| 21 | }; |
| 22 | |
| 23 | class ScriptEntityNode : |
| 24 | public ScriptSceneNode |
| 25 | { |
| 26 | public: |
| 27 | // Constructor, checks if the passed node is actually an entity |
| 28 | ScriptEntityNode(const scene::INodePtr& node); |
| 29 | |
| 30 | // Methods wrapping to Entity class |
| 31 | std::string getKeyValue(const std::string& key); |
| 32 | void setKeyValue(const std::string& key, const std::string& value); |
| 33 | bool isInherited(const std::string& key); |
| 34 | |
| 35 | ScriptEntityClass getEntityClass(); |
| 36 | bool isModel(); |
| 37 | bool isOfType(const std::string& className); |
| 38 | Entity::KeyValuePairs getKeyValuePairs(const std::string& prefix); |
| 39 | |
| 40 | // Visit each keyvalue, wraps to the contained entity |
| 41 | void forEachKeyValue(EntityVisitor& visitor); |
| 42 | |
| 43 | // Checks if the given SceneNode structure is an EntityNode |
| 44 | static bool isEntity(const ScriptSceneNode& node); |
| 45 | |
| 46 | // "Cast" service for Python, returns a ScriptEntityNode. |
| 47 | // The returned node is non-NULL if the cast succeeded |
| 48 | static ScriptEntityNode getEntity(const ScriptSceneNode& node); |
| 49 | }; |
| 50 | |
| 51 | // Wrap around the EntityClassVisitor interface |
| 52 | class EntityVisitorWrapper : |
no outgoing calls
no test coverage detected