twisted.positioning.base.Heading(Angle) class documentationtwisted.positioning.base
(View In Hierarchy)
The heading of a mobile object.
| Instance Variable | variation | The (optional) magnetic variation. The sign of the variation is positive 
for variations towards the east (clockwise from north), and negative for 
variations towards the west (counterclockwise from north). If the variation
is unknown or not applicable, this is None. (type:AngleorNone.) | 
| Instance Variable | correctedHeading 0 | The heading, corrected for variation. If the variation is unknown ( None),
is None. This attribute is read-only (its value is determined by the angle 
and variation attributes). The value is coerced to being between 0 
(inclusive) and 360 (exclusive). | 
| Method | __init__ | Initializes an angle with an optional variation. | 
| Class Method | fromFloats | Constructs a Heading from the float values of the angle and variation. | 
| Method | correctedHeading | Corrects the heading by the given variation. This is sometimes known as the true heading. | 
| Method | setSign | Sets the sign of the variation of this heading. | 
| Method | __repr__ | Returns a string representation of this angle. | 
Inherited from Angle:
| Method | inDecimalDegrees | The value of this angle in decimal degrees. This value is immutable. | 
| Method | inDegreesMinutesSeconds | The value of this angle as a degrees, minutes, seconds tuple. This value is immutable. | 
| Method | __float__ | Returns this angle as a float. | 
| Class Variable | _RANGE_EXPRESSIONS | A collection of expressions for the allowable range for the angular value 
of a particular coordinate value. (type: dictofAnglesconstants to callables) | 
| Class Variable | _ANGLE_TYPE_NAMES | English names for angle types. (type: dictofAnglesconstants tostr) | 
| Method | _angleValueRepr | Returns a string representation of the angular value of this angle. | 
| Method | _angleTypeNameRepr | Returns a string representation of the type of this angle. | 
Inherited from FancyEqMixin (via Angle):
| Method | __eq__ | Undocumented | 
| Method | __ne__ | Undocumented | 
None),
is None. This attribute is read-only (its value is determined by the angle 
and variation attributes). The value is coerced to being between 0 
(inclusive) and 360 (exclusive).
  Initializes an angle with an optional variation.
Constructs a Heading from the float values of the angle and variation.
| Parameters | angleValue | The angle value of this heading. (type: float) | 
| variationValue | The value of the variation of this heading. (type: float@return AHeading with the given values.) | 
Sets the sign of the variation of this heading.
| Parameters | sign | The new sign. 1for positive and-1for negative 
signs, respectively. (type:int) | 
| Raises | ValueError | If the signparameter is not-1or1. | 
Returns a string representation of this angle.
| Returns | The string representation. (type: str) | |