Package mosp :: Package geo :: Module osm :: Class Node
[hide private]
[frames] | no frames]

Class Node

source code


A geo-model node.


Authors:
P. Tute, Rory McCann
Instance Methods [hide private]
 
__init__(self, id=None, x=None, y=None, zone=None, lon=None, lat=None, tags=None)
Initialize the geo-model node.
source code
 
getLat(self)
Returns the node's Latitude.
source code
 
getLon(self)
Returns the nodes's Longitude.
source code
 
setLat(self, lat)
Sets the node's Latitude and UTM coordinates.
source code
 
setLon(self, lon)
Sets the node's Longitude and UTM coordinates.
source code
 
getX(self)
Returns the node's x coordinate, it's UTM easting.
source code
 
getY(self)
Returns the node's y coordinate, it's UTM northing.
source code
 
getZone(self)
Returns the node's UTM zone.
source code
 
setX(self, x)
Sets the node's x coordinate (UTM easting) and re-calculates Lat/Lon.
source code
 
setY(self, y)
Sets the node's y coordinate (UTM northing) and re-calculates Lat/Lon.
source code
 
setZone(self, z)
Sets the node's y coordinate (UTM northing) and re-calculates Lat/Lon.
source code
 
__repr__(self)
String respresentation of RoutingNode.
source code

Inherited from routing.RoutingNode: __cmp__, cleanup, get_route, get_route_dist, get_routes, on_visit, set_route, setup, setup2, update

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __setattr__, __sizeof__, __str__, __subclasshook__

Instance Variables [hide private]

Inherited from routing.RoutingNode: id, n, neighbors, todo, ways, worldobject

Properties [hide private]
  lat
Returns the node's Latitude.
  lon
Returns the nodes's Longitude.
  x
Returns the node's x coordinate, it's UTM easting.
  y
Returns the node's y coordinate, it's UTM northing.
  z
Returns the node's UTM zone.

Inherited from object: __class__

Method Details [hide private]

__init__(self, id=None, x=None, y=None, zone=None, lon=None, lat=None, tags=None)
(Constructor)

source code 

Initialize the geo-model node.

Parameters:
  • id - node id
  • x - UTM easting
  • y - UTM northing
  • zone - UTM zone
  • lon - WGS84 Longitude
  • lat - WGS84 Latitude
  • tags - OSM tags
Overrides: object.__init__

__repr__(self)
(Representation operator)

source code 

String respresentation of RoutingNode.

Overrides: object.__repr__
(inherited documentation)

Property Details [hide private]

lat

Returns the node's Latitude.

Get Method:
getLat(self) - Returns the node's Latitude.
Set Method:
setLat(self, lat) - Sets the node's Latitude and UTM coordinates.

lon

Returns the nodes's Longitude.

Get Method:
getLon(self) - Returns the nodes's Longitude.
Set Method:
setLon(self, lon) - Sets the node's Longitude and UTM coordinates.

x

Returns the node's x coordinate, it's UTM easting.

Get Method:
getX(self) - Returns the node's x coordinate, it's UTM easting.
Set Method:
setX(self, x) - Sets the node's x coordinate (UTM easting) and re-calculates Lat/Lon.

y

Returns the node's y coordinate, it's UTM northing.

Get Method:
getY(self) - Returns the node's y coordinate, it's UTM northing.
Set Method:
setY(self, y) - Sets the node's y coordinate (UTM northing) and re-calculates Lat/Lon.

z

Returns the node's UTM zone.

Get Method:
getZone(self) - Returns the node's UTM zone.
Set Method:
setZone(self, z) - Sets the node's y coordinate (UTM northing) and re-calculates Lat/Lon.