![]() |
Open CASCADE Technology Reference Manual 8.0.0
|
Auxiliary class for ParamReader. It stores commands for a ParamReader to manage the current parameter number. Used by methods Read... from ParamReader. It allows to define the following commands : More...
#include <IGESData_ParamCursor.hxx>
Public Member Functions | |
| IGESData_ParamCursor (const int num) | |
| Creates a Cursor to read a precise parameter of ParamReader, identified by its number, then set Current Number to "num + 1" (this constructor allows to simply give a Number to a method Read... from ParamReader, which will be translated into a ParamCursor by compiler) | |
| IGESData_ParamCursor (const int num, const int nb, const int size=1) | |
| Creates a Cursor to read a list of parameters (count "nb") starting from a precise one (number "num") included, then set Current Number of ParamNumber to the first following one ("num + nb") If size is given, it means that each parameter is made of more than one term. One term is the normal (default) case : for instance, a Parameter comprises one Integer, or one Entity ... Size gives the complete size of each Item if it is complex. To be used ONLY IF it is constant. | |
| void | SetTerm (const int size, const bool autoadv=true) |
| Defines the size of a term to read in the item : this commands ParamReader to read "size" parameters for each item, then skip the remainder of the item to the same term of next Item (that is, skip "item size" - "term size") | |
| void | SetOne (const bool autoadv=true) |
| Defines a term of one Parameter (very current case) | |
| void | SetXY (const bool autoadv=true) |
| Defines a term of two Parameters for a XY (current case) | |
| void | SetXYZ (const bool autoadv=true) |
| Defines a term of three Parameters for XYZ (current case) | |
| void | SetAdvance (const bool advance) |
| Changes command to advance current cursor after reading parameters. If "advance" True, sets advance, if "False", resets it. ParamCursor is created by default with True. | |
| int | Start () const |
| Returns (included) starting number for reading parameters. | |
| int | Limit () const |
| Returns (excluded) upper limit number for reading parameters. | |
| int | Count () const |
| Returns required count of items to be read. | |
| int | ItemSize () const |
| Returns length of item (count of parameters per item) | |
| int | TermSize () const |
| Returns length of current term (count of parameters) in item. | |
| int | Offset () const |
| Returns offset from which current term must be read in item. | |
| bool | Advance () const |
| Returns True if Advance command has been set. | |
Auxiliary class for ParamReader. It stores commands for a ParamReader to manage the current parameter number. Used by methods Read... from ParamReader. It allows to define the following commands :
If commands to advance Current Number are not set, it must be set by the user (with method SetCurrent from ParamReader) ParamReader offers methods which create most useful cases
| IGESData_ParamCursor::IGESData_ParamCursor | ( | const int | num | ) |
Creates a Cursor to read a precise parameter of ParamReader, identified by its number, then set Current Number to "num + 1" (this constructor allows to simply give a Number to a method Read... from ParamReader, which will be translated into a ParamCursor by compiler)
Creates a Cursor to read a list of parameters (count "nb") starting from a precise one (number "num") included, then set Current Number of ParamNumber to the first following one ("num + nb") If size is given, it means that each parameter is made of more than one term. One term is the normal (default) case : for instance, a Parameter comprises one Integer, or one Entity ... Size gives the complete size of each Item if it is complex. To be used ONLY IF it is constant.
| bool IGESData_ParamCursor::Advance | ( | ) | const |
Returns True if Advance command has been set.
| int IGESData_ParamCursor::Count | ( | ) | const |
Returns required count of items to be read.
| int IGESData_ParamCursor::ItemSize | ( | ) | const |
Returns length of item (count of parameters per item)
| int IGESData_ParamCursor::Limit | ( | ) | const |
Returns (excluded) upper limit number for reading parameters.
| int IGESData_ParamCursor::Offset | ( | ) | const |
Returns offset from which current term must be read in item.
Changes command to advance current cursor after reading parameters. If "advance" True, sets advance, if "False", resets it. ParamCursor is created by default with True.
Defines a term of one Parameter (very current case)
Defines the size of a term to read in the item : this commands ParamReader to read "size" parameters for each item, then skip the remainder of the item to the same term of next Item (that is, skip "item size" - "term size")
In addition, Offset from beginning of Item is managed : After being created, and for the first call to SetTerm, the part of Item to be read begins exactly as the Item begins But after a SetTerm, the next read will add an offset which is the size of former term.
autoadv commands Advance management. If it is True (default), the last SetTerm (Item size has been covered) calls SetAdvance If it is False, SetAdvance must be called directly if necessary
Error if a SetTerm overpasses the size of the Item
Defines a term of two Parameters for a XY (current case)
Defines a term of three Parameters for XYZ (current case)
| int IGESData_ParamCursor::Start | ( | ) | const |
Returns (included) starting number for reading parameters.
| int IGESData_ParamCursor::TermSize | ( | ) | const |
Returns length of current term (count of parameters) in item.