Search in sources :

Example 1 with ResolveSyncWorkResultMapper

use of com.enonic.xp.lib.node.mapper.ResolveSyncWorkResultMapper in project xp by enonic.

the class DiffBranchesHandler method execute.

@Override
public Object execute() {
    final NodeId nodeId = getNodeId(this.nodeKey);
    if (nodeId == null) {
        throw new NodeNotFoundException("Node with key [" + this.nodeKey + "] not found");
    }
    final ResolveSyncWorkResult result = this.nodeService.resolveSyncWork(SyncWorkResolverParams.create().includeChildren(includeChildren).nodeId(nodeId).branch(targetBranch).build());
    return new ResolveSyncWorkResultMapper(result);
}
Also used : NodeNotFoundException(com.enonic.xp.node.NodeNotFoundException) ResolveSyncWorkResultMapper(com.enonic.xp.lib.node.mapper.ResolveSyncWorkResultMapper) NodeId(com.enonic.xp.node.NodeId) ResolveSyncWorkResult(com.enonic.xp.node.ResolveSyncWorkResult)

Aggregations

ResolveSyncWorkResultMapper (com.enonic.xp.lib.node.mapper.ResolveSyncWorkResultMapper)1 NodeId (com.enonic.xp.node.NodeId)1 NodeNotFoundException (com.enonic.xp.node.NodeNotFoundException)1 ResolveSyncWorkResult (com.enonic.xp.node.ResolveSyncWorkResult)1