OpenVDB
9.0.1
|
Retrieve intrinsic information from AX AST by performing various traversal algorithms. More...
Go to the source code of this file.
Classes | |
struct | VisitNodeType< NodeT, OpT, Derived > |
Namespaces | |
openvdb | |
openvdb::v9_0 | |
openvdb::v9_0::ax | |
openvdb::v9_0::ax::ast | |
Functions | |
bool | usesAttribute (const ast::Node &node, const std::string &name, const tokens::CoreType type=tokens::UNKNOWN) |
Returns whether or not a given branch of an AST reads from or writes to a given attribute. More... | |
bool | writesToAttribute (const ast::Node &node, const std::string &name, const tokens::CoreType type=tokens::UNKNOWN) |
Returns whether or not a given branch of an AST writes to a given attribute. More... | |
bool | callsFunction (const ast::Node &node, const std::string &name) |
Returns whether or not a given branch of an AST calls a function. More... | |
void | catalogueVariables (const ast::Node &node, std::vector< const ast::Variable * > *readOnly, std::vector< const ast::Variable * > *writeOnly, std::vector< const ast::Variable * > *readWrite, const bool locals=true, const bool attributes=true) |
todo More... | |
void | catalogueAttributeTokens (const ast::Node &node, std::vector< std::string > *readOnly, std::vector< std::string > *writeOnly, std::vector< std::string > *readWrite) |
Parse all attributes into three unique vectors which represent how they are accessed within the syntax tree. Read only attributes are stored within the 'readOnly' container (for example. More... | |
void | attributeDependencyTokens (const ast::Tree &tree, const std::string &name, const tokens::CoreType type, std::vector< std::string > &dependencies) |
Populate a list of attribute names which the given attribute depends on. More... | |
template<typename NodeT , typename OpT > | |
void | visitNodeType (const ast::Node &node, const OpT &op) |
For an AST node of a given type, search for and call a custom const operator() which takes a const reference to every occurrence of the specified node type. More... | |
template<typename NodeT , typename ContainerType = std::vector<const NodeT*>> | |
void | collectNodeType (const ast::Node &node, ContainerType &array) |
Visit all nodes of a given type and store pointers to them in a provided compatible container. More... | |
template<typename NodeTypeList , typename ContainerType = std::vector<const Node*>> | |
void | collectNodeTypes (const ast::Node &node, ContainerType &array) |
Visit all nodes of the given types and store pointers to them in a container of base ast::Node pointers. More... | |
void | linearize (const ast::Node &node, std::vector< const ast::Node * > &list) |
Flatten the provided AST branch into a linear list using post order traversal. More... | |
const ast::Variable * | firstUse (const ast::Node &node, const std::string &token) |
const ast::Variable * | lastUse (const ast::Node &node, const std::string &token) |
Retrieve intrinsic information from AX AST by performing various traversal algorithms.