NCollection_Array2< TheItemType > Class Template Reference
#include <NCollection_Array2.hxx>
Data Structures |
| class | Iterator |
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.
|
Detailed Description
template<class TheItemType>
class NCollection_Array2< TheItemType >
Purpose: The class Array2 represents bi-dimensional arrays of fixed size known at run time. The ranges of indices are user defined.
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++)
Constructor & Destructor Documentation
template<class TheItemType >
template<class TheItemType >
template<class TheItemType >
template<class TheItemType >
Member Function Documentation
template<class TheItemType >
template<class TheItemType >
template<class TheItemType >
template<class TheItemType >
template<class TheItemType >
template<class TheItemType >
template<class TheItemType >
template<class TheItemType >
template<class TheItemType >
template<class TheItemType >
template<class TheItemType >
template<class TheItemType >
template<class TheItemType >
template<class TheItemType >
template<class TheItemType >
template<class TheItemType >
template<class TheItemType >
Field Documentation
template<class TheItemType >
template<class TheItemType >
template<class TheItemType >
template<class TheItemType >
template<class TheItemType >
template<class TheItemType >
template<class TheItemType >
The documentation for this class was generated from the following file: