lsst.afw  14.0-22-gc76603d1b
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | List of all members
lsst::afw::geom::IcrsCoordEndpoint Class Reference

An endpoint for IcrsCoord. More...

#include <Endpoint.h>

Inheritance diagram for lsst::afw::geom::IcrsCoordEndpoint:
lsst::afw::geom::BaseVectorEndpoint< coord::IcrsCoord > lsst::afw::geom::BaseEndpoint< coord::IcrsCoord, std::vector< coord::IcrsCoord > >

Public Types

using Array = std::vector< coord::IcrsCoord >
 
using Point = coord::IcrsCoord
 

Public Member Functions

 IcrsCoordEndpoint (IcrsCoordEndpoint const &)=default
 
 IcrsCoordEndpoint (IcrsCoordEndpoint &&)=default
 
IcrsCoordEndpoint & operator= (IcrsCoordEndpoint const &)=delete
 
IcrsCoordEndpoint & operator= (IcrsCoordEndpoint &&)=delete
 
 IcrsCoordEndpoint ()
 Construct a IcrsCoordEndpoint. More...
 
 IcrsCoordEndpoint (int nAxes)
 Construct a IcrsCoordEndpoint with nAxes specified; nAxes must equal 2. More...
 
virtual ~IcrsCoordEndpoint ()
 
virtual std::vector< double > dataFromPoint (Point const &point) const override
 Get raw data from a single point. More...
 
virtual ndarray::Array< double, 2, 2 > dataFromArray (Array const &arr) const override
 Get raw data from an array of points. More...
 
virtual Point pointFromData (std::vector< double > const &data) const override
 Get a single point from raw data. More...
 
virtual Array arrayFromData (ndarray::Array< double, 2, 2 > const &data) const override
 Get an array of points from raw data. More...
 
virtual std::shared_ptr< ast::Frame > makeFrame () const override
 Create a Frame that can be used with this end point in a Transform. More...
 
virtual void normalizeFrame (std::shared_ptr< ast::Frame > framePtr) const override
 Check that framePtr points to a SkyFrame and set longitude axis to 0, latitude to 1. More...
 
virtual int getNPoints (Array const &arr) const override
 Return the number of points in an array. More...
 
int getNAxes () const
 

Static Public Member Functions

static std::string getClassPrefix ()
 Get the class name prefix, e.g. "Point2" for "Point2Endpoint". More...
 

Protected Member Functions

void _assertNAxes (int nAxes) const
 
int _getNAxes (ndarray::Array< double, 2, 2 > const &data) const
 
int _getNAxes (ndarray::Array< double, 1, 1 > const &data) const
 
int _getNAxes (std::vector< double > const &data) const
 
int _getNPoints (ndarray::Array< double, 2, 2 > const &data) const
 

Detailed Description

An endpoint for IcrsCoord.

A IcrsCoordEndpoint always has 2 axes: RA, Dec

Definition at line 290 of file Endpoint.h.

Member Typedef Documentation

◆ Array

Definition at line 172 of file Endpoint.h.

◆ Point

Definition at line 173 of file Endpoint.h.

Constructor & Destructor Documentation

◆ IcrsCoordEndpoint() [1/4]

lsst::afw::geom::IcrsCoordEndpoint::IcrsCoordEndpoint ( IcrsCoordEndpoint const &  )
default

◆ IcrsCoordEndpoint() [2/4]

lsst::afw::geom::IcrsCoordEndpoint::IcrsCoordEndpoint ( IcrsCoordEndpoint &&  )
default

◆ IcrsCoordEndpoint() [3/4]

lsst::afw::geom::IcrsCoordEndpoint::IcrsCoordEndpoint ( )
inlineexplicit

Construct a IcrsCoordEndpoint.

Definition at line 300 of file Endpoint.h.

◆ IcrsCoordEndpoint() [4/4]

lsst::afw::geom::IcrsCoordEndpoint::IcrsCoordEndpoint ( int  nAxes)
explicit

Construct a IcrsCoordEndpoint with nAxes specified; nAxes must equal 2.

This constructor is primarily used by Transform; other users are encouraged to use the default constructor.

Parameters
[in]nAxesThe number of axes in a point; must equal 2
Exceptions
lsst.pex.exceptions.InvalidParameterErrorif nAxes != 2

◆ ~IcrsCoordEndpoint()

virtual lsst::afw::geom::IcrsCoordEndpoint::~IcrsCoordEndpoint ( )
inlinevirtual

Definition at line 314 of file Endpoint.h.

Member Function Documentation

◆ _assertNAxes()

void lsst::afw::geom::BaseEndpoint< coord::IcrsCoord , std::vector< coord::IcrsCoord > >::_assertNAxes ( int  nAxes) const
protectedinherited

◆ _getNAxes() [1/3]

int lsst::afw::geom::BaseEndpoint< coord::IcrsCoord , std::vector< coord::IcrsCoord > >::_getNAxes ( ndarray::Array< double, 2, 2 > const &  data) const
inlineprotectedinherited

Definition at line 152 of file Endpoint.h.

◆ _getNAxes() [2/3]

int lsst::afw::geom::BaseEndpoint< coord::IcrsCoord , std::vector< coord::IcrsCoord > >::_getNAxes ( ndarray::Array< double, 1, 1 > const &  data) const
inlineprotectedinherited

Definition at line 154 of file Endpoint.h.

◆ _getNAxes() [3/3]

int lsst::afw::geom::BaseEndpoint< coord::IcrsCoord , std::vector< coord::IcrsCoord > >::_getNAxes ( std::vector< double > const &  data) const
inlineprotectedinherited

Definition at line 156 of file Endpoint.h.

◆ _getNPoints()

int lsst::afw::geom::BaseEndpoint< coord::IcrsCoord , std::vector< coord::IcrsCoord > >::_getNPoints ( ndarray::Array< double, 2, 2 > const &  data) const
inlineprotectedinherited

Definition at line 158 of file Endpoint.h.

◆ arrayFromData()

virtual Array lsst::afw::geom::IcrsCoordEndpoint::arrayFromData ( ndarray::Array< double, 2, 2 > const &  data) const
overridevirtual

Get an array of points from raw data.

Parameters
[in]dataRaw data for an array of points, as a 2-D ndarray array [nPoints, nAxes] in C order, so the in-memory view is, for example, x0, y0, x1, y1, x2, y2, ...
Returns
an array of points
Exceptions
lsst::pex::exceptions::InvalidParameterErrorif the array has the wrong nAxes dimension

Implements lsst::afw::geom::BaseEndpoint< coord::IcrsCoord, std::vector< coord::IcrsCoord > >.

◆ dataFromArray()

virtual ndarray::Array<double, 2, 2> lsst::afw::geom::IcrsCoordEndpoint::dataFromArray ( Array const &  arr) const
overridevirtual

Get raw data from an array of points.

Parameters
[in]arrArray of points
Returns
the data as a 2-D ndarray array [nAxes, nPoints] in C order, so the in-memory view is, for example, x0, x1, x2, ..., y0, y1, y2, ...
Exceptions
lsst::pex::exceptions::InvalidParameterErrorif the array has the wrong nAxes dimension

Implements lsst::afw::geom::BaseEndpoint< coord::IcrsCoord, std::vector< coord::IcrsCoord > >.

◆ dataFromPoint()

virtual std::vector<double> lsst::afw::geom::IcrsCoordEndpoint::dataFromPoint ( Point const &  point) const
overridevirtual

Get raw data from a single point.

Parameters
[in]pointdata for a single point
Returns
the values in the point as a vector of size NAxess
Exceptions
lsst::pex::exceptions::InvalidParameterErrorif the point has the wrong number of axes

Implements lsst::afw::geom::BaseEndpoint< coord::IcrsCoord, std::vector< coord::IcrsCoord > >.

◆ getClassPrefix()

static std::string lsst::afw::geom::IcrsCoordEndpoint::getClassPrefix ( )
inlinestatic

Get the class name prefix, e.g. "Point2" for "Point2Endpoint".

Definition at line 335 of file Endpoint.h.

◆ getNAxes()

int lsst::afw::geom::BaseEndpoint< coord::IcrsCoord , std::vector< coord::IcrsCoord > >::getNAxes ( ) const
inlineinherited

Definition at line 79 of file Endpoint.h.

◆ getNPoints()

virtual int lsst::afw::geom::BaseVectorEndpoint< coord::IcrsCoord >::getNPoints ( Array const &  arr) const
overridevirtualinherited

Return the number of points in an array.

Implements lsst::afw::geom::BaseEndpoint< coord::IcrsCoord, std::vector< coord::IcrsCoord > >.

◆ makeFrame()

virtual std::shared_ptr<ast::Frame> lsst::afw::geom::IcrsCoordEndpoint::makeFrame ( ) const
overridevirtual

Create a Frame that can be used with this end point in a Transform.

Reimplemented from lsst::afw::geom::BaseEndpoint< coord::IcrsCoord, std::vector< coord::IcrsCoord > >.

◆ normalizeFrame()

virtual void lsst::afw::geom::IcrsCoordEndpoint::normalizeFrame ( std::shared_ptr< ast::Frame >  framePtr) const
overridevirtual

Check that framePtr points to a SkyFrame and set longitude axis to 0, latitude to 1.

Reimplemented from lsst::afw::geom::BaseEndpoint< coord::IcrsCoord, std::vector< coord::IcrsCoord > >.

◆ operator=() [1/2]

IcrsCoordEndpoint& lsst::afw::geom::IcrsCoordEndpoint::operator= ( IcrsCoordEndpoint const &  )
delete

◆ operator=() [2/2]

IcrsCoordEndpoint& lsst::afw::geom::IcrsCoordEndpoint::operator= ( IcrsCoordEndpoint &&  )
delete

◆ pointFromData()

virtual Point lsst::afw::geom::IcrsCoordEndpoint::pointFromData ( std::vector< double > const &  data) const
overridevirtual

Get a single point from raw data.

Parameters
[in]dataData as a vector of length NAxes
Returns
the corresponding point

Implements lsst::afw::geom::BaseEndpoint< coord::IcrsCoord, std::vector< coord::IcrsCoord > >.


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