pylib.data_step_std module

STEP Standard structure.

Date

2020-01-03

See also

STEP, ISO 10303-21, AP 232 (Application Protocol) http://www.steptools.com/stds/step/ and https://www.steptools.com/stds/stp_aim/html/schema.html

ISO 10303-21:2002. Industrial automation systems and integration – Product data representation and exchange – Part 21: Implementation methods: Clear text encoding of the exchange structure

ISO 10303-21:2016. Industrial automation systems and integration – Product data representation and exchange – Part 21: Implementation methods: Clear text encoding of the exchange structure

class ARRAY[source]

Bases: tuple

EXPRESS Type ARRAY

ARRAY are ordered. An ARRAY is the only aggregate that may contain unset members.

Parameters
  • value (str) – value

  • dtype

Return type

tuple

class AXIS2_PLACEMENT_2D(name, location, ref_direction)[source]

Bases: pylib.data_step_std.PLACEMENT

STEP Standard ENTITY axis2_placement_2d

Explicit Attributes

Parameters

Derived Attributes

Variables
class AXIS2_PLACEMENT_3D(name, location, axis, ref_direction)[source]

Bases: pylib.data_step_std.PLACEMENT

STEP Standard ENTITY axis2_placement_3d

Explicit Attributes

Parameters

Derived Attributes

Variables
BOOLEAN(value)[source]

EXPRESS Type BOOLEAN with values TRUE and FALSE

Parameters

value (str) – either .T. for a True value or .F. for a False value

Raises

TypeError

class BOUNDED_CURVE(name)[source]

Bases: pylib.data_step_std.CURVE

STEP Standard ENTITY bounded_curve

Explicit Attributes

Parameters

name (STRING) – label

Derived Attributes

Variables

dim (INTEGER) – dimension_count

class B_SPLINE_CURVE(name, degree, control_points_list, curve_form, closed_curve, self_intersect)[source]

Bases: pylib.data_step_std.BOUNDED_CURVE

STEP Standard ENTITY b_spline_curve

Explicit Attributes

Parameters

Derived Attributes

Variables
class B_SPLINE_CURVE_FORM[source]

Bases: enum.Enum

STEP Standard TYPE b_spline_curve_form

ENUMERATION OF (polyline_form, circular_arc, elliptic_arc, parabolic_arc, hyperbolic_arc, unspecified).

Variables
CIRCULAR_ARC = 2
ELLIPTIC_ARC = 3
HYPERBOLIC_ARC = 5
PARABOLIC_ARC = 4
POLYLINE_FORM = 1
UNSPECIFIED = 6
class B_SPLINE_CURVE_WITH_KNOTS(name, degree, control_points_list, curve_form, closed_curve, self_intersect, knot_multiplicities, knots, knot_spec)[source]

Bases: pylib.data_step_std.B_SPLINE_CURVE

STEP Standard ENTITY b_spline_curve_with_knots

Explicit Attributes

Parameters

Derived Attributes

Variables
class CARTESIAN_POINT(name, coordinates)[source]

Bases: pylib.data_step_std.POINT

STEP Standard ENTITY cartesian_point

Explicit Attributes

Parameters
  • name (STRING) – label

  • coordinates (tuple[float, ..]) – list of length_measure

Derived Attributes

Variables

dim (INTEGER) – dimension_count

__str__()[source]

Return str(self).

class CIRCLE(name, position, radius)[source]

Bases: pylib.data_step_std.CONIC

STEP Standard ENTITY circle

Explicit Attributes

Parameters

Derived Attributes

Variables

dim (INTEGER) – dimension_count

class CONIC(name, position)[source]

Bases: pylib.data_step_std.CURVE

STEP Standard ENTITY conic

Explicit Attributes

Parameters

Derived Attributes

Variables

dim (INTEGER) – dimension_count

class CURVE(name)[source]

Bases: pylib.data_step_std.GEOMETRIC_REPRESENTATION_ITEM

STEP Standard ENTITY curve

Explicit Attributes

Parameters

name (STRING) – label

Derived Attributes

Variables

dim (INTEGER) – dimension_count

class DIRECTION(name, direction_ratios)[source]

Bases: pylib.data_step_std.GEOMETRIC_REPRESENTATION_ITEM

STEP Standard ENTITY direction

Explicit Attributes

Parameters
  • name (STRING) – label

  • direction_ratios (LIST[REAL, ..]) – STEP Standard LIST OF REAL

Derived Attributes

Variables

dim (INTEGER) – dimension_count

class EDGE(name, edge_start, edge_end)[source]

Bases: pylib.data_step_std.TOPOLOGICAL_REPRESENTATION_ITEM

STEP Standard ENTITY edge

Explicit Attributes

Parameters
  • name (STRING) – label

  • edge_start (VERTEX) – start point

  • edge_end (VERTEX) – end point

class EDGE_CURVE(name, edge_start, edge_end, edge_geometry, same_sense)[source]

Bases: pylib.data_step_std.EDGE

STEP Standard ENTITY edge_curve

Explicit Attributes

Parameters
  • name (STRING) – label

  • edge_start (VERTEX) – start point

  • edge_end (VERTEX) – end point

  • edge_geometry (CURVE) – curve

  • same_sense (BOOLEAN) – <<TODO>>

Derived Attributes

Variables

dim (INTEGER) – dimension_count

Definition from ISO/CD 10303-42:1992: An edge curve is a special subtype of edge which has its geometry fully defined. The geometry is defined by associating the edge with a curve which may be unbounded. As the topological and geometric directions may be opposed, an indicator (same sense) is used to identify whether the edge and curve directions agree or are opposed. The Boolean value indicates whether the curve direction agrees with (TRUE) or is in the opposite direction (FALSE) to the edge direction. Any geometry associated with the vertices of the edge shall be consistent with the edge geometry.

Informal propositions
  1. The domain of the edge curve is formally defined to be the domain of its edge geometry as trimmed by the vertices. This domain does not include the vertices.

  2. An edge curve has non-zero finite extent.

  3. An edge curve is a manifold.

  4. An edge curve is arcwise connected.

  5. The edge start is not a part of the edge domain.

  6. The edge end is not a part of the edge domain.

  7. Vertex geometry shall be consistent with edge geometry.

Attribute definitions
EdgeGeometry

The curve which defines the shape and spatial location of the edge. This curve may be unbounded and is implicitly trimmed by the vertices of the edge; this defines the edge domain. Multiple edges can reference the same curve.

SameSense

This logical flag indicates whether (TRUE), or not (FALSE) the senses of the edge and the curve defining the edge geometry are the same. The sense of an edge is from the edge start vertex to the edge end vertex; the sense of a curve is in the direction of increasing parameter.

class EDGE_LOOP(name, edge_list)[source]

Bases: pylib.data_step_std.PATH, pylib.data_step_std.LOOP

STEP Standard ENTITY edge_loop

Explicit Attributes

Parameters
class ELLIPSE(name, position, semi_axis_1, semi_axis_2)[source]

Bases: pylib.data_step_std.CONIC

STEP Standard ENTITY ellipse

Explicit Attributes

Parameters

Derived Attributes

Variables

dim (INTEGER) – dimension_count

class GENERIC[source]

Bases: object

class GEOMETRIC_REPRESENTATION_ITEM(name)[source]

Bases: pylib.data_step_std.REPRESENTATION_ITEM

STEP Standard ENTITY geometric_representation_item

Explicit Attributes

Parameters

name (STRING) – label

Derived Attributes

Variables

dim (INTEGER) – dimension_count

class INTEGER[source]

Bases: int

EXPRESS Type INTEGER

EXPRESS integers can have in principle any length, but most implementations restricted them to a signed 32 bit value.

class KNOT_TYPE[source]

Bases: enum.Enum

STEP Standard TYPE knot_type

ENUMERATION OF (uniform_knots, quasi_uniform_knots, piecewise_bezier_knots, unspecified).

Variables
PIECEWISE_BEZIER_KNOTS = 3
QUASI_UNIFORM_KNOTS = 2
UNIFORM_KNOTS = 1
UNSPECIFIED = 4
class LINE(name, pnt, dir)[source]

Bases: pylib.data_step_std.CURVE

STEP Standard ENTITY line

Explicit Attributes

Parameters

Derived Attributes

Variables

dim (INTEGER) – dimension_count

class LIST[source]

Bases: tuple

EXPRESS Type LIST

LIST are ordered. It is not possible to contain unset members.

Parameters
  • value (str) – value

  • dtype

Return type

tuple

LOGICAL(value)[source]

EXPRESS Type LOGICAL with values TRUE and FALSE and in addition UNKNOWN

Parameters

value (str) – either .T. for a True value or .F. for a False value

class LOOP(name)[source]

Bases: pylib.data_step_std.TOPOLOGICAL_REPRESENTATION_ITEM

STEP Standard ENTITY loop

Explicit Attributes

Parameters

name (STRING) – label

class ORIENTED_EDGE(name, edge_start, edge_end, edge_element, orientation)[source]

Bases: pylib.data_step_std.EDGE

STEP Standard ENTITY oriented_edge

Explicit Attributes

Parameters
  • name (STRING) – label

  • edge_start (VERTEX) – [re-declared attribute from edge]

  • edge_end (VERTEX) – [re-declared attribute from edge]

  • edge_element (EDGE) –

  • orientation (BOOLEAN) –

Derived Attributes

Variables
  • edge_start (VERTEX) – [re-declared attribute from edge]

  • edge_end (VERTEX) – [re-declared attribute from edge]

class PATH(name, edge_list)[source]

Bases: pylib.data_step_std.TOPOLOGICAL_REPRESENTATION_ITEM

STEP Standard ENTITY path

Explicit Attributes

Parameters
class PLACEMENT(name, location)[source]

Bases: pylib.data_step_std.GEOMETRIC_REPRESENTATION_ITEM

STEP Standard ENTITY placement

Explicit Attributes

Parameters

Derived Attributes

Variables

dim (INTEGER) – dimension_count

class POINT(name)[source]

Bases: pylib.data_step_std.GEOMETRIC_REPRESENTATION_ITEM

STEP Standard ENTITY point

Explicit Attributes

Parameters

name (STRING) – label

Derived Attributes

Variables

dim (INTEGER) – dimension_count

class PREFERRED_SURFACE_CURVE_REPRESENTATION[source]

Bases: enum.Enum

STEP Standard TYPE b_spline_curve_form

Variables
CURVE_3D = 1
PCURVE_S1 = 2
PCURVE_S2 = 3
class REAL[source]

Bases: float

EXPRESS Type REAL

Ideally an EXPRESS real value is unlimited in accuracy and size. But in practice a real value is represented by a floating point value of type double.

class REPRESENTATION_ITEM(name)[source]

Bases: object

STEP Standard ENTITY representation_item

Explicit Attributes

Parameters

name (STRING) – label

Additional attributes

Variables

idn (int <<additional>>) – for the instance the instance id and for the class the total number of instances

idn = 0
class SEAM_CURVE(name, curve_3d, associated_geometry, master_representation)[source]

Bases: pylib.data_step_std.SURFACE_CURVE

STEP Standard ENTITY seam_curve

Explicit Attributes

Parameters

Derived Attributes

Variables
  • dim (INTEGER) – dimension_count

  • basis_surface (SET[SURFACE, ..]) – <<TODO>>

class SET[source]

Bases: set

EXPRESS Type SET

SET are unordered. Contain a particular value more than once, is not allowed. It is not possible to contain unset members.

Parameters
  • value (str) – value

  • dtype

Return type

set

class STRING[source]

Bases: str

EXPRESS Type STRING

This is the most often used simple type. EXPRESS strings can be of any length and can contain any character (ISO 10646/Unicode).

class SURFACE_CURVE(name, curve_3d, associated_geometry, master_representation)[source]

Bases: pylib.data_step_std.CURVE

STEP Standard ENTITY surface_curve

Explicit Attributes

Parameters

Derived Attributes

Variables
  • dim (INTEGER) – dimension_count

  • basis_surface (SET[SURFACE, ..]) – <<TODO>>

class TOPOLOGICAL_REPRESENTATION_ITEM(name)[source]

Bases: pylib.data_step_std.REPRESENTATION_ITEM

STEP Standard ENTITY topological_representation_item

Explicit Attributes

Parameters

name (STRING) – label

class VECTOR(name, orientation, magnitude)[source]

Bases: pylib.data_step_std.GEOMETRIC_REPRESENTATION_ITEM

STEP Standard ENTITY vector

Explicit Attributes

Parameters

Derived Attributes

Variables

dim (INTEGER) – dimension_count

class VERTEX(name)[source]

Bases: pylib.data_step_std.TOPOLOGICAL_REPRESENTATION_ITEM

STEP Standard ENTITY vertex

Explicit Attributes

Parameters

name (STRING) – label

class VERTEX_POINT(name, vertex_geometry)[source]

Bases: pylib.data_step_std.VERTEX

STEP Standard ENTITY vertex_point

Explicit Attributes

Parameters
  • name (STRING) – label

  • vertex_geometry (POINT) – point

Derived Attributes

Variables

dim (INTEGER) – dimension_count

__str__()[source]

Return str(self).

boolean_choose(b, choice1, choice2)[source]

STEP Standard FUNCTION boolean_choose

Parameters
Returns

STEP STEP Standard TYPE GENERIC

Return type

object

dimension_of(item)[source]

STEP Standard FUNCTION dimension_of

Parameters

item (GEOMETRIC_REPRESENTATION_ITEM) –

Returns

dim

Return type

Union[int, None]

Variables

dim (INTEGER) – dimension_count dimension_count > 0

list_to_array(lis, low, u)[source]

STEP Standard FUNCTION list_to_array

Parameters
  • lis (tuple[GENERIC, ..]) – STEP Standard TYPE LIST [0:?] OF GENERIC

  • low (INTEGER) –

  • u (INTEGER) –

Returns

res

Return type

Union[tuple, None]

Variables
  • n (INTEGER) –

  • res (tuple[GENERIC, ..]) – STEP Standard TYPE ARRAY [low:u] OF GENERIC

path_head_to_tail(a_path)[source]

STEP Standard FUNCTION path_head_to_tail

Check if the path is a connected curve set.

Parameters

a_path (PATH) –

Returns

p

Return type

LOGICAL

Variables

p