Castle Game Engine: X3DNodes: Class TNodesManager

# Class TNodesManager
Description | Hierarchy | Fields | Methods | Properties
## Unit X3DNodes ## Declaration `type TNodesManager = class(TObject)` ## Description ## Hierarchy TObject TNodesManager ## Overview ### Methods
| `constructor Create;`
| `destructor Destroy; override;`
| `procedure RegisterNodeClass(NodeClass: TX3DNodeClass);`
| `procedure RegisterNodeClasses(const NodeClasses: array of TX3DNodeClass);`
| `procedure UnRegisterNodeClass(NodeClass: TX3DNodeClass; ErrorIfNotRegistered: boolean = true);`
| `function NodeTypeNameToClass(const ANodeTypeName: string; const Version: TX3DVersion): TX3DNodeClass;`
| `function URNToClass(const URN: string): TX3DNodeClass;`
| `function RegisteredCount: Cardinal;`
### Properties
| `property Registered [Index:Integer]: TX3DNodeClass read GetRegistered;`
## Description ### Methods
| `constructor Create;`
| `destructor Destroy; override;`
| `procedure RegisterNodeClass(NodeClass: TX3DNodeClass);`
Make the given node class known to the parser and other routines. We associate the node class with it's TX3DNode.ClassNodeTypeName (make sure it's not empty). It is OK to register two different node classes with the same node. For example, VRML 1.0 TConeNode_1 class and VRML 2.0/X3D TConeNode_2 class both have a name 'Cone' (and will be correctly chosen during parsing). But you cannot register two times the same NodeClass.
| `procedure RegisterNodeClasses(const NodeClasses: array of TX3DNodeClass);`
| `procedure UnRegisterNodeClass(NodeClass: TX3DNodeClass; ErrorIfNotRegistered: boolean = true);`
Unregisters given node class, removing it from our table. ###### Exceptions raised ENodesManagerError if NodeClass.ClassNodeTypeName = '' (so it cannot be even registered), or if ((NodeClass was not registered) and ErrorIfNotRegistered)
| `function NodeTypeNameToClass(const ANodeTypeName: string; const Version: TX3DVersion): TX3DNodeClass;`
Return node class for a given name. This method is the main purpose of TNodesManager: to map node names into node classes. Searches in nodes registered by RegisterNodeClass and such. During searching, looks not only for matching node name, but also at matching VRML/X3D version, checking `ForVRMLVersion(Version)`. Returns `Nil` when not found.
| `function URNToClass(const URN: string): TX3DNodeClass;`
Return class that matches given URL. This is useful for EXTERNROTOs. Returns `Nil` if not found.
| `function RegisteredCount: Cardinal;`
### Properties
| `property Registered [Index:Integer]: TX3DNodeClass read GetRegistered;`
Enumerate all registered classes, from Registered[0] to Registered[RegisteredCount - 1].
Generated by PasDoc 0.13.0 on 2015-06-15 04:43:17