OCC.TopLoc module

class Handle_TopLoc_Datum3D(*args)

Bases: OCC.MMgt.Handle_MMgt_TShared

static DownCast()
GetObject()
IsNull()
Nullify()
thisown

The membership flag

class Handle_TopLoc_IndexedMapNodeOfIndexedMapOfLocation(*args)

Bases: OCC.TCollection.Handle_TCollection_MapNode

static DownCast()
GetObject()
IsNull()
Nullify()
thisown

The membership flag

class Handle_TopLoc_SListNodeOfItemLocation(*args)

Bases: OCC.MMgt.Handle_MMgt_TShared

static DownCast()
GetObject()
IsNull()
Nullify()
thisown

The membership flag

class Handle_TopLoc_StdMapNodeOfMapOfLocation(*args)

Bases: OCC.TCollection.Handle_TCollection_MapNode

static DownCast()
GetObject()
IsNull()
Nullify()
thisown

The membership flag

class SwigPyIterator(*args, **kwargs)

Bases: object

advance()
copy()
decr()
distance()
equal()
incr()
next()
previous()
thisown

The membership flag

value()
class TopLoc_Datum3D(*args)

Bases: OCC.MMgt.MMgt_TShared

  • Constructs a default Datum3D.
Return type:None
  • Constructs a Datum3D form a Trsf from gp. An error is raised if the Trsf is not a rigid transformation.
Parameters:T (gp_Trsf) –
Return type:None
GetHandle()
ShallowDumpToString()

TopLoc_Datum3D_ShallowDumpToString(TopLoc_Datum3D self) -> std::string

Transformation()
  • Returns a gp_Trsf which, when applied to this datum, produces the default datum.
Return type:gp_Trsf
thisown

The membership flag

class TopLoc_IndexedMapNodeOfIndexedMapOfLocation(*args)

Bases: OCC.TCollection.TCollection_MapNode

Parameters:
  • K1 (TopLoc_Location &) –
  • K2 (int) –
  • n1 (TCollection_MapNodePtr &) –
  • n2 (TCollection_MapNodePtr &) –
Return type:

None

GetHandle()
GetKey2()

TopLoc_IndexedMapNodeOfIndexedMapOfLocation_GetKey2(TopLoc_IndexedMapNodeOfIndexedMapOfLocation self) -> Standard_Integer

Key1()
Return type:TopLoc_Location
Next2()
Return type:TCollection_MapNodePtr
SetKey2()

TopLoc_IndexedMapNodeOfIndexedMapOfLocation_SetKey2(TopLoc_IndexedMapNodeOfIndexedMapOfLocation self, Standard_Integer value)

thisown

The membership flag

class TopLoc_IndexedMapOfLocation(*args)

Bases: OCC.TCollection.TCollection_BasicMap

Parameters:
  • NbBuckets (int) – default value is 1
  • Other (TopLoc_IndexedMapOfLocation &) –
Return type:

None

Return type:

None

Add()
Parameters:K (TopLoc_Location &) –
Return type:int
Assign()
Parameters:Other (TopLoc_IndexedMapOfLocation &) –
Return type:TopLoc_IndexedMapOfLocation
Clear()
Return type:None
Contains()
Parameters:K (TopLoc_Location &) –
Return type:bool
FindIndex()
Parameters:K (TopLoc_Location &) –
Return type:int
FindKey()
Parameters:I (int) –
Return type:TopLoc_Location
ReSize()
Parameters:NbBuckets (int) –
Return type:None
RemoveLast()
Return type:None
Set()
Parameters:Other (TopLoc_IndexedMapOfLocation &) –
Return type:TopLoc_IndexedMapOfLocation
Substitute()
Parameters:
  • I (int) –
  • K (TopLoc_Location &) –
Return type:

None

thisown

The membership flag

class TopLoc_ItemLocation(*args)

Bases: object

  • Sets the elementary Datum to <D> Sets the exponent to <P>
Parameters:
  • D (Handle_TopLoc_Datum3D &) –
  • P (int) –
  • fromTrsf (bool) – default value is Standard_False
  • anOther (TopLoc_ItemLocation &) –
Return type:

None

Return type:

None

Assign()
Parameters:anOther (TopLoc_ItemLocation &) –
Return type:TopLoc_ItemLocation
Destroy()
Return type:None
Set()
Parameters:anOther (TopLoc_ItemLocation &) –
Return type:TopLoc_ItemLocation
thisown

The membership flag

class TopLoc_Location(*args)

Bases: object

  • Constructs an empty local coordinate system object. Note: A Location constructed from a default datum is said to be ‘empty’.
Return type:None
  • Constructs the local coordinate system object defined by the transformation T. T invokes in turn, a TopLoc_Datum3D object.
Parameters:T (gp_Trsf) –
Return type:None
  • Constructs the local coordinate system object defined by the 3D datum D. Exceptions Standard_ConstructionError if the transformation T does not represent a 3D coordinate system.
Parameters:D (Handle_TopLoc_Datum3D &) –
Return type:None
Divided()
  • Returns <self> / <Other>.
Parameters:Other (TopLoc_Location &) –
Return type:TopLoc_Location
FirstDatum()
  • Returns the first elementary datum of the Location. Use the NextLocation function recursively to access the other data comprising this location. Exceptions Standard_NoSuchObject if this location is empty.
Return type:Handle_TopLoc_Datum3D
FirstPower()
  • Returns the power elevation of the first elementary datum. Exceptions Standard_NoSuchObject if this location is empty.
Return type:int
HashCode()
  • Returns a hashed value for this local coordinate system. This value is used, with map tables, to store and retrieve the object easily, and is in the range [ 1..Upper ].
Parameters:Upper (int) –
Return type:int
Identity()
  • Resets this location to the Identity transformation.
Return type:None
Inverted()
  • Returns the inverse of <self>. //! <self> * Inverted() is an Identity.
Return type:TopLoc_Location
IsDifferent()
  • Returns true if this location and the location Other do not have the same elementary data, i.e. do not contain the same series of TopLoc_Datum3D and respective powers. This method is an alias for operator !=.
Parameters:Other (TopLoc_Location &) –
Return type:bool
IsEqual()
  • Returns true if this location and the location Other have the same elementary data, i.e. contain the same series of TopLoc_Datum3D and respective powers. This method is an alias for operator ==.
Parameters:Other (TopLoc_Location &) –
Return type:bool
IsIdentity()
  • Returns true if this location is equal to the Identity transformation.
Return type:bool
Multiplied()
  • Returns <self> * <Other>, the elementary datums are concatenated.
Parameters:Other (TopLoc_Location &) –
Return type:TopLoc_Location
NextLocation()
  • Returns a Location representing <self> without the first datum. We have the relation : //! <self> = NextLocation() * FirstDatum() ^ FirstPower() Exceptions Standard_NoSuchObject if this location is empty.
Return type:TopLoc_Location
Powered()
  • Returns me at the power <pwr>. If <pwr> is zero returns Identity. <pwr> can be lower than zero (usual meaning for powers).
Parameters:pwr (int) –
Return type:TopLoc_Location
Predivided()
  • Returns <Other>.Inverted() * <self>.
Parameters:Other (TopLoc_Location &) –
Return type:TopLoc_Location
ShallowDumpToString()

TopLoc_Location_ShallowDumpToString(TopLoc_Location self) -> std::string

Transformation()
  • Returns the transformation associated to the coordinate system.
Return type:gp_Trsf
thisown

The membership flag

class TopLoc_MapIteratorOfMapOfLocation(*args)

Bases: OCC.TCollection.TCollection_BasicMapIterator

Return type:None
Parameters:aMap (TopLoc_MapOfLocation &) –
Return type:None
Initialize()
Parameters:aMap (TopLoc_MapOfLocation &) –
Return type:None
Key()
Return type:TopLoc_Location
thisown

The membership flag

class TopLoc_MapLocationHasher

Bases: object

static HashCode(*args)
Parameters:
  • K (TopLoc_Location &) –
  • Upper (int) –
Return type:

int

static IsEqual(*args)
Parameters:
  • K1 (TopLoc_Location &) –
  • K2 (TopLoc_Location &) –
Return type:

bool

thisown

The membership flag

TopLoc_MapLocationHasher_HashCode(*args)
Parameters:
  • K (TopLoc_Location &) –
  • Upper (int) –
Return type:

int

TopLoc_MapLocationHasher_IsEqual(*args)
Parameters:
  • K1 (TopLoc_Location &) –
  • K2 (TopLoc_Location &) –
Return type:

bool

class TopLoc_MapOfLocation(*args)

Bases: OCC.TCollection.TCollection_BasicMap

Parameters:
  • NbBuckets (int) – default value is 1
  • Other (TopLoc_MapOfLocation &) –
Return type:

None

Return type:

None

Add()
Parameters:aKey (TopLoc_Location &) –
Return type:bool
Assign()
Parameters:Other (TopLoc_MapOfLocation &) –
Return type:TopLoc_MapOfLocation
Clear()
Return type:None
Contains()
Parameters:aKey (TopLoc_Location &) –
Return type:bool
ReSize()
Parameters:NbBuckets (int) –
Return type:None
Remove()
Parameters:aKey (TopLoc_Location &) –
Return type:bool
Set()
Parameters:Other (TopLoc_MapOfLocation &) –
Return type:TopLoc_MapOfLocation
thisown

The membership flag

class TopLoc_SListNodeOfItemLocation(*args)

Bases: OCC.MMgt.MMgt_TShared

Parameters:
  • I (TopLoc_ItemLocation &) –
  • aTail (TopLoc_SListOfItemLocation &) –
Return type:

None

GetHandle()
Tail()
Return type:TopLoc_SListOfItemLocation
Value()
Return type:TopLoc_ItemLocation
thisown

The membership flag

class TopLoc_SListOfItemLocation(*args)

Bases: object

  • Creates an empty List.
Return type:None
  • Creates a List with <anItem> as value and <aTail> as tail.
Parameters:
  • anItem (TopLoc_ItemLocation &) –
  • aTail (TopLoc_SListOfItemLocation &) –
Return type:

None

  • Creates a list from an other one. The lists are shared.
Parameters:Other (TopLoc_SListOfItemLocation &) –
Return type:None
Assign()
  • Sets a list from an other one. The lists are shared. The list itself is returned.
Parameters:Other (TopLoc_SListOfItemLocation &) –
Return type:TopLoc_SListOfItemLocation
ChangeTail()
  • Returns the current tail of the list. This tail may be modified. A method modifying the tail can be called. The tail will be modified in the list.
Return type:TopLoc_SListOfItemLocation
ChangeValue()
  • Returns the current value of the list. An error is raised if the list is empty. This value may be modified. A method modifying the value can be called. The value will be modified in the list.
Return type:TopLoc_ItemLocation
Clear()
  • Sets the list to be empty.
Return type:None
Construct()
  • Replaces the list by a list with <anItem> as Value and the list <self> as tail.
Parameters:anItem (TopLoc_ItemLocation &) –
Return type:None
Constructed()
  • Returns a new list with <anItem> as Value an the list <self> as tail.
Parameters:anItem (TopLoc_ItemLocation &) –
Return type:TopLoc_SListOfItemLocation
Initialize()
  • Sets the iterator to iterate on the content of <aList>. This is Assign().
Parameters:aList (TopLoc_SListOfItemLocation &) –
Return type:None
IsEmpty()
Return type:bool
More()
  • Returns True if the iterator has a current value. This is !IsEmpty()
Return type:bool
Next()
  • Moves the iterator to the next object in the list. If the iterator is empty it will stay empty. This is ToTail()
Return type:None
Set()
Parameters:Other (TopLoc_SListOfItemLocation &) –
Return type:TopLoc_SListOfItemLocation
SetTail()
  • Changes the current tail in the list. On an empty list SetTail is Assign.
Parameters:aList (TopLoc_SListOfItemLocation &) –
Return type:None
SetValue()
  • Changes the current value in the list. An error is raised if the list is empty.
Parameters:anItem (TopLoc_ItemLocation &) –
Return type:None
Tail()
  • Returns the current tail of the list. On an empty list the tail is the list itself.
Return type:TopLoc_SListOfItemLocation
ToTail()
  • Replaces the list <self> by its tail.
Return type:None
Value()
  • Returns the current value of the list. An error is raised if the list is empty.
Return type:TopLoc_ItemLocation
thisown

The membership flag

class TopLoc_StdMapNodeOfMapOfLocation(*args)

Bases: OCC.TCollection.TCollection_MapNode

Parameters:
  • K (TopLoc_Location &) –
  • n (TCollection_MapNodePtr &) –
Return type:

None

GetHandle()
Key()
Return type:TopLoc_Location
thisown

The membership flag

register_handle(handle, base_object)

Inserts the handle into the base object to prevent memory corruption in certain cases