lsst.astshim
21.0.0-2-g45278ab+4fcf437b75
|
Go to the documentation of this file.
22 #ifndef ASTSHIM_UNITMAP_H
23 #define ASTSHIM_UNITMAP_H
54 explicit UnitMap(
int ncoord, std::string
const &options =
"")
55 :
Mapping(reinterpret_cast<AstMapping *>(astUnitMap(ncoord,
"%s", options.c_str()))) {
68 std::shared_ptr<UnitMap>
copy()
const {
return std::static_pointer_cast<UnitMap>(
copyPolymorphic()); }
72 return copyImpl<UnitMap, AstUnitMap>();
76 explicit UnitMap(AstUnitMap *rawptr) :
Mapping(reinterpret_cast<AstMapping *>(rawptr)) {
78 std::ostringstream os;
79 os <<
"this is a " <<
getClassName() <<
", which is not a UnitMap";
80 throw std::invalid_argument(os.str());
void assertOK(AstObject *rawPtr1=nullptr, AstObject *rawPtr2=nullptr)
Definition: base.cc:49
UnitMap(int ncoord, std::string const &options="")
Definition: UnitMap.h:54
UnitMap & operator=(UnitMap const &)=delete
UnitMap(UnitMap const &)=default
Copy constructor: make a deep copy.
std::string getClassName() const
Definition: Object.h:139
UnitMap & operator=(UnitMap &&)=default
UnitMap(UnitMap &&)=default
UnitMap(AstUnitMap *rawptr)
Construct a UnitMap from a raw AST pointer.
Definition: UnitMap.h:76
std::shared_ptr< UnitMap > copy() const
Return a deep copy of this object.
Definition: UnitMap.h:68
AST wrapper classes and functions.
Definition: attributes_channel.dox:1
virtual std::shared_ptr< Object > copyPolymorphic() const override
Definition: UnitMap.h:71
virtual ~UnitMap()
Definition: UnitMap.h:59
AstObject const * getRawPtr() const
Definition: Object.h:292