private ExplorerNode createExplorerNode(final ExplorerTreeNode explorerTreeNode) {
        if (ExplorerConstants.isSystemNode(explorerTreeNode.getType(), explorerTreeNode.getUuid())) {
            return ExplorerConstants.SYSTEM_NODE;
        } else if (ExplorerConstants.isFavouritesNode(explorerTreeNode.getType(), explorerTreeNode.getUuid())) {
            return ExplorerConstants.FAVOURITES_NODE;
        } else {
            return explorerTreeNode.buildExplorerNode()
                    .addNodeFlag(ExplorerFlags.getStandardFlagByDocType(explorerTreeNode.getType())
                            .orElse(null))
                    .build();
        }
    }
General form a function that returns a list of explorer nodes from the tree DAO

@param folderDocRef  The root doc ref of the query
@param fetchFunction The function to call to get the list of ExplorerTreeNodes given a root ExplorerTreeNode
@return The list of converted ExplorerNodes
stroom-explorer/stroom-explorer-impl/src/main/java/stroom/explorer/impl/ExplorerNodeServiceImpl.java