|
Public Member Functions |
| | NCollection_Array2 (const Standard_Integer theRowLower, const Standard_Integer theRowUpper, const Standard_Integer theColLower, const Standard_Integer theColUpper) |
| | Constructor.
|
| | NCollection_Array2 (const NCollection_Array2 &theOther) |
| | Copy constructor.
|
| | NCollection_Array2 (const TheItemType &theBegin, const Standard_Integer theRowLower, const Standard_Integer theRowUpper, const Standard_Integer theColLower, const Standard_Integer theColUpper) |
| | C array-based constructor.
|
| void | Init (const TheItemType &theValue) |
| | Initialise the values.
|
| virtual Standard_Integer | Size (void) const |
| | Size (number of items).
|
| Standard_Integer | Length (void) const |
| | Length (number of items).
|
| Standard_Integer | RowLength (void) const |
| | RowLength.
|
| Standard_Integer | ColLength (void) const |
| | ColLength.
|
| Standard_Integer | LowerRow (void) const |
| | LowerRow.
|
| Standard_Integer | UpperRow (void) const |
| | UpperRow.
|
| Standard_Integer | LowerCol (void) const |
| | LowerCol.
|
| Standard_Integer | UpperCol (void) const |
| | UpperCol.
|
| Standard_Boolean | IsDeletable (void) const |
| | myDeletable flag
|
| virtual void | Assign (const NCollection_BaseCollection< TheItemType > &theOther) |
| | Assign.
|
| NCollection_Array2 & | operator= (const NCollection_Array2 &theOther) |
| | operator= (array to array)
|
| const TheItemType & | Value (const Standard_Integer theRow, const Standard_Integer theCol) const |
| | Constant value access.
|
| const TheItemType & | operator() (const Standard_Integer theRow, const Standard_Integer theCol) const |
| | operator() - alias to ChangeValue
|
| TheItemType & | ChangeValue (const Standard_Integer theRow, const Standard_Integer theCol) |
| | Variable value access.
|
| TheItemType & | operator() (const Standard_Integer theRow, const Standard_Integer theCol) |
| | operator() - alias to ChangeValue
|
| void | SetValue (const Standard_Integer theRow, const Standard_Integer theCol, const TheItemType &theItem) |
| | SetValue.
|
| | ~NCollection_Array2 (void) |
| | Destructor - releases the memory.
|
Protected Attributes |
| Standard_Integer | myLowerRow |
| Standard_Integer | myUpperRow |
| Standard_Integer | myLowerCol |
| Standard_Integer | myUpperCol |
| TheItemType ** | myData |
| | Pointer to the row pointers table.
|
| TheItemType * | myStart |
| | Pointer to the memory array.
|
| Standard_Boolean | myDeletable |
| | Flag showing who allocated the array.
|
Private Member Functions |
| void | Allocate (void) |
| | Allocate memory for the array, set up indirection table.
|
virtual TYPENAME NCollection_BaseCollection<
TheItemType >::Iterator & | CreateIterator (void) const |
| | Creates Iterator for use on BaseCollection.
|
Data Structures |
| class | Iterator |
Warning: Programs clients of such class must be independant of the range of the first element. Then, a C++ for loop must be written like this
for (i = A.LowerRow(); i <= A.UpperRow(); i++) for (j = A.LowerCol(); j <= A.UpperCol(); j++)