![]() |
Open CASCADE Technology Reference Manual 8.0.0
|
Defines a generally defined Field for STEP data : can be used either in any kind of entity to implement it or in free format entities in a "late-binding" mode A field can have : no value (or derived), a single value of any kind, a list of value : single or double list. More...
#include <StepData_Field.hxx>
Public Member Functions | |
| StepData_Field () | |
| Creates a Field, empty ("no value defined") | |
| StepData_Field (const StepData_Field &other, const bool copy=false) | |
| Creates a Field from another one. If <copy> is True, Handled data (Select,String,List, not entities) are copied. | |
| void | CopyFrom (const StepData_Field &other) |
| Gets the copy of the values of another field. | |
| StepData_Field & | operator= (const StepData_Field &theOther) |
| Assignment. | |
| void | Clear (const int kind=0) |
| Clears the field, to set it as "no value defined" Just before SetList, predeclares it as "any" A Kind can be directly set here to declare a type. | |
| void | SetDerived () |
| Codes a Field as derived (no proper value) | |
| void | SetInt (const int val) |
| Directly sets the Integer value, if its Kind matches Integer, Boolean, Logical, or Enum (does not change Kind) | |
| void | SetInteger (const int val=0) |
| Sets an Integer value (before SetList* declares it as Integer) | |
| void | SetBoolean (const bool val=false) |
| Sets a Boolean value (or predeclares a list as boolean) | |
| void | SetLogical (const StepData_Logical val=StepData_LFalse) |
| Sets a Logical Value (or predeclares a list as logical) | |
| void | SetReal (const double val=0.0) |
| Sets a Real Value (or predeclares a list as Real);. | |
| void | SetString (const char *const val="") |
| Sets a String Value (or predeclares a list as String) Does not redefine the Kind if it is already String or Enum. | |
| void | SetEnum (const int val=-1, const char *const text="") |
| Sets an Enum Value (as its integer counterpart) (or predeclares a list as Enum) If <text> is given , also sets its textual expression <val> negative means unknown (known values begin at 0) | |
| void | SetSelectMember (const occ::handle< StepData_SelectMember > &val) |
| Sets a SelectMember (for Integer,Boolean,Enum,Real,Logical) Hence, the value of the field is accessed through this member. | |
| void | SetEntity (const occ::handle< Standard_Transient > &val) |
| Sets an Entity Value. | |
| void | SetEntity () |
| Predeclares a list as of entity. | |
| void | SetList (const int size, const int first=1) |
| Declares a field as a list, with an initial size Initial lower is defaulted as 1, can be defined The list starts empty, typed by the last Set* If no Set* before, sets it as "any" (transient/select) | |
| void | SetList2 (const int siz1, const int siz2, const int f1=1, const int f2=1) |
| Declares a field as an homogeneous square list, with initial sizes, and initial lowers. | |
| void | Set (const occ::handle< Standard_Transient > &val) |
| Sets an undetermined value : can be String, SelectMember, HArray(1-2) ... else, an Entity In case of an HArray, determines and records its size(s) | |
| void | ClearItem (const int num) |
| Declares an item of the list as undefined (ignored if list not defined as String,Entity or Any) | |
| void | SetInt (const int num, const int val, const int kind) |
| Internal access to an Integer Value for a list, plus its kind. | |
| void | SetInteger (const int num, const int val) |
| Sets an Integer Value for a list (rank num) (recognizes a SelectMember) | |
| void | SetBoolean (const int num, const bool val) |
| void | SetLogical (const int num, const StepData_Logical val) |
| void | SetEnum (const int num, const int val, const char *const text="") |
| Sets an Enum Value (Integer counterpart), also its text expression if known (if list has been set as "any") | |
| void | SetReal (const int num, const double val) |
| void | SetString (const int num, const char *const val) |
| void | SetEntity (const int num, const occ::handle< Standard_Transient > &val) |
| bool | IsSet (const int n1=1, const int n2=1) const |
| int | ItemKind (const int n1=1, const int n2=1) const |
| Returns the kind of an item in a list or double list It is the kind of the list, except if it is "Any", in such a case the true kind is determined and returned. | |
| int | Kind (const bool type=true) const |
| Returns the kind of the field <type> True (D) : returns only the type itself else, returns the complete kind. | |
| int | Arity () const |
| int | Length (const int index=1) const |
| int | Lower (const int index=1) const |
| int | Int () const |
| int | Integer (const int n1=1, const int n2=1) const |
| bool | Boolean (const int n1=1, const int n2=1) const |
| StepData_Logical | Logical (const int n1=1, const int n2=1) const |
| double | Real (const int n1=1, const int n2=1) const |
| const char * | String (const int n1=1, const int n2=1) const |
| int | Enum (const int n1=1, const int n2=1) const |
| const char * | EnumText (const int n1=1, const int n2=1) const |
| occ::handle< Standard_Transient > | Entity (const int n1=1, const int n2=1) const |
| occ::handle< Standard_Transient > | Transient () const |
Defines a generally defined Field for STEP data : can be used either in any kind of entity to implement it or in free format entities in a "late-binding" mode A field can have : no value (or derived), a single value of any kind, a list of value : single or double list.
When a field is set, this defines its new kind (Integer etc..) A single value is immediately set. A list of value is, firstly declared as for a kind (Integer String etc), then declared as a list with its initial size, after this its items are set Also it can be set in once if the HArray is ready
| StepData_Field::StepData_Field | ( | ) |
Creates a Field, empty ("no value defined")
| StepData_Field::StepData_Field | ( | const StepData_Field & | other, |
| const bool | copy = false ) |
Creates a Field from another one. If <copy> is True, Handled data (Select,String,List, not entities) are copied.
| int StepData_Field::Arity | ( | ) | const |
Clears the field, to set it as "no value defined" Just before SetList, predeclares it as "any" A Kind can be directly set here to declare a type.
Declares an item of the list as undefined (ignored if list not defined as String,Entity or Any)
| void StepData_Field::CopyFrom | ( | const StepData_Field & | other | ) |
Gets the copy of the values of another field.
| occ::handle< Standard_Transient > StepData_Field::Entity | ( | const int | n1 = 1, |
| const int | n2 = 1 ) const |
| int StepData_Field::Int | ( | ) | const |
Returns the kind of an item in a list or double list It is the kind of the list, except if it is "Any", in such a case the true kind is determined and returned.
Returns the kind of the field <type> True (D) : returns only the type itself else, returns the complete kind.
| StepData_Logical StepData_Field::Logical | ( | const int | n1 = 1, |
| const int | n2 = 1 ) const |
|
inline |
Assignment.
| void StepData_Field::Set | ( | const occ::handle< Standard_Transient > & | val | ) |
Sets an undetermined value : can be String, SelectMember, HArray(1-2) ... else, an Entity In case of an HArray, determines and records its size(s)
Sets a Boolean value (or predeclares a list as boolean)
| void StepData_Field::SetDerived | ( | ) |
Codes a Field as derived (no proper value)
| void StepData_Field::SetEntity | ( | ) |
Predeclares a list as of entity.
| void StepData_Field::SetEntity | ( | const int | num, |
| const occ::handle< Standard_Transient > & | val ) |
| void StepData_Field::SetEntity | ( | const occ::handle< Standard_Transient > & | val | ) |
Sets an Entity Value.
Sets an Enum Value (Integer counterpart), also its text expression if known (if list has been set as "any")
Sets an Enum Value (as its integer counterpart) (or predeclares a list as Enum) If <text> is given , also sets its textual expression <val> negative means unknown (known values begin at 0)
Internal access to an Integer Value for a list, plus its kind.
Directly sets the Integer value, if its Kind matches Integer, Boolean, Logical, or Enum (does not change Kind)
Sets an Integer Value for a list (rank num) (recognizes a SelectMember)
Sets an Integer value (before SetList* declares it as Integer)
Declares a field as a list, with an initial size Initial lower is defaulted as 1, can be defined The list starts empty, typed by the last Set* If no Set* before, sets it as "any" (transient/select)
| void StepData_Field::SetList2 | ( | const int | siz1, |
| const int | siz2, | ||
| const int | f1 = 1, | ||
| const int | f2 = 1 ) |
Declares a field as an homogeneous square list, with initial sizes, and initial lowers.
| void StepData_Field::SetLogical | ( | const int | num, |
| const StepData_Logical | val ) |
| void StepData_Field::SetLogical | ( | const StepData_Logical | val = StepData_LFalse | ) |
Sets a Logical Value (or predeclares a list as logical)
Sets a Real Value (or predeclares a list as Real);.
| void StepData_Field::SetSelectMember | ( | const occ::handle< StepData_SelectMember > & | val | ) |
Sets a SelectMember (for Integer,Boolean,Enum,Real,Logical) Hence, the value of the field is accessed through this member.
Sets a String Value (or predeclares a list as String) Does not redefine the Kind if it is already String or Enum.
| occ::handle< Standard_Transient > StepData_Field::Transient | ( | ) | const |