World Ocean Simulation System (WOSS) library
|
Class that stores the coordinates of moving entity. More...
#include <location-definitions.h>
Public Member Functions | |
Location (const CoordZ &coordz=CoordZ(), double dist=LOCATION_COMPARISON_DISTANCE) | |
Location (double latitude, double longitude, double depth=0, double dist=LOCATION_COMPARISON_DISTANCE) | |
virtual | ~Location () |
virtual Location * | create (double latitude, double longitude, double depth=0, double dist=LOCATION_COMPARISON_DISTANCE) const |
virtual Location * | create (const CoordZ &coordz=CoordZ(), double dist=LOCATION_COMPARISON_DISTANCE) const |
virtual Location * | clone () const |
virtual bool | isValid () const |
virtual bool | isEquivalentTo (const woss::CoordZ &coordz) |
virtual void | setLocation (const CoordZ &coordz) |
virtual void | setLatitude (double lat) |
virtual void | setLongitude (double lon) |
virtual void | setDepth (double depth) |
virtual void | setVerticalOrientation (double angle) |
virtual void | setHorizontalOrientation (double angle) |
virtual CoordZ | getLocation () |
virtual double | getLatitude () |
virtual double | getLongitude () |
virtual double | getDepth () |
virtual double | getX () |
virtual double | getY () |
virtual double | getZ () |
virtual double | getVerticalOrientation () |
virtual double | getHorizontalOrientation () |
virtual double | getBearing () |
friend::std::ostream & | operator<< (::std::ostream &os, const Location &instance) |
Protected Attributes | |
double | comparison_distance |
CoordZ | curr_coordz |
double | vertical_orientation |
double | horizontal_orientation |
double | bearing |
Class that stores the coordinates of moving entity.
The woss::Location class has the task of storing the geographical coordinates of a moving entity
Location default constructor
coordz | coordinates |
dist | distance comparison precision [m] |
Location::Location | ( | double | latitude, |
double | longitude, | ||
double | depth = 0 , |
||
double | dist = LOCATION_COMPARISON_DISTANCE |
||
) |
Location constructor
latitude | latitude value [decimal degrees] |
longitude | longitude value [decimal degrees] |
depth | depth value [m] |
dist | distance comparison precision [m] |
|
inlinevirtual |
Location destructor
|
inlinevirtual |
Location virtual factory method
Reimplemented in WossPosition.
Referenced by woss::WossCreatorContainer< Data * >::get().
|
inlinevirtual |
Location virtual factory method
coordz | coordinates |
dist | distance comparison precision [m] |
Reimplemented in WossPosition.
|
inlinevirtual |
Location virtual factory method
latitude | latitude value [decimal degrees] |
longitude | longitude value [decimal degrees] |
depth | depth value [m] |
dist | distance comparison precision [m] |
Reimplemented in WossPosition.
|
virtual |
Gets current bearing in [-pi,pi]
Reimplemented in WossWpPosition.
References bearing.
|
virtual |
Gets current depth
Reimplemented in WossPosition.
References woss::CoordZ::getDepth(), and getLocation().
Referenced by WossPosition::getDepth().
|
virtual |
Gets current horizontal orientation from reference line (0 degrees = parallel to direction of current movement ) positive values are counter-clockwise rotations, while negative ones are clockwise rotations
References horizontal_orientation.
|
virtual |
Gets current latitude
Reimplemented in WossPosition.
References woss::Coord::getLatitude(), and getLocation().
Referenced by WossPosition::getLatitude().
|
virtual |
Gets current coordinates
Reimplemented in WossWpPosition.
References curr_coordz.
Referenced by getDepth(), getLatitude(), WossWpPosition::getLocation(), getLongitude(), getX(), getY(), getZ(), and isEquivalentTo().
|
virtual |
Gets current longitude
Reimplemented in WossPosition.
References getLocation(), and woss::Coord::getLongitude().
Referenced by WossPosition::getLongitude().
|
virtual |
Gets current vertical orientation from reference line (0 degrees = parallel to sea surface / bottom ). Negative values are towards the surface, while positive ones are towards sea bottom
Reimplemented in WossWpPosition.
References vertical_orientation.
|
virtual |
Gets current cartesian x-axis value
Reimplemented in WossPosition.
References woss::CoordZ::getCartX(), and getLocation().
Referenced by WossPosition::getX().
|
virtual |
Gets current cartesian y-axis value
Reimplemented in WossPosition.
References woss::CoordZ::getCartY(), and getLocation().
Referenced by WossPosition::getY().
|
virtual |
Gets current cartesian z-axis value
Reimplemented in WossPosition.
References woss::CoordZ::getCartZ(), and getLocation().
Referenced by WossPosition::getZ().
|
virtual |
Checks if the woss::CoordZ given is equivalent to this Location
coordz | valid woss::CoordZ to check |
Reimplemented in WossWpPosition.
References comparison_distance, woss::CoordZ::getCartDistance(), getLocation(), and woss::CoordZ::isValid().
|
inlinevirtual |
Checks the validity of Location
References curr_coordz, and woss::CoordZ::isValid().
|
inline |
<< operator
os | left operand ostream reference |
instance | right operand const Location reference |
References curr_coordz, woss::CoordZ::getDepth(), woss::Coord::getLatitude(), and woss::Coord::getLongitude().
|
virtual |
Sets initial depth
lat | valid depth [m] |
Reimplemented in WossPosition.
References curr_coordz, and woss::CoordZ::setDepth().
Referenced by WossPosition::setDepth().
|
virtual |
Gets current horizontal orientation from reference line (0 degrees = parallel to direction of current movement ) positive values are counter-clockwise rotations, while negative ones are clockwise rotations
angle | delta angle [dec degrees] |
References horizontal_orientation.
|
virtual |
Sets initial latitude
lat | valid latitude [decimal degrees] |
Reimplemented in WossPosition.
References curr_coordz, and woss::Coord::setLatitude().
Referenced by WossPosition::setLatitude().
|
virtual |
|
virtual |
Sets initial longitude
lat | valid longitude [decimal degrees] |
Reimplemented in WossPosition.
References curr_coordz, and woss::Coord::setLongitude().
Referenced by WossPosition::setLongitude().
|
virtual |
Sets current vertical orientation from reference line (0 degrees = parallel to sea surface / bottom ). Negative values are towards the surface, while positive ones are towards sea bottom
angle | delta angle [dec degrees] |
References vertical_orientation.
|
protected |
current bearing
Referenced by getBearing(), and WossWpPosition::getBearing().
|
protected |
Comparison distance [m]
Referenced by isEquivalentTo(), and WossWpPosition::isEquivalentTo().
|
protected |
current coordinates
Referenced by getLocation(), WossWpPosition::isEquivalentTo(), isValid(), operator<<(), setDepth(), setLatitude(), setLocation(), and setLongitude().
|
protected |
current horizontal orientation. It's the delta angle from reference direction (0 degrees = parallel to movement's direction )
Referenced by getHorizontalOrientation(), and setHorizontalOrientation().
|
protected |
current vertical orientation. It's the delta angle from reference direction (0 degrees = parallel to sea surface / bottom )
Referenced by getVerticalOrientation(), WossWpPosition::getVerticalOrientation(), and setVerticalOrientation().