OCC.Core.TObj module¶
TObj module, see official documentation at https://www.opencascade.com/doc/occt-7.4.0/refman/html/package_tobj.html
-
class
SwigPyIterator
(*args, **kwargs)¶ Bases:
object
-
advance
()¶
-
copy
()¶
-
decr
()¶
-
distance
()¶
-
equal
()¶
-
incr
()¶
-
next
()¶
-
previous
()¶
-
property
thisown
¶ The membership flag
-
value
()¶
-
-
class
TObj_Application
(*args, **kwargs)¶ Bases:
OCC.Core.TDocStd.TDocStd_Application
Constructs the new instance and registers it in CDM_Session
- Return type
-
CreateNewDocument
()¶ - Create the OCAF document from scratch
- param theDoc
- type theDoc
TDocStd_Document
- param theFormat
- type theFormat
TCollection_ExtendedString
- rtype
bool
-
static
DownCast
(t)¶
-
ErrorMessage
()¶ - Signal error during Load or Save Default imiplementation is empty
- param theMsg
- type theMsg
TCollection_ExtendedString
- param theLevel
- type theLevel
Message_Gravity
- rtype
None* Signal error during Load or Save Default imiplementation invoke previous declaration with 0
- param theMsg
- type theMsg
TCollection_ExtendedString
- rtype
None
-
static
GetInstance
()¶ - Returns static instance of the application
- rtype
opencascade::handle<TObj_Application>
-
IsVerbose
()¶ - Returns the verbose flag
- rtype
bool
-
LoadDocument
()¶ - Loading the OCAF document from a file
- param theSourceFile
- type theSourceFile
TCollection_ExtendedString
- param theTargetDoc
- type theTargetDoc
TDocStd_Document
- rtype
bool
-
Messenger
()¶ - Returns reference to associated messenger handle
- rtype
opencascade::handle<Message_Messenger>
-
SaveDocument
()¶ - /** * Load/Save support */ Saving the OCAF document to a file
- param theSourceDoc
- type theSourceDoc
TDocStd_Document
- param theTargetFile
- type theTargetFile
TCollection_ExtendedString
- rtype
bool
-
SetVerbose
()¶ - Sets the verbose flag, meaning that load/save models should show CPU and elapsed times
- param isVerbose
- type isVerbose
bool
- rtype
None
-
property
thisown
¶ The membership flag
-
class
TObj_Assistant
¶ Bases:
object
-
static
BindModel
()¶ - Binds model to the map
- param theModel
- type theModel
TObj_Model
- rtype
None
-
static
BindType
()¶ - Binds Standard_Type to the map; returns index of bound type
- param theType
- type theType
Standard_Type
- rtype
int
-
static
ClearModelMap
()¶ - Clears all records from the model map
- rtype
None
-
static
ClearTypeMap
()¶ - Clears map of types
- rtype
None
-
static
FindModel
()¶ - /** * Interface for DataMap of Modeller name */ Finds model by name
- param theName
- type theName
char *
- rtype
opencascade::handle<TObj_Model>
-
static
FindType
()¶ - /** * Interface for Map of Standard Types */ Finds Standard_Type by index; returns NULL handle if not found
- param theTypeIndex
- type theTypeIndex
int
- rtype
opencascade::handle<Standard_Type>
-
static
FindTypeIndex
()¶ - Rinds index by Standard_Type; returns 0 if not found
- param theType
- type theType
Standard_Type
- rtype
int
-
static
GetAppVersion
()¶ - Returns the version of application which wrote the currently read document. Returns 0 if it has not been set yet for the current document.
- rtype
int
-
static
GetCurrentModel
()¶ - Returns current model
- rtype
opencascade::handle<TObj_Model>
-
static
SetCurrentModel
()¶ - /** * Interface to the current model */ Sets current model
- param theModel
- type theModel
TObj_Model
- rtype
None
-
static
UnSetCurrentModel
()¶ - Unsets current model
- rtype
None
-
property
thisown
¶ The membership flag
-
static
-
class
TObj_CheckModel
(*args)¶ Bases:
object
- Initialize checker by model
- param theModel
- type theModel
TObj_Model
- rtype
None
-
static
DownCast
(t)¶
-
GetModel
()¶ - Returns the checked model
- rtype
opencascade::handle<TObj_Model>
-
IsToFix
()¶ - Returns true if it is allowed to fix inconsistencies
- rtype
bool
-
Perform
()¶ - Performs all checks. Descendants should call parent method before doing own checks. This implementation checks OCAF references and back references between objects of the model. Returns true if no inconsistencies found.
- rtype
bool
-
SetToFix
()¶ - Sets flag allowing fixing inconsistencies
- param theToFix
- type theToFix
bool
- rtype
None
-
property
thisown
¶ The membership flag
-
class
TObj_DataMapOfNameLabel
(*args)¶ Bases:
object
-
Assign
()¶
-
Bind
()¶
-
Bound
()¶
-
ChangeFind
()¶
-
ChangeSeek
()¶
-
Clear
()¶
-
Exchange
()¶
-
Find
()¶
-
IsBound
()¶
-
ReSize
()¶
-
Seek
()¶
-
Set
()¶
-
Size
()¶
-
UnBind
()¶
-
begin
()¶
-
cbegin
()¶
-
cend
()¶
-
end
()¶
-
property
thisown
¶ The membership flag
-
-
class
TObj_DataMapOfObjectHSequenceOcafObjects
(*args)¶ Bases:
object
-
Assign
()¶
-
Bind
()¶
-
Bound
()¶
-
ChangeFind
()¶
-
ChangeSeek
()¶
-
Clear
()¶
-
Exchange
()¶
-
Find
()¶
-
IsBound
()¶
-
ReSize
()¶
-
Seek
()¶
-
Set
()¶
-
Size
()¶
-
UnBind
()¶
-
begin
()¶
-
cbegin
()¶
-
cend
()¶
-
end
()¶
-
property
thisown
¶ The membership flag
-
-
class
TObj_DataMapOfStringPointer
(*args)¶ Bases:
object
-
Assign
()¶
-
Bind
()¶
-
Bound
()¶
-
ChangeFind
()¶
-
ChangeSeek
()¶
-
Clear
()¶
-
Exchange
()¶
-
Find
()¶
-
IsBound
()¶
-
ReSize
()¶
-
Seek
()¶
-
Set
()¶
-
Size
()¶
-
UnBind
()¶
-
begin
()¶
-
cbegin
()¶
-
cend
()¶
-
end
()¶
-
property
thisown
¶ The membership flag
-
-
class
TObj_HSequenceOfObject
(*args)¶ Bases:
OCC.Core.TObj.TObj_SequenceOfObject
,OCC.Core.Standard.Standard_Transient
Empty constructor
- Return type
None* Copy constructor – does nothing
- Parameters
& (Standard_Transient) –
- Return type
-
Append
()¶
-
ChangeSequence
()¶
-
static
DownCast
(t)¶
-
Sequence
()¶
-
property
thisown
¶ The membership flag
-
class
TObj_HiddenPartition
(*args)¶ Bases:
OCC.Core.TObj.TObj_Partition
- constructor
- param theLabel
- type theLabel
TDF_Label
- rtype
None
-
static
DownCast
(t)¶
-
GetTypeFlags
()¶ - Returns all flags of father except Visible
- rtype
int
-
property
thisown
¶ The membership flag
-
class
TObj_LabelIterator
(*args, **kwargs)¶ Bases:
OCC.Core.TObj.TObj_ObjectIterator
Empty constructor
- Return type
None* Copy constructor – does nothing
- Parameters
& (Standard_Transient) –
- Return type
-
static
DownCast
(t)¶
-
LabelValue
()¶ - Returns the label of the current item
- rtype
inline TDF_Label
-
More
()¶ - /** * Redefined methods */ Returns True if there is a current Item in the iteration.
- rtype
bool
-
Next
()¶ - Move to the next Item
- rtype
None
-
Value
()¶ - Returns the current item
- rtype
opencascade::handle<TObj_Object>
-
property
thisown
¶ The membership flag
-
class
TObj_Model
(*args, **kwargs)¶ Bases:
OCC.Core.Standard.Standard_Transient
Empty constructor
- Return type
None* Copy constructor – does nothing
- Parameters
& (Standard_Transient) –
- Return type
-
AbortCommand
()¶ - Abort the Command transaction. Do nothing If there is no Command transaction open.
- rtype
None
-
CloseDocument
()¶ - Close Free OCAF document
- param theDoc
- type theDoc
TDocStd_Document
- rtype
None
-
CommitCommand
()¶ - Commit the Command transaction. Do nothing If there is no Command transaction open.
- rtype
None
-
CopyReferences
()¶ - Copy references from me to the other
- param theTarget
- type theTarget
TObj_Model
- param theRelocTable
- type theRelocTable
TDF_RelocationTable
- rtype
None
-
static
DownCast
(t)¶
-
FindObject
()¶ - Returns an Object by given Name (or Null if not found).
- param theName
- type theName
TCollection_HExtendedString
- param theDictionary
- type theDictionary
TObj_TNameContainer
- rtype
opencascade::handle<TObj_Object>
-
GetApplication
()¶ - /** * Methods for obtaining application */ Returns handle to static instance of the relevant application class
- rtype
opencascade::handle<TObj_Application>
-
GetChecker
()¶ - Returns the tool checking model consistency. Descendant may redefine it to return its own tool.
- rtype
opencascade::handle<TObj_CheckModel>
-
GetChildren
()¶ - Returns an Iterator on objects in the main partition
- rtype
opencascade::handle<TObj_ObjectIterator>
-
GetDictionary
()¶ - /** * Internal methods */ Returns the map of names of the objects
- rtype
opencascade::handle<TObj_TNameContainer>
-
GetDocument
()¶ - Returns OCAF document of Model
- rtype
opencascade::handle<TDocStd_Document>
-
static
GetDocumentModel
()¶ - Returns model which contains a document with the label, or NULL handle if label is NULL
- param theLabel
- type theLabel
TDF_Label
- rtype
opencascade::handle<TObj_Model>
-
GetFile
()¶ - Returns the full file name this model is to be saved to, or null if the model was not saved yet
- rtype
opencascade::handle<TCollection_HExtendedString>
-
GetFormat
()¶ - /** * Methods for obtaining the version of Format */ Returns the format for save/restore. This implementation returns ‘BinOcaf’. The method should be redefined for those models that should use another format.
- rtype
TCollection_ExtendedString
-
GetFormatVersion
()¶ - Returns the version of format stored in TObj file
- rtype
int
-
GetGUID
()¶ - /** * Definition of interface GUID */ Defines interface GUID for TObj_Model
- rtype
Standard_GUID
-
GetLabel
()¶ - /** * OCAF methods */ Returns OCAF label on which model data are stored.
- rtype
TDF_Label
-
GetMainPartition
()¶ - Returns root object of model
- rtype
opencascade::handle<TObj_Partition>
-
GetModelName
()¶ - /** * Methods for supporting unique naming of the objects in model */ Returns the name of the model
- rtype
opencascade::handle<TCollection_HExtendedString>
-
GetObjects
()¶ - /** * Access to the objects in the model */ Returns an Iterator on all objects in the Model
- rtype
opencascade::handle<TObj_ObjectIterator>
-
GetRoot
()¶ - /** * Methods for iteration on the model */ Returns root object of model
- rtype
opencascade::handle<TObj_Object>
-
HasOpenCommand
()¶ - /** * API for transaction mechanism */ Returns True if a Command transaction is open Starting, finishing the transaction
- rtype
bool
-
IsModified
()¶ - Modification status
- rtype
bool
-
IsRegisteredName
()¶ - Returns True is name is registered in the names map The input argument may be NULL handle, then model check in own global container
- param theName
- type theName
TCollection_HExtendedString
- param theDictionary
- type theDictionary
TObj_TNameContainer
- rtype
bool
-
Load
()¶ - /** * Implementation of Load/Save for OCAF based models */ Load the OCAF model from a file. If the filename is empty or file does not exists, it just initializes model by empty data.
- param theFile
- type theFile
TCollection_ExtendedString
- rtype
bool
-
Messenger
()¶ - Get messenger used for messages output (by default, the messenger from application is used)
- rtype
opencascade::handle<Message_Messenger>
-
NewEmpty
()¶ - This function have to create a new model with type like me
- rtype
opencascade::handle<TObj_Model>
-
OpenCommand
()¶ - Open a new command transaction.
- rtype
None
-
Paste
()¶ - /** * Methods for clone model */ Pastes me to the new model references will not be copied if theRelocTable is not 0 if theRelocTable is not NULL theRelocTable is filled by objects
- param theModel
- type theModel
TObj_Model
- param theRelocTable
default value is 0
- type theRelocTable
TDF_RelocationTable
- rtype
bool
-
RegisterName
()¶ - Register name in the map The input argument may be NULL handle, then model check in own global container
- param theName
- type theName
TCollection_HExtendedString
- param theLabel
- type theLabel
TDF_Label
- param theDictionary
- type theDictionary
TObj_TNameContainer
- rtype
None
-
Save
()¶ - Save the model to the same file
- rtype
bool
-
SaveAs
()¶ - Save the model to a file
- param theFile
- type theFile
TCollection_ExtendedString
- rtype
bool
-
SetLabel
()¶ - Sets OCAF label on which model data are stored. Used by persistence mechanism.
- param theLabel
- type theLabel
TDF_Label
- rtype
None
-
SetMessenger
()¶ - /** * Messages mechanism */ Set messenger to use for messages output
- param theMsgr
- type theMsgr
Message_Messenger
- rtype
None
-
SetModified
()¶ - Sets modification status
- param theModified
- type theModified
bool
- rtype
None
-
static
SetNewName
()¶ - Sets new unique name for the object
- param theObject
- type theObject
TObj_Object
- rtype
None
-
UnRegisterName
()¶ - Unregisters name from the map The input argument may be NULL handle, then model check in own global container
- param theName
- type theName
TCollection_HExtendedString
- param theDictionary
- type theDictionary
TObj_TNameContainer
- rtype
None
-
Update
()¶ - /** * Methods for updating model */ this method is called before activating this model
- rtype
bool
-
property
thisown
¶ The membership flag
-
class
TObj_ModelIterator
(*args)¶ Bases:
OCC.Core.TObj.TObj_ObjectIterator
- /** * Constructor */ Creates Iterator and initialize it by Model`s label
- param theModel
- type theModel
TObj_Model
- rtype
None
-
static
DownCast
(t)¶
-
More
()¶ - /** * Methods to iterate on objects. */ Returns True if iteration is not finished and method Value() will give the object
- rtype
bool
-
Next
()¶ - Iterates to the next object
- rtype
None
-
Value
()¶ - Returns current object (or MainObj of Model if iteration has finished)
- rtype
opencascade::handle<TObj_Object>
-
property
thisown
¶ The membership flag
-
class
TObj_Object
(*args, **kwargs)¶ Bases:
OCC.Core.Standard.Standard_Transient
Empty constructor
- Return type
None* Copy constructor – does nothing
- Parameters
& (Standard_Transient) –
- Return type
-
AddBackReference
()¶ - Registers another object as being dependent on this one. Stores back references under sublabel 2 (purely transient data, not subject to persistency).
- param theObject
- type theObject
TObj_Object
- rtype
None
-
AfterRetrieval
()¶ - /** * Method for updating object afrer restoring */ Preforms updating the links and dependances of the object which are not stored in persistence. Should be redefined if necessary.
- rtype
None
-
BeforeForgetReference
()¶ - Invokes from TObj_TReference::BeforeForget(). theLabel - label on that reference become removed Default implementation is empty
- param &
- type &
TDF_Label
- rtype
None
-
BeforeStoring
()¶ - Preforms storing the objects transient fields in OCAF document which were outside transaction mechanism. Default implementation doesnot nothing
- rtype
None
-
CanDetach
()¶ - /** * Methods for deleting the object */ Checks if object can be detached with specified mode
- param theMode
default value is TObj_FreeOnly
- type theMode
TObj_DeletingMode
- rtype
bool
-
CanRemoveReference
()¶ - Returns True if the referred object theObject can be deleted without deletion of this object. Default implementation does nothing and returns False.
- param theObject
- type theObject
TObj_Object
- rtype
bool
-
ClearBackReferences
()¶ - The default implementation just clear the back references container
- rtype
None
-
ClearFlags
()¶ - clears flags by the mask.
- param theMask
default value is ~0
- type theMask
int
- rtype
None
-
Clone
()¶ - /** * Cloning related methods */ Copy me to other label theTargetLabel New object will not have all the reference that has me. Coping object with data and childs, but change name by adding string ‘_copy’ As result return handle of new object (null handle is something wrong) NOTE: BackReferences not coping. After clonning all objects it is neccessary to call copy references with the same relocation table
- param theTargetLabel
- type theTargetLabel
TDF_Label
- param theRelocTable
default value is 0
- type theRelocTable
TDF_RelocationTable
- rtype
opencascade::handle<TObj_Object>
-
CopyChildren
()¶ - Coping the children from source label to the target.
- param theTargetLabel
- type theTargetLabel
TDF_Label
- param theRelocTable
- type theRelocTable
TDF_RelocationTable
- rtype
None
-
CopyReferences
()¶ - Coping the references. return Standard_False is Target object is different type
- param theTargetObject
- type theTargetObject
TObj_Object
- param theRelocTable
- type theRelocTable
TDF_RelocationTable
- rtype
None
-
static
Detach
()¶ - Deletes the object from the model. The dependent objects are either deleted or modified when possible (see description of TObj_DeletingMode enumeration for more details) Returns True if deletion was successful. Checks if object can be deleted. Should be redefined for each specific kind of object
- param theMode
default value is TObj_FreeOnly
- type theMode
TObj_DeletingMode
- rtype
bool* Deletes the object from the label. Checks if object can be deleted. Finds object on the label and detaches it by calling previos method. Returns true if there is no object on the label after detaching
- param theLabel
- type theLabel
TDF_Label
- param theMode
default value is TObj_FreeOnly
- type theMode
TObj_DeletingMode
- rtype
bool
-
static
DownCast
(t)¶
-
GetBackReferences
()¶ - Returns iterator for the objects which depend on this one. These reffering objects may belong to other models. theType narrows a variety of iterated objects
- param theType
default value is NULL
- type theType
Standard_Type
- rtype
opencascade::handle<TObj_ObjectIterator>
-
GetBadReference
()¶ - Return True if this refers to the model theRoot belongs to and a referred label is not a descendant of theRoot. In this case theBadReference returns the currently referred label.
- param theRoot
- type theRoot
TDF_Label
- param theBadReference
- type theBadReference
TDF_Label
- rtype
bool
-
GetChildLabel
()¶ - Returns the label under which children are stored
- rtype
TDF_Label
-
GetChildren
()¶ - Returns iterator for the child objects. This method provides tree-like view of the objects hierarchy. The references to other objects are not considered as children. theType narrows a variety of iterated objects The default implementation search for children on 1 sublavel of the children sub label
- param theType
default value is NULL
- type theType
Standard_Type
- rtype
opencascade::handle<TObj_ObjectIterator>
-
GetDataLabel
()¶ - Returns the label which is the root for data OCAF sub-tree
- rtype
TDF_Label
-
GetDictionary
()¶ - /** * Methods hanling name of the object */ Returns the map of names of the objects Default implementation returns global Dictionary of the model
- rtype
opencascade::handle<TObj_TNameContainer>
-
GetFatherObject
()¶ - Returns the father object, which may be NULL theType gives type of father object to search
- param theType
default value is NULL
- type theType
Standard_Type
- rtype
opencascade::handle<TObj_Object>
-
GetFlags
()¶ - Returns mask of seted flags
- rtype
int
-
GetLabel
()¶ - /** * Access to the OCAF-specific data */ Returns the OCAF label on which object`s data are stored
- rtype
TDF_Label
-
GetModel
()¶ - /** * Virtual methods */ Returns the model to which the object belongs
- rtype
opencascade::handle<TObj_Model>
-
GetName
()¶ - Returns the name of the object (empty string if object has no name)
- rtype
opencascade::handle<TCollection_HExtendedString>* Returns the Standard_True is object has name and returns name to theName
- param theName
- type theName
TCollection_ExtendedString
- rtype
bool* Returns the Standard_True is object has name and returns name to theName
- param theName
- type theName
TCollection_AsciiString
- rtype
bool
-
GetNameForClone
()¶ - Returns name for copy default implementation returns the same name
- param &
- type &
TObj_Object
- rtype
opencascade::handle<TCollection_HExtendedString>
-
static
GetObj
()¶ - /** * methods for object retrieval */ Returns the Object attached to a given label. Returns False if no object of type TObj_Object is stored on the specified label. If isSuper is true tries to find on the super labels.
- param theLabel
- type theLabel
TDF_Label
- param theResult
- type theResult
TObj_Object
- param isSuper
default value is Standard_False
- type isSuper
bool
- rtype
bool
-
GetOrder
()¶ - /** * Public methods to access order of object */ returns order of object (or tag of their label if order is not initialised)
- rtype
int
-
GetReferenceLabel
()¶ - Returns the label which is the root for reference OCAF sub-tree
- rtype
TDF_Label
-
GetReferences
()¶ - Returns an Iterator containing objects that compose the this one theType narrows a variety of iterated objects
- param theType
default value is NULL
- type theType
Standard_Type
- rtype
opencascade::handle<TObj_ObjectIterator>
-
GetTypeFlags
()¶ - /** * Access to object flags */ Returns flags (bitmask) that define properties of objects of that type By default returns flag Visible
- rtype
int
-
HasBackReferences
()¶ - Returns True if obejct has 1 or more back references
- rtype
bool
-
HasReference
()¶ - /** * Analysis of dependencies on other objects */ Returns True if object has reference to indicated object
- param theObject
- type theObject
TObj_Object
- rtype
bool
-
IsAlive
()¶ - /** * Methods for checking and Updating object */ Checks that object alive in model Default implementation checks that object has TObject attribute at own label.
- rtype
bool
-
ObjectState_Hidden
= 1¶
-
ObjectState_Imported
= 4¶
-
ObjectState_ImportedByFile
= 8¶
-
ObjectState_Ordered
= 16¶
-
ObjectState_Saved
= 2¶
-
RelocateReferences
()¶ - Make that each reference pointing to a descendant label of theFromRoot to point to an equivalent label under theToRoot. Return False if a resulting reference does not point to an TObj_Object Example: a referred object label = 0:3:24:7:2:7 theFromRoot = 0:3:24 theToRoot = 0:2 a new referred label = 0:2:7:2:7
- param theFromRoot
- type theFromRoot
TDF_Label
- param theToRoot
- type theToRoot
TDF_Label
- param theUpdateBackRefs
default value is Standard_True
- type theUpdateBackRefs
bool
- rtype
bool
-
RemoveAllReferences
()¶ - Remove all references to other objects, by removing all reference attributes
- rtype
None
-
RemoveBackReference
()¶ - Removes information on dependent object (back reference). If theSingleOnly is true only the first back reference is removed in the case of duplicate items.
- param theObject
- type theObject
TObj_Object
- param theSingleOnly
default value is Standard_True
- type theSingleOnly
bool
- rtype
None
-
RemoveBackReferences
()¶ - Removes all back reference by removing references from other to me.
- param theMode
default value is TObj_FreeOnly
- type theMode
TObj_DeletingMode
- rtype
bool
-
RemoveReference
()¶ - Removes reference to the object by replace reference to NULL object
- param theObject
- type theObject
TObj_Object
- rtype
None
-
ReplaceReference
()¶ - Replace reference from old object to new object. If it is not possible, may raise exception. If new object is null then simple remove reference to old object.
- param theOldObject
- type theOldObject
TObj_Object
- param theNewObject
- type theNewObject
TObj_Object
- rtype
None
-
SetFlags
()¶ - Sets flags with defined mask.
- param theMask
- type theMask
int
- rtype
None
-
SetName
()¶ - Sets name of the object. Returns False if theName is not unique.
- param theName
- type theName
TCollection_HExtendedString
- rtype
bool* Sets name of the object. Returns False if theName is not unique.
- param theName
- type theName
TCollection_HAsciiString
- rtype
bool* Sets name of the object. Returns False if theName is not unique.
- param name
- type name
char *
- rtype
bool
-
SetOrder
()¶ - sets order of object
- param theIndx
- type theIndx
int
- rtype
bool
-
TestFlags
()¶ - tests flags by the mask.
- param theMask
- type theMask
int
- rtype
bool
-
Visible
= 1¶
-
getChildLabel
()¶ - Returns the label for child with rank
- param theRank
- type theRank
int
- rtype
TDF_Label
-
property
thisown
¶ The membership flag
-
class
TObj_ObjectIterator
¶ Bases:
OCC.Core.Standard.Standard_Transient
Empty constructor
- Return type
None* Copy constructor – does nothing
- Parameters
& (Standard_Transient) –
- Return type
-
static
DownCast
(t)¶
-
More
()¶ - Returns True if iteration is not finished and method Current() will give the object. Default implementation returns False
- rtype
bool
-
Next
()¶ - Iterates to the next object Default implementation does nothing
- rtype
None
-
Value
()¶ - Returns current object (or null if iteration has finished) Default implementation returns null handle
- rtype
opencascade::handle<TObj_Object>
-
property
thisown
¶ The membership flag
-
class
TObj_OcafObjectIterator
(*args)¶ Bases:
OCC.Core.TObj.TObj_LabelIterator
- /** * Constructor */ Creates the iterator on objects in the sub labels of theLabel theType narrows a variety of iterated objects
- param theLabel
- type theLabel
TDF_Label
- param theType
default value is NULL
- type theType
Standard_Type
- param theRecursive
default value is Standard_False
- type theRecursive
bool
- rtype
None
-
static
DownCast
(t)¶
-
property
thisown
¶ The membership flag
-
class
TObj_Partition
(*args, **kwargs)¶ Bases:
OCC.Core.TObj.TObj_Object
Empty constructor
- Return type
None* Copy constructor – does nothing
- Parameters
& (Standard_Transient) –
- Return type
-
AfterRetrieval
()¶ - /** * Method for updating object afrer restoring */ Preforms updating the links and dependances of the object which are not stored in persistence. Does not register the partition name
- rtype
None
-
static
Create
()¶ - /** * Method for create partition */ Creates a new partition on given label.
- param theLabel
- type theLabel
TDF_Label
- rtype
opencascade::handle<TObj_Partition>
-
static
DownCast
(t)¶
-
GetLastIndex
()¶ - Return Last index in partition (reserved);
- rtype
int
-
GetNamePrefix
()¶ - Returns prefix for names of the objects in partition.
- rtype
opencascade::handle<TCollection_HExtendedString>
-
GetNewName
()¶ - Generates and returns name for new object in partition. if theIsToChangeCount is true partition icrease own counter to generate new name next time starting from new counter value
- param theIsToChangeCount
default value is Standard_True
- type theIsToChangeCount
bool
- rtype
opencascade::handle<TCollection_HExtendedString>
-
static
GetPartition
()¶ - /** * Methods to define partition by object */ Returns the partition in which object is stored. Null partition returned if not found
- param theObject
- type theObject
TObj_Object
- rtype
opencascade::handle<TObj_Partition>
-
NewLabel
()¶ - /** * Methods handling of the objects in partition */ Creates and Returns label for new object in partition.
- rtype
TDF_Label
-
SetLastIndex
()¶ - Sets Last index in partition (reserved);
- param theIndex
- type theIndex
int
- rtype
None
-
SetName
()¶ - /** * Methods hanling name of the object */ Sets name of the object. partition does not check unique of own name
- param theName
- type theName
TCollection_HExtendedString
- rtype
bool
-
SetNamePrefix
()¶ - Sets prefix for names of the objects in partition.
- param thePrefix
- type thePrefix
TCollection_HExtendedString
- rtype
None
-
property
thisown
¶ The membership flag
-
class
TObj_Persistence
(*args, **kwargs)¶ Bases:
object
-
static
CreateNewObject
()¶ - /** * Public methods, to be called externally */ Creates and returns a new object of the registered type If the type is not registered, returns Null handle
- param theType
- type theType
char *
- param theLabel
- type theLabel
TDF_Label
- rtype
opencascade::handle<TObj_Object>
-
DumpTypesToString
(TObj_Persistence self) → std::string¶
-
property
thisown
¶ The membership flag
-
static
-
class
TObj_ReferenceIterator
(*args)¶ Bases:
OCC.Core.TObj.TObj_LabelIterator
- Creates the iterator on references in partition theType narrows a variety of iterated objects
- param theLabel
- type theLabel
TDF_Label
- param theType
default value is NULL
- type theType
Standard_Type
- param theRecursive
default value is Standard_True
- type theRecursive
bool
- rtype
None
-
static
DownCast
(t)¶
-
property
thisown
¶ The membership flag
-
class
TObj_SequenceIterator
(*args)¶ Bases:
OCC.Core.TObj.TObj_ObjectIterator
- /** * Constructor */ Creates an iterator an initialize it by sequence of objects.
- param theObjects
- type theObjects
TObj_HSequenceOfObject
- param theType
default value is NULL
- type theType
Standard_Type
- rtype
None
-
static
DownCast
(t)¶
-
More
()¶ - /** * Redefined methods */ Returns True if there is a current Item in the iteration.
- rtype
bool
-
Next
()¶ - Move to the next Item
- rtype
None
-
Value
()¶ - Returns the current item
- rtype
opencascade::handle<TObj_Object>
-
property
thisown
¶ The membership flag
-
class
TObj_SequenceOfIterator
(*args)¶ Bases:
object
-
Append
()¶
-
Assign
()¶
-
ChangeFirst
()¶
-
ChangeLast
()¶
-
ChangeValue
()¶
-
Clear
()¶
-
Exchange
()¶
-
First
()¶
-
InsertAfter
()¶
-
InsertBefore
()¶
-
IsEmpty
()¶
-
Last
()¶
-
Length
()¶
-
Lower
()¶
-
Prepend
()¶
-
Remove
()¶
-
Reverse
()¶
-
Set
()¶
-
SetValue
()¶
-
Size
()¶
-
Split
()¶
-
Upper
()¶
-
Value
()¶
-
begin
()¶
-
cbegin
()¶
-
cend
()¶
-
static
delNode
()¶
-
end
()¶
-
property
thisown
¶ The membership flag
-
-
class
TObj_SequenceOfObject
(*args)¶ Bases:
object
-
Append
()¶
-
Assign
()¶
-
ChangeFirst
()¶
-
ChangeLast
()¶
-
ChangeValue
()¶
-
Clear
()¶
-
Exchange
()¶
-
First
()¶
-
InsertAfter
()¶
-
InsertBefore
()¶
-
IsEmpty
()¶
-
Last
()¶
-
Length
()¶
-
Lower
()¶
-
Prepend
()¶
-
Remove
()¶
-
Reverse
()¶
-
Set
()¶
-
SetValue
()¶
-
Size
()¶
-
Split
()¶
-
Upper
()¶
-
Value
()¶
-
begin
()¶
-
cbegin
()¶
-
cend
()¶
-
static
delNode
()¶
-
end
()¶
-
property
thisown
¶ The membership flag
-
-
class
TObj_TIntSparseArray
(*args)¶ Bases:
OCC.Core.TDF.TDF_Attribute
- Empty constructor
- rtype
None
-
Clear
()¶ - Clears the set
- rtype
None
-
static
DownCast
(t)¶
-
static
GetID
()¶ - This method is used in implementation of ID()
- rtype
Standard_GUID
-
GetIterator
()¶ - Returns iterator on objects contained in the set
- rtype
Iterator
-
HasValue
()¶ - Returns true if the value with the given ID is present.
- param theId
- type theId
Standard_Size
- rtype
bool
-
static
Set
()¶ - Creates TObj_TIntSparseArray attribute on given label.
- param theLabel
- type theLabel
TDF_Label
- rtype
opencascade::handle<TObj_TIntSparseArray>
-
SetDoBackup
()¶ - Methods to handle the modification delta Sets the flag pointing to the necessity to maintain a modification delta. It is called by the retrieval driver
- param toDo
- type toDo
bool
- rtype
None
-
SetValue
()¶ - Sets the value with the given ID. Raises an exception if theId is not positive
- param theId
- type theId
Standard_Size
- param theValue
- type theValue
int
- rtype
None
-
Size
()¶ - Methods for access to data Returns the number of stored values in the set
- rtype
Standard_Size
-
UnsetValue
()¶ - Unsets the value with the given ID. Raises an exception if theId is not positive
- param theId
- type theId
Standard_Size
- rtype
None
-
Value
()¶ - Returns the value by its ID. Raises an exception if no value is stored with this ID
- param theId
- type theId
Standard_Size
- rtype
int
-
property
thisown
¶ The membership flag
-
class
TObj_TIntSparseArray_MapOfData
(theIncrement: Standard_Size)¶ Bases:
object
-
Assign
()¶
-
Bind
()¶
-
ChangeFind
()¶
-
ChangeValue
()¶
-
Exchange
()¶
-
Extent
()¶
-
Find
()¶
-
IsBound
()¶
-
IsEmpty
()¶
-
SetValue
()¶
-
UnBind
()¶
-
Value
()¶
-
property
thisown
¶ The membership flag
-
-
class
TObj_TIntSparseArray_VecOfData
(theIncrement: Standard_Size)¶ Bases:
object
-
Assign
()¶
-
Bind
()¶
-
ChangeFind
()¶
-
ChangeValue
()¶
-
Exchange
()¶
-
Extent
()¶
-
Find
()¶
-
IsBound
()¶
-
IsEmpty
()¶
-
SetValue
()¶
-
UnBind
()¶
-
Value
()¶
-
property
thisown
¶ The membership flag
-
-
class
TObj_TModel
(*args)¶ Bases:
OCC.Core.TDF.TDF_Attribute
- /** * Standard methods of attribute */ Empty constructor
- rtype
None
-
static
DownCast
(t)¶
-
static
GetID
()¶ - This method is used in implementation of ID()
- rtype
Standard_GUID
-
Model
()¶ - Returns the Model object
- rtype
opencascade::handle<TObj_Model>
-
Set
()¶ - Methods for setting and obtaining the Model object Sets the the Model object
- param theModel
- type theModel
TObj_Model
- rtype
None
-
property
thisown
¶ The membership flag
-
class
TObj_TNameContainer
(*args)¶ Bases:
OCC.Core.TDF.TDF_Attribute
- Standard methods of OCAF attribute Empty constructor
- rtype
None
-
Clear
()¶ - Remove all names registered in container
- rtype
None
-
static
DownCast
(t)¶
-
Get
()¶ - Returns the TObj_DataMapOfNameLabel object
- rtype
TObj_DataMapOfNameLabel
-
static
GetID
()¶ - This method is used in implementation of ID()
- rtype
Standard_GUID
-
IsRegistered
()¶ - Return True is theName is registered in the Map
- param theName
- type theName
TCollection_HExtendedString
- rtype
bool
-
RecordName
()¶ - Methods for adding and removing names Records name with label attached
- param theName
- type theName
TCollection_HExtendedString
- param theLabel
- type theLabel
TDF_Label
- rtype
None
-
RemoveName
()¶ - Remove name from the map
- param theName
- type theName
TCollection_HExtendedString
- rtype
None
-
Set
()¶ - Method for create TObj_TNameContainer object Creates TObj_DataMapOfNameLabel attribute on given label if not exist
- param theLabel
- type theLabel
TDF_Label
- rtype
opencascade::handle<TObj_TNameContainer>* Methods for setting and obtaining TObj_TNameContainer Sets the TObj_DataMapOfNameLabel object
- param theElem
- type theElem
TObj_DataMapOfNameLabel
- rtype
None
-
property
thisown
¶ The membership flag
-
class
TObj_TObject
(*args)¶ Bases:
OCC.Core.TDF.TDF_Attribute
- Standard methods of OCAF attribute Empty constructor
- rtype
None
-
static
DownCast
(t)¶
-
Get
()¶ - Returns the TObj_Object object
- rtype
opencascade::handle<TObj_Object>
-
static
GetID
()¶ - This method is used in implementation of ID()
- rtype
Standard_GUID
-
Set
()¶ - Method for create TObj_TObject object Creates TObj_TObject attribute on given label
- param theLabel
- type theLabel
TDF_Label
- param theElem
- type theElem
TObj_Object
- rtype
opencascade::handle<TObj_TObject>* Methods for setting and obtaining TObj_Object Sets the TObj_Object object
- param theElem
- type theElem
TObj_Object
- rtype
None
-
property
thisown
¶ The membership flag
-
class
TObj_TReference
(*args)¶ Bases:
OCC.Core.TDF.TDF_Attribute
- Standard methods of OCAF attribute Empty constructor
- rtype
None
-
static
DownCast
(t)¶
-
Get
()¶ - Returns the referenced theObject
- rtype
opencascade::handle<TObj_Object>
-
static
GetID
()¶ - This method is used in implementation of ID()
- rtype
Standard_GUID
-
GetLabel
()¶ - Returns the referred label.
- rtype
TDF_Label
-
GetMasterLabel
()¶ - Returns the Label of master object.
- rtype
TDF_Label
-
Set
()¶ - Method for create TObj_TReference object Creates reference on TDF_Label <theLabel> to the object <theObject> and creates backreference from the object <theObject> to <theMaster> one.
- param theLabel
- type theLabel
TDF_Label
- param theObject
- type theObject
TObj_Object
- param theMaster
- type theMaster
TObj_Object
- rtype
opencascade::handle<TObj_TReference>* Methods for setting and obtaining referenced object Sets the reference to the theObject
- param theObject
- type theObject
TObj_Object
- param theMasterLabel
- type theMasterLabel
TDF_Label
- rtype
None* Sets the reference to the theObject at indicated Label. It is method for persistent only. Don`t use anywhere else.
- param theLabel
- type theLabel
TDF_Label
- param theMasterLabel
- type theMasterLabel
TDF_Label
- rtype
None
-
property
thisown
¶ The membership flag
-
class
TObj_TXYZ
(*args)¶ Bases:
OCC.Core.TDF.TDF_Attribute
- Standard methods of OCAF attribute Empty constructor
- rtype
None
-
static
DownCast
(t)¶
-
DumpToString
(TObj_TXYZ self) → std::string¶
-
Get
()¶ - Returns the XYZ
- rtype
gp_XYZ
-
static
GetID
()¶ - This method is used in implementation of ID()
- rtype
Standard_GUID
-
Set
()¶ - Method for create TObj_TXYZ object Creates attribute and sets the XYZ
- param theLabel
- type theLabel
TDF_Label
- param theXYZ
- type theXYZ
gp_XYZ
- rtype
opencascade::handle<TObj_TXYZ>* Methods for setting and obtaining XYZ Sets the XYZ
- param theXYZ
- type theXYZ
gp_XYZ
- rtype
None
-
property
thisown
¶ The membership flag