Package com.banuba.sdk.scene
Class Entity.CppProxy
java.lang.Object
com.banuba.sdk.scene.Entity.CppProxy
- All Implemented Interfaces:
Entity
- Enclosing interface:
- Entity
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.banuba.sdk.scene.Entity
Entity.CppProxy
-
Method Summary
Modifier and TypeMethodDescriptionvoid
void
add entiy as child to hierarchyvoid
addComponent
(Component component) add given component to entity if component of given type wasn't added before.void
addIntoLayer
(Layer layer) Add entity for given layer if it is wasn't added before.void
remove all child entites list.protected void
finalize()
findChildByName
(String entityName) Perform depth-first traverse of entity tree.get all child entites list.getComponent
(ComponentType type) get component of given type.returns list of layers in which entity was added.getName()
boolean
hasComponent
(ComponentType type) check if component of given type was added.boolean
isActive()
void
removeChild
(Entity child) remove entiy as child to hierarchyvoid
removeComponent
(Component component) remove given component to entity if component of given component was added before.void
removeFromLayer
(Layer layer) Removes entity from given layer if it is was added before.void
setActive
(boolean active) Set enable/disable entity flag.void
Set a new name to the entity.
-
Method Details
-
_djinni_private_destroy
public void _djinni_private_destroy() -
finalize
-
setName
Description copied from interface:Entity
Set a new name to the entity. Name could be empty. -
getName
-
addChild
Description copied from interface:Entity
add entiy as child to hierarchy -
removeChild
Description copied from interface:Entity
remove entiy as child to hierarchy- Specified by:
removeChild
in interfaceEntity
- Parameters:
child
- (entity): child entity.
-
getChildren
Description copied from interface:Entity
get all child entites list.- Specified by:
getChildren
in interfaceEntity
-
clearChildren
public void clearChildren()Description copied from interface:Entity
remove all child entites list.- Specified by:
clearChildren
in interfaceEntity
-
findChildByName
Description copied from interface:Entity
Perform depth-first traverse of entity tree. Return first found child with name `entityName` or NULL if such an entity doesn't exist.- Specified by:
findChildByName
in interfaceEntity
- Parameters:
entityName
- (string): name of desired entity- Returns:
- found entity (entity) or null
-
getParent
-
setActive
public void setActive(boolean active) Description copied from interface:Entity
Set enable/disable entity flag. The disabling of the entity is equivalent to removing the entity and all its children from the hierarchy. -
isActive
public boolean isActive() -
addIntoLayer
Description copied from interface:Entity
Add entity for given layer if it is wasn't added before.- Specified by:
addIntoLayer
in interfaceEntity
- Parameters:
layer
- (layer): layer to add.
-
removeFromLayer
Description copied from interface:Entity
Removes entity from given layer if it is was added before.- Specified by:
removeFromLayer
in interfaceEntity
-
getLayers
Description copied from interface:Entity
returns list of layers in which entity was added. -
addComponent
Description copied from interface:Entity
add given component to entity if component of given type wasn't added before.- Specified by:
addComponent
in interfaceEntity
- Parameters:
component
- (component): component to add.
-
hasComponent
Description copied from interface:Entity
check if component of given type was added.- Specified by:
hasComponent
in interfaceEntity
- Returns:
- flag (bool)
-
getComponent
Description copied from interface:Entity
get component of given type.- Specified by:
getComponent
in interfaceEntity
- Returns:
- component of given type (component)
-
removeComponent
Description copied from interface:Entity
remove given component to entity if component of given component was added before.- Specified by:
removeComponent
in interfaceEntity
- Parameters:
component
- (component): component to remove.
-