class documentation

class twisted.positioning.base._BaseSpeed(FancyEqMixin): (source)

Known subclasses: twisted.positioning.base.Climb, twisted.positioning.base.Speed

View In Hierarchy

An object representing the abstract concept of the speed (rate of movement) of a mobile object.

This primarily has behavior for converting between units and comparison.

Class Variable compareAttributes Undocumented
Method __init__ Initializes a speed.
Property inMetersPerSecond The speed that this object represents, expressed in meters per second. This attribute is immutable.
Property inKnots Returns the speed represented by this object, expressed in knots. This attribute is immutable.
Method __float__ Returns the speed represented by this object expressed in meters per second.
Method __repr__ Returns a string representation of this speed object.
Instance Variable _speed Undocumented

Inherited from FancyEqMixin:

Method __eq__ Undocumented
Method __ne__ Undocumented
compareAttributes = (source)

Undocumented

(type: tuple[str, ...])
def __init__(self, speed): (source)

Initializes a speed.

ParametersspeedThe speed that this object represents, expressed in meters per second. (type: float)
RaisesValueErrorRaised if value was invalid for this particular kind of speed. Only happens in subclasses.
_speed = (source)

Undocumented

@property
inMetersPerSecond = (source)

The speed that this object represents, expressed in meters per second. This attribute is immutable.

(type: float)
@property
inKnots = (source)

Returns the speed represented by this object, expressed in knots. This attribute is immutable.

(type: float)
def __float__(self): (source)

Returns the speed represented by this object expressed in meters per second.

ReturnsThe speed represented by this object, expressed in meters per second. (type: float)
def __repr__(self): (source)

Returns a string representation of this speed object.

ReturnsThe string representation. (type: str)
API Documentation for Twisted, generated by pydoctor 20.12.1 at 2021-02-28 19:53:36.