Chemical Data Processing Library Python API - Version 1.4.0
Public Member Functions | Properties | List of all members
CDPL.Vis.Object3D Class Reference

Hierarchical 3D scene object that owns a list of nested sub-objects and inherits its property bag from Base.PropertyContainer. More...

+ Inheritance diagram for CDPL.Vis.Object3D:

Public Member Functions

None __init__ ()
 Default constructor.
 
None __init__ (Object3D obj)
 Constructs a copy of the Object3D instance obj. More...
 
Object3D assign (Object3D self)
 Replaces the current state of arg1 with a copy of the state of the Object3D instance self. More...
 
None clear ()
 Removes all sub-objects and clears all properties of this object.
 
None removeSubObject (int idx)
 Removes the sub-object at index idx. More...
 
Object3D getSubObject (int idx)
 Returns a reference to the sub-object at index idx. More...
 
int getNumSubObjects ()
 Returns the number of sub-objects directly owned by this object. More...
 
Object3D addSubObject ()
 Creates a new empty sub-object and appends it to the sub-object list. More...
 
Object3D addSubObject (Object3D obj)
 
Base.Any __getitem__ (Base.LookupKey key)
 
Object3D __getitem__ (int idx)
 
bool __contains__ (Base.LookupKey key)
 Returns the result of the membership test operation key in self. More...
 
None __setitem__ (Base.LookupKey key, Base.Any value)
 
bool __delitem__ (Base.LookupKey key)
 
None __delitem__ (int idx)
 
int __len__ ()
 
- Public Member Functions inherited from CDPL.Base.PropertyContainer
int getObjectID ()
 Returns the numeric identifier (ID) of the wrapped C++ class instance. More...
 
int getNumProperties ()
 Returns the number of property entries. More...
 
Any getPropertyOrDefault (LookupKey key, Any def_value)
 
list getPropertyKeys ()
 
list getPropertyValues ()
 
list getProperties ()
 Returns a reference to itself. More...
 
None setProperty (LookupKey key, Any value)
 
bool removeProperty (LookupKey key)
 Clears the value of the property specified by key. More...
 
Any getProperty (LookupKey key, bool throw_=False)
 Returns the value of the property specified by key. More...
 
bool isPropertySet (LookupKey key)
 Tells whether or not a value has been assigned to the property specified by key. More...
 
None clearProperties ()
 Clears all property values.
 
None addProperties (PropertyContainer cntnr)
 Adds the property value entries in the PropertyContainer instance cntnr. More...
 
None copyProperties (PropertyContainer cntnr)
 Replaces the current set of properties by a copy of the entries in cntnr. More...
 
None swap (PropertyContainer cntnr)
 Exchanges the properties of this container with the properties of the container cntnr. More...
 
Any __getitem__ (LookupKey key)
 
bool __contains__ (LookupKey key)
 Returns the result of the membership test operation key in self. More...
 
None __setitem__ (LookupKey key, Any value)
 
bool __delitem__ (LookupKey key)
 

Properties

 numSubObjects = property(getNumSubObjects)
 
- Properties inherited from CDPL.Base.PropertyContainer
 objectID = property(getObjectID)
 
 propertyKeys = property(getPropertyKeys)
 
 propertyValues = property(getPropertyValues)
 
 properties = property(getProperties)
 
 numProperties = property(getNumProperties)
 

Detailed Description

Hierarchical 3D scene object that owns a list of nested sub-objects and inherits its property bag from Base.PropertyContainer.

Concrete 3D representations (e.g. those produced by Vis.FeatureContainerObject3DFactory) are typically assembled as trees of nested Object3D instances annotated with rendering-relevant properties.

Since
1.3

Constructor & Destructor Documentation

◆ __init__()

None CDPL.Vis.Object3D.__init__ ( Object3D  obj)

Constructs a copy of the Object3D instance obj.

Parameters
objThe Object3D instance to copy.

Member Function Documentation

◆ assign()

Object3D CDPL.Vis.Object3D.assign ( Object3D  self)

Replaces the current state of arg1 with a copy of the state of the Object3D instance self.

Parameters
selfThe Object3D instance to copy.
Returns
arg1

◆ removeSubObject()

None CDPL.Vis.Object3D.removeSubObject ( int  idx)

Removes the sub-object at index idx.

Parameters
idxThe zero-based index of the sub-object to remove.
Exceptions
Base.IndexErrorif the number of sub-objects is zero or idx is not in the range [0, getNumSubObjects() - 1].

◆ getSubObject()

Object3D CDPL.Vis.Object3D.getSubObject ( int  idx)

Returns a reference to the sub-object at index idx.

Parameters
idxThe zero-based sub-object index.
Returns
A reference to the sub-object.
Exceptions
Base.IndexErrorif the number of sub-objects is zero or idx is not in the range [0, getNumSubObjects() - 1].

◆ getNumSubObjects()

int CDPL.Vis.Object3D.getNumSubObjects ( )

Returns the number of sub-objects directly owned by this object.

Returns
The sub-object count.

◆ addSubObject() [1/2]

Object3D CDPL.Vis.Object3D.addSubObject ( )

Creates a new empty sub-object and appends it to the sub-object list.

Returns
A reference to the newly created sub-object.

◆ addSubObject() [2/2]

Object3D CDPL.Vis.Object3D.addSubObject ( Object3D  obj)
Parameters
obj
Returns

◆ __getitem__() [1/2]

Base.Any CDPL.Vis.Object3D.__getitem__ ( Base.LookupKey  key)
Parameters
key
Returns

◆ __getitem__() [2/2]

Object3D CDPL.Vis.Object3D.__getitem__ ( int  idx)
Parameters
idx
Returns

◆ __contains__()

bool CDPL.Vis.Object3D.__contains__ ( Base.LookupKey  key)

Returns the result of the membership test operation key in self.

Parameters
keyThe value to test for membership.
Returns
The result of the membership test operation.

◆ __setitem__()

None CDPL.Vis.Object3D.__setitem__ ( Base.LookupKey  key,
Base.Any  value 
)
Parameters
key
value

◆ __delitem__() [1/2]

bool CDPL.Vis.Object3D.__delitem__ ( Base.LookupKey  key)
Parameters
key
Returns

◆ __delitem__() [2/2]

None CDPL.Vis.Object3D.__delitem__ ( int  idx)
Parameters
idx

◆ __len__()

int CDPL.Vis.Object3D.__len__ ( )
Returns

Reimplemented from CDPL.Base.PropertyContainer.