Package Scientific :: Package Geometry :: Module Objects3D :: Class Line

[frames] | no frames]

# Class Line

    GeometricalObject3D --+
                          |
                         Line

Line

Instance Methods

__init__(self, point, direction) |

`float`

distanceFrom(self, point) |

Scientific.Geometry.Vector

projectionOf(self, point) Returns: the projection of point onto the line |

`float` or `NoneType`

volume(self) Returns: the volume of the object. |

Inherited from `GeometricalObject3D`: `hasPoint`, `intersectWith`

Method Details

### __init__(self, point, direction)
(Constructor)

Parameters:
  - `point` (Scientific.Geometry.Vector) - any point on the line
  - `direction` (Scientific.Geometry.Vector) - the direction of the line

### distanceFrom(self, point)

Parameters:
  - `point` - a point in space
Returns: `float`
Overrides: GeometricalObject3D.distanceFrom
  (inherited documentation)

### projectionOf(self, point)

Parameters:
  - `point` (Scientific.Geometry.Vector) - a point in space
Returns: Scientific.Geometry.Vector
  the projection of point onto the line

### volume(self)

Returns: `float` or `NoneType`
  the volume of the object. The result is `None` for unbounded objects and zero for lower-dimensional objects.
Overrides: GeometricalObject3D.volume
  (inherited documentation)