22 #ifndef ASTSHIM_LUTMAP_H
23 #define ASTSHIM_LUTMAP_H
27 #include "astshim/base.h"
28 #include "astshim/Mapping.h"
76 explicit LutMap(std::vector<double>
const & lut,
double start,
double inc, std::string
const & options=
"")
78 Mapping(reinterpret_cast<AstMapping *>(
79 astLutMap(lut.size(), lut.data(), start, inc, options.c_str())
91 std::shared_ptr<LutMap>
copy()
const {
107 return _copyImpl<LutMap, AstLutMap>();
112 Mapping(reinterpret_cast<AstMapping *>(rawptr))
115 std::ostringstream os;
116 os <<
"this is a " <<
getClass() <<
", which is not a LutMap";
117 throw std::invalid_argument(os.str());
int getLutInterp() const
Definition: LutMap.h:103
virtual std::shared_ptr< Object > _copyPolymorphic() const override
Definition: LutMap.h:106
std::string getClass() const
Definition: Object.h:117
std::shared_ptr< LutMap > copy() const
Return a deep copy of this object.
Definition: LutMap.h:91
double getD(std::string const &attrib) const
Definition: Object.h:360
double getLutEpsilon() const
Definition: LutMap.h:98
LutMap(AstLutMap *rawptr)
Construct an LutMap from a raw AST pointer.
Definition: LutMap.h:111
int getI(std::string const &attrib) const
Definition: Object.h:386
LutMap(std::vector< double > const &lut, double start, double inc, std::string const &options="")
Definition: LutMap.h:76
AstObject const * getRawPtr() const
Definition: Object.h:260