CARMA C++
carma::services::Source Class Reference

Source is derived from CatalogEntry and is used to hold information for a particular entry from a source catalog. More...

#include <carma/services/Source.h>

Inherits carma::services::CatalogEntry.

Public Member Functions

std::string getCatalogFormat () const
 
std::string getComments () const
 
coordSysType getCoordSysType () const
 
Distance getDistance () const
 
unsigned long getIdNo () const
 
Angle getParallax () const
 
sourcePntType getPntType () const
 
Velocity getVelocity () const
 
Angle getXCoordinate () const
 
double getXProperMotion () const
 
Angle getYCoordinate () const
 
double getYProperMotion () const
 
bool isOptical () const
 
bool isPlanet () const
 
bool isRadio () const
 
void setCatalogFormat (const std::string &catalogFormat)
 Set the catalog format style (this is used by NOVAS). More...
 
void setComments (const std::string &comments)
 Set any additional comments about this Source. More...
 
void setIdNo (unsigned long idNo)
 Set an ID number for this Source. More...
 
void setParallax (const Angle &parallax)
 Set the parallax of this Source. More...
 
void setPntType (sourcePntType type)
 Set the pointing type for this source. More...
 
void setVelocity (const Velocity &velocity)
 Set the radial velocity of this Source. More...
 
void setXCoordinate (const Angle &xcoord)
 Set the X coordinate of this Source. More...
 
void setXProperMotion (double xProperMotion)
 Set the X proper motion of this Source. More...
 
void setYCoordinate (const Angle &ycoord)
 Set the Y coordinate of this Source. More...
 
void setYProperMotion (double yProperMotion)
 Set the Y proper motion of this Source. More...
 
 Source ()
 Default Constructor. More...
 
 Source (const std::string &name)
 Simple Constructor. More...
 
 Source (const std::string &name, const Angle &xCoord, const Angle &yCoord, const Velocity &velocity, const Angle &parallax, coordSysType coordSys=COORDSYS_RADEC, double xProperMotion=0.0, double yProperMotion=0.0, const std::string &catalogFormat="CARMA", unsigned long idNo=0, sourcePntType pntType=PNT_RADIO, const std::string &comments="This Space For Rent")
 Full Constructor. More...
 
 Source (const std::string &name, const Angle &xCoord, const Angle &yCoord, const Velocity &velocity, const Distance &distance, coordSysType coordSys=COORDSYS_RADEC, double xProperMotion=0.0, double yProperMotion=0.0, const std::string &catalogFormat="CARMA", unsigned long idNo=0, sourcePntType pntType=PNT_RADIO, const std::string &comments="This Space For Rent")
 Full Constructor. More...
 
virtual ~Source ()
 Destructor. More...
 
- Public Member Functions inherited from carma::services::CatalogEntry
 CatalogEntry ()
 Constructor. More...
 
virtual std::string getName () const
 
virtual void setName (const std::string &name)
 All catalog entries must be named. More...
 
virtual ~CatalogEntry ()
 Destructor. More...
 

Static Public Member Functions

static bool isPlanet (const std::string &sourceName)
 

Additional Inherited Members

- Protected Attributes inherited from carma::services::CatalogEntry
std::string name_
 

Detailed Description

Source is derived from CatalogEntry and is used to hold information for a particular entry from a source catalog.

Definition at line 23 of file Source.h.

Constructor & Destructor Documentation

carma::services::Source::Source ( )

Default Constructor.

We need this because this class is used in a map in SourceCatalog

carma::services::Source::Source ( const std::string &  name)

Simple Constructor.

Parameters
nameThe name of the source object.
carma::services::Source::Source ( const std::string &  name,
const Angle xCoord,
const Angle yCoord,
const Velocity velocity,
const Angle parallax,
coordSysType  coordSys = COORDSYS_RADEC,
double  xProperMotion = 0.0,
double  yProperMotion = 0.0,
const std::string &  catalogFormat = "CARMA",
unsigned long  idNo = 0,
sourcePntType  pntType = PNT_RADIO,
const std::string &  comments = "This Space For Rent" 
)

Full Constructor.

Parameters
nameThe name of the source
xCoordThe X coordinate of the object (e.g. RA, Galactic Longitude), represented by an Angle
yCoordThe Y coordinate of the object (e.g. DEC, Galactic Latitude), represented by an Angle
velocityThe radial velocity of the source, represented by a Velocity
parallaxThe parallax of the source, represented by an Angle.
coordSysthe coordinate system type. (COORDSYS_RADEC, COORDSYS_GALACTIC)
xProperMotionThe proper motion in the X direction (mas/yr)
yProperMotionThe proper motion in the Y direction (mas/yr)
catalogFormatCatalog format (FK5, Hipparcos)
idNoAn ID number for this source.
pntTypeIndicates if this source can be used for radio and/or optical pointing. Default PNT_RADIO.
commentsComments about this source
carma::services::Source::Source ( const std::string &  name,
const Angle xCoord,
const Angle yCoord,
const Velocity velocity,
const Distance distance,
coordSysType  coordSys = COORDSYS_RADEC,
double  xProperMotion = 0.0,
double  yProperMotion = 0.0,
const std::string &  catalogFormat = "CARMA",
unsigned long  idNo = 0,
sourcePntType  pntType = PNT_RADIO,
const std::string &  comments = "This Space For Rent" 
)

Full Constructor.

Parameters
nameThe name of the source
xCoordThe X coordinate of the object (e.g. RA, Galactic Longitude), represented by an Angle
yCoordThe Y coordinate of the object (e.g. DEC, Galactic Latitude), represented by an Angle
velocityThe radial velocity of the source, represented by a Velocity
distanceThe distance to the source, represented by a Distance. CARMA convention is that a zero distance (Distance::value()) means the infinite distance (parallax=0). This quantity is stored internally as a parallax Angle.
coordSysthe coordinate system type. (COORDSYS_RADEC, COORDSYS_GALACTIC)
xProperMotionThe proper motion in the X direction (mas/yr)
yProperMotionThe proper motion in the Y direction (mas/yr)
catalogFormatCatalog format (FK5, Hipparcos)
idNoAn ID number for this source.
commentsComments about this source
virtual carma::services::Source::~Source ( )
virtual

Destructor.

Member Function Documentation

std::string carma::services::Source::getCatalogFormat ( ) const
Parameters
catalogCatalog format (FK5, Hipparcos)

Definition at line 268 of file Source.h.

std::string carma::services::Source::getComments ( ) const
Returns
Additional comments about the source.

Definition at line 261 of file Source.h.

coordSysType carma::services::Source::getCoordSysType ( ) const
Returns
the coordinate system enum, as a string

Definition at line 232 of file Source.h.

Distance carma::services::Source::getDistance ( void  ) const
Returns
An equivalent distance (pc) for this Source's parallax

Definition at line 309 of file Source.h.

unsigned long carma::services::Source::getIdNo ( ) const
Returns
ID number for this source.

Definition at line 275 of file Source.h.

Angle carma::services::Source::getParallax ( ) const
Returns
The parallax of the source, represented by an Angle.

Definition at line 254 of file Source.h.

sourcePntType carma::services::Source::getPntType ( ) const
Returns
the pointing type for this source (PNT_RADIO,PNT_OPTICAL,PNT_BOTH)

Definition at line 283 of file Source.h.

Velocity carma::services::Source::getVelocity ( ) const
Returns
The radial velocity of the source, represented by a Velocity

Definition at line 247 of file Source.h.

Angle carma::services::Source::getXCoordinate ( ) const
Returns
The X coordinate of the object (e.g. RA, Galactic Longitude), represented by an Angle

Definition at line 210 of file Source.h.

double carma::services::Source::getXProperMotion ( ) const
Returns
The proper motion in the X direction (mas/yr)

Definition at line 225 of file Source.h.

Angle carma::services::Source::getYCoordinate ( ) const
Returns
The Y coordinate of the object (e.g. DEC, Galactic Latitude), represented by an Angle

Definition at line 218 of file Source.h.

double carma::services::Source::getYProperMotion ( ) const
Returns
The proper motion in the Y direction (mas/yr)

Definition at line 239 of file Source.h.

bool carma::services::Source::isPlanet ( ) const
Returns
True if this Source's name matches a Solar System body (including the Moon), false otherwise. Match is case-insensitive.

Definition at line 300 of file Source.h.

static bool carma::services::Source::isPlanet ( const std::string &  sourceName)
static
Parameters
sourceNameName of source to check.
Returns
true if the source name matches a Solar System body (including the Moon), false otherwise. Match is case-insensitive.
void carma::services::Source::setCatalogFormat ( const std::string &  catalogFormat)

Set the catalog format style (this is used by NOVAS).

Parameters
catalogCatalog format (FK5, Hipparcos)
void carma::services::Source::setComments ( const std::string &  comments)

Set any additional comments about this Source.

Parameters
commentsAdditional comments about the source.
void carma::services::Source::setIdNo ( unsigned long  idNo)

Set an ID number for this Source.

Parameters
idNoAn ID number for this source.
void carma::services::Source::setParallax ( const Angle parallax)

Set the parallax of this Source.

Parameters
parallaxThe parallax of the source, represented by an Angle.
void carma::services::Source::setPntType ( sourcePntType  type)

Set the pointing type for this source.

Parameters
thepointing type (PNT_RADIO,PNT_OPTICAL,PNT_BOTH)

Definition at line 194 of file Source.h.

void carma::services::Source::setVelocity ( const Velocity velocity)

Set the radial velocity of this Source.

Parameters
velocityThe radial velocity of the source, represented by a Velocity
void carma::services::Source::setXCoordinate ( const Angle xcoord)

Set the X coordinate of this Source.

Parameters
xcoordThe X coordinate of the object (e.g. RA, Galactic Longitude), represented by an Angle
void carma::services::Source::setXProperMotion ( double  xProperMotion)

Set the X proper motion of this Source.

Parameters
xProperMotionThe proper motion in the X direction (mas/yr)
void carma::services::Source::setYCoordinate ( const Angle ycoord)

Set the Y coordinate of this Source.

Parameters
ycoordThe Y coordinate of the object (e.g. DEC, Galactic Latitude), represented by an Angle
void carma::services::Source::setYProperMotion ( double  yProperMotion)

Set the Y proper motion of this Source.

Parameters
yProperMotionThe proper motion in the Y direction (mas/yr)

The documentation for this class was generated from the following file: