class NodeSearchService implements NodeSearchServiceInterface (View source)

Find nodes based on a fulltext search

Properties

protected NodeDataRepository $nodeDataRepository
protected NodeFactory $nodeFactory
protected PersistenceManagerInterface $persistenceManager

Methods

findByProperties(string $term, array $searchNodeTypes, Context $context, NodeInterface $startingPoint = null)

Search all properties for given $term

bool
nodeSatisfiesSearchNodeTypes(NodeInterface $node, array $searchNodeTypes)

Whether or not the given $node satisfies the specified types

Details

NodeInterface[] findByProperties(string $term, array $searchNodeTypes, Context $context, NodeInterface $startingPoint = null)

Search all properties for given $term

TODO: Implement a better search when Flow offer the possibility

Parameters

string $term
array $searchNodeTypes
Context $context
NodeInterface $startingPoint

Return Value

NodeInterface[]

protected bool nodeSatisfiesSearchNodeTypes(NodeInterface $node, array $searchNodeTypes)

Whether or not the given $node satisfies the specified types

Parameters

NodeInterface $node
array $searchNodeTypes

Return Value

bool