Tekla Open API

Detailed and full API reference helps you master Tekla Open API

This is the most recent version of Tekla Open API.
For older versions, please visit Tekla Warehouse.

LineSegment Class

The LineSegment class represents a single finite segment of a line in 3D space. See Line for the implementation of a straight line.
Inheritance Hierarchy
SystemObject
  Tekla.Structures.Geometry3dLineSegment

Namespace:  Tekla.Structures.Geometry3d
Assembly:  Tekla.Structures (in Tekla.Structures.dll) Version: 2018.1.0.0 (2018.1.0.0)
Syntax
[SerializableAttribute]
public class LineSegment

The LineSegment type exposes the following members.

Constructors
  Name Description
Public method LineSegment
Instantiates a line segment with both the starting point and the end point zeroed.
Public method LineSegment(Point, Point)
Instantiates a line segment with the given points.
Top
Properties
  Name Description
Public property Point1
The starting point of the line segment.
Public property Point2
The end point of the line segment.
Top
Methods
  Name Description
Public method Equals
Returns true if the objects are equal.
(Overrides ObjectEquals(Object).)
Public method GetDirectionVector
Returns a new unit direction vector of a line segment.
Public method GetHashCode
Returns a hash code for a line segment. Notice, in extremely rare cases, you might not get the same hash code for two line segments even though they are considered equal! This should, however, happen only in extremely rare cases!
(Overrides ObjectGetHashCode.)
Public method Length
Returns the length of a line segment.
Top
Operators
  Name Description
Public operatorStatic member Equality
Checks the equality of two line segments.
Public operatorStatic member Inequality
Checks the inequality of two line segments.
Top
See Also