SAMSON has a mechanism for SBCFunctor functors, which are used to perform e.g. selection operators and visit operations.

See also
Getting nodes


Selection functors are predicates that may be combined:

// find all atoms which have a partial charge larger than 0.4f
std::vector<SBNode*> nodeVector;
SBAtom::HasPartialCharge() &&
(SBAtom::GetPartialCharge() >= 0.4f));


static SBDDocument * getActiveDocument()
Returns a pointer to SAMSON's active document.
Definition: SAMSON.cpp:727
@ Atom
Definition: SBDDataGraphNode.hpp:70
This node predicate compares the node type with a given type.
Definition: SBDDataGraphNode.hpp:505
virtual void getNodes(SBNodeIndexer &nodeIndexer, SBNode::Type nodeType, bool selectedNodesOnly=false, const SBNodePredicate &visitPredicate=SBDDataGraphNode::All(), bool includeDependencies=false) const
Collects nodes into nodeIndexer, based on a nodeType, a selection status and a visitPredicate,...
Definition: SBDDocumentFolder.cpp:741