The ValidateNodeCreateContext class is used to automate actual <Node> creation and user interface state handling for script commands that create <Node> objects. It can also be used to create <Node> sets from template model files.
Class Hierarchy | Type » ValidateNodeCreateContext |
Function members are as follows:
Return Type | Function Name | Documentation |
---|---|---|
static int32 | CreateNodes | Creates one or more <Node> objects of the type indicated by 'NodeType'. If one or more <Group> node objects (or derived class objects) are selected, a new <Node> is created for each selected <Group> (or derived object). Otherwise one new <Node> is created and it is placed under the default parent of the model indicated by Model. |
static int32 | CreateNodesFromTemplate | Creates one or more sets of <Node> objects from a template model file. The set of created <Node> objects includes each <Node> under the root node of the template model. Creates one or more <Node> objects of the type indicated by 'NodeType'. If one or more <Group> node objects (or derived class objects) are selected, the template file is loaded for each selected <Group> (or derived object). Otherwise the template is loaded once, and content is placed under the default parent of the model indicated by Model. |
static int32 | ImportNodesFromTemplate | This option is undocumented at present. |
static int32 | TestContext | Sets the UI state for a <Node> creation command. The current implementation tests if a <Group> node (or derived node type) is selected, or if the selection buffer is empty and prints a message using the StatusBar member of 'CommandInfo'. If a <Group> is selected or the selection buffer is empty, the message informs the user that the command will create a <Node> of type 'NodeType'. Otherwise, the message informs the user what type of selection is necessary for the command to be enabled. |