Open CASCADE Technology
6.5.4
|
#include <TObj_TIntSparseArray.hxx>
Public Types | |
typedef TObj_TIntSparseArray_VecOfData::ConstIterator | Iterator |
Public Member Functions | |
TObj_TIntSparseArray () | |
Empty constructor. | |
const Standard_GUID & | ID () const |
Returns the ID of this attribute. | |
Standard_Size | Size () const |
Methods for access to data. | |
Iterator | GetIterator () const |
Returns iterator on objects contained in the set. | |
Standard_Boolean | HasValue (const Standard_Size theId) const |
Returns true if the value with the given ID is present. | |
Standard_Integer | Value (const Standard_Size theId) const |
Returns the value by its ID. Raises an exception if no value is stored with this ID. | |
void | SetValue (const Standard_Size theId, const Standard_Integer theValue) |
Sets the value with the given ID. Raises an exception if theId is not positive. | |
void | UnsetValue (const Standard_Size theId) |
Unsets the value with the given ID. Raises an exception if theId is not positive. | |
void | Clear () |
Clears the set. | |
Handle< TDF_Attribute > | NewEmpty () const |
Redefined OCAF abstract methods. | |
Handle< TDF_Attribute > | BackupCopy () const |
Moves this delta into a new other attribute. | |
void | Restore (const Handle< TDF_Attribute > &theDelta) |
Restores the set using info saved in backup attribute theDelta. | |
void | Paste (const Handle< TDF_Attribute > &theInto, const Handle< TDF_RelocationTable > &theRT) const |
This method is used when copying an attribute from a source structure into a target structure. | |
void | BeforeCommitTransaction () |
It is called just before Commit or Abort transaction and does Backup() to create a delta. | |
void | DeltaOnModification (const Handle< TDF_DeltaOnModification > &theDelta) |
Applies theDelta to this. | |
Standard_Boolean | AfterUndo (const Handle< TDF_AttributeDelta > &theDelta, const Standard_Boolean toForce) |
Clears my modification delta; called after application of theDelta. | |
void | SetDoBackup (const Standard_Boolean toDo) |
Methods to handle the modification delta. | |
void | ClearDelta () |
Static Public Member Functions | |
static const Standard_GUID & | GetID () |
This method is used in implementation of ID() | |
static Handle < TObj_TIntSparseArray > | Set (const TDF_Label &theLabel) |
Creates TObj_TIntSparseArray attribute on given label. |
OCAF Attribute to store a set of positive integer values in the OCAF tree. Each value is identified by ID (positive integer). The supporting underlying data structure is NCollection_SparseArray of integers.
typedef TObj_TIntSparseArray_VecOfData::ConstIterator TObj_TIntSparseArray::Iterator |
Standard_Boolean TObj_TIntSparseArray::AfterUndo | ( | const Handle< TDF_AttributeDelta > & | theDelta, |
const Standard_Boolean | toForce | ||
) | [virtual] |
Reimplemented from TDF_Attribute.
Handle< TDF_Attribute > TObj_TIntSparseArray::BackupCopy | ( | ) | const [virtual] |
Reimplemented from TDF_Attribute.
void TObj_TIntSparseArray::BeforeCommitTransaction | ( | ) | [virtual] |
Reimplemented from TDF_Attribute.
void TObj_TIntSparseArray::ClearDelta | ( | ) | [inline] |
void TObj_TIntSparseArray::DeltaOnModification | ( | const Handle< TDF_DeltaOnModification > & | theDelta | ) | [virtual] |
Reimplemented from TDF_Attribute.
static const Standard_GUID& TObj_TIntSparseArray::GetID | ( | ) | [static] |
Iterator TObj_TIntSparseArray::GetIterator | ( | ) | const [inline] |
Standard_Boolean TObj_TIntSparseArray::HasValue | ( | const Standard_Size | theId | ) | const [inline] |
const Standard_GUID& TObj_TIntSparseArray::ID | ( | ) | const [virtual] |
Implements TDF_Attribute.
Handle< TDF_Attribute > TObj_TIntSparseArray::NewEmpty | ( | ) | const [virtual] |
Returns an new empty TObj_TIntSparseArray attribute. It is used by the copy algorithm.
Implements TDF_Attribute.
void TObj_TIntSparseArray::Paste | ( | const Handle< TDF_Attribute > & | theInto, |
const Handle< TDF_RelocationTable > & | theRT | ||
) | const [virtual] |
Implements TDF_Attribute.
void TObj_TIntSparseArray::Restore | ( | const Handle< TDF_Attribute > & | theDelta | ) | [virtual] |
Implements TDF_Attribute.
static Handle< TObj_TIntSparseArray > TObj_TIntSparseArray::Set | ( | const TDF_Label & | theLabel | ) | [static] |
void TObj_TIntSparseArray::SetDoBackup | ( | const Standard_Boolean | toDo | ) | [inline] |
Sets the flag pointing to the necessity to maintain a modification delta. It is called by the retrieval driver
void TObj_TIntSparseArray::SetValue | ( | const Standard_Size | theId, |
const Standard_Integer | theValue | ||
) |
Standard_Size TObj_TIntSparseArray::Size | ( | ) | const [inline] |
Returns the number of stored values in the set
Standard_Integer TObj_TIntSparseArray::Value | ( | const Standard_Size | theId | ) | const [inline] |