Open CASCADE Technology 7.9.1
Loading...
Searching...
No Matches
TObj_Partition.hxx File Reference
#include <TObj_Object.hxx>
#include <TObj_Persistence.hxx>

Functions

 TObj_Partition (const TDF_Label &theLabel, const Standard_Boolean theSetName=Standard_True)
 Constructor is protected; static methods are used for creation of this type of objects.
virtual Standard_Boolean SetName (const Handle< TCollection_HExtendedString > &theName) const override
 Sets name of the object. partition does not check unique of own name.
virtual void AfterRetrieval () override
 Performs updating the links and dependencies of the object which are not stored in persistence. Does not register the partition name.
TDF_Label NewLabel () const
 Creates and Returns label for new object in partition.
void SetNamePrefix (const Handle< TCollection_HExtendedString > &thePrefix)
 Sets prefix for names of the objects in partition.
Handle< TCollection_HExtendedStringGetNamePrefix () const
 Returns prefix for names of the objects in partition.
Handle< TCollection_HExtendedStringGetNewName (const Standard_Boolean theIsToChangeCount=Standard_True)
 Generates and returns name for new object in partition. if theIsToChangeCount is true partition increase own counter to generate new name next time starting from new counter value.
Standard_Integer GetLastIndex () const
 Return Last index in partition (reserved);.
void SetLastIndex (const Standard_Integer theIndex)
 Sets Last index in partition (reserved);.
virtual Standard_Boolean Update ()
 Does nothing in the partition.
virtual Standard_Boolean copyData (const Handle< TObj_Object > &theTargetObject) override
 Coping the data of me to Target object. return Standard_False is Target object is different type.

Function Documentation

◆ AfterRetrieval()

virtual void AfterRetrieval ( )
overridevirtual

Performs updating the links and dependencies of the object which are not stored in persistence. Does not register the partition name.

Method for updating object after restoring

◆ copyData()

virtual Standard_Boolean copyData ( const Handle< TObj_Object > & theTargetObject)
overrideprotectedvirtual

Coping the data of me to Target object. return Standard_False is Target object is different type.

protected redefined methods

◆ GetLastIndex()

Standard_Integer GetLastIndex ( ) const

Return Last index in partition (reserved);.

◆ GetNamePrefix()

Handle< TCollection_HExtendedString > GetNamePrefix ( ) const

Returns prefix for names of the objects in partition.

◆ GetNewName()

Handle< TCollection_HExtendedString > GetNewName ( const Standard_Boolean theIsToChangeCount = Standard_True)

Generates and returns name for new object in partition. if theIsToChangeCount is true partition increase own counter to generate new name next time starting from new counter value.

◆ NewLabel()

TDF_Label NewLabel ( ) const

Creates and Returns label for new object in partition.

Methods handling of the objects in partition

◆ SetLastIndex()

void SetLastIndex ( const Standard_Integer theIndex)

Sets Last index in partition (reserved);.

◆ SetName()

virtual Standard_Boolean SetName ( const Handle< TCollection_HExtendedString > & theName) const
overridevirtual

Sets name of the object. partition does not check unique of own name.

Methods handling name of the object

◆ SetNamePrefix()

void SetNamePrefix ( const Handle< TCollection_HExtendedString > & thePrefix)

Sets prefix for names of the objects in partition.

◆ TObj_Partition()

TObj_Partition ( const TDF_Label & theLabel,
const Standard_Boolean theSetName = Standard_True )

Constructor is protected; static methods are used for creation of this type of objects.

This class provides tool handling one of partitions (the set of homogeneous elements) in the OCAF based model`s data structure */

class TObj_Partition : public TObj_Object { protected: enum DataTag { DataTag_First = TObj_Object::DataTag_Last, DataTag_LastIndex, DataTag_Last = DataTag_First + 100 };

protected: /** Constructor

◆ Update()

virtual Standard_Boolean Update ( )
virtual

Does nothing in the partition.

Methods for updating the object