36 #ifndef PROFILESURFACE_EMPTY_OBJECT_H
37 #define PROFILESURFACE_EMPTY_OBJECT_H
64 class GeoTessMetaData;
85 static string class_name() {
return "ProfileSurfaceEmpty"; }
104 virtual bool operator ==(
const GeoTessProfile& p)
const {
return p.
getType() == GeoTessProfileType::SURFACE_EMPTY; }
114 virtual double getValue(
int attributeIndex,
int nodeIndex)
const {
return NaN_DOUBLE; }
122 virtual double getValueTop(
int attributeIndex)
const {
return NaN_DOUBLE; }
134 virtual bool isNaN(
int nodeIndex,
int attributeIndex) {
return true; }
141 int attributeIndex,
double radius,
142 bool allowRadiusOutOfRange)
const
143 {
return NaN_DOUBLE; }
148 virtual void setData(
const vector<GeoTessData*>& inData) { }
162 os << endl <<
"ERROR in ProfileSurfaceEmpty::getData" << endl
163 <<
"Unsupported method call." << endl;
174 os << endl <<
"ERROR in ProfileSurfaceEmpty::getData" << endl
175 <<
"Unsupported method call." << endl;
186 os << endl <<
"ERROR in ProfileSurfaceEmpty::getData" << endl
187 <<
"Unsupported method call." << endl;
197 os << endl <<
"ERROR in ProfileSurfaceEmpty::getDataBottom" << endl
198 <<
"Unsupported method call." << endl;
209 os << endl <<
"ERROR in ProfileSurfaceEmpty::getDataTop" << endl
210 <<
"Unsupported method call." << endl;
221 os << endl <<
"ERROR in ProfileSurfaceEmpty::getDataBottom" << endl
222 <<
"Unsupported method call." << endl;
233 os << endl <<
"ERROR in ProfileSurfaceEmpty::getDataBottom" << endl
234 <<
"Unsupported method call." << endl;
243 virtual float getRadius(
int i)
const {
return NaN_FLOAT; }
248 virtual void setRadii(
const vector<float>& newRadii) { }
276 virtual float*
getRadii() {
return (
float*) NULL; }
288 GeoTessProfileSurfaceEmpty(IFStreamAscii& ifs, GeoTessMetaData& gtmd) : GeoTessProfile() { }
294 virtual ~GeoTessProfileSurfaceEmpty() { }
299 virtual void write(IFStreamBinary& ofs)
300 { ofs.writeByte((
byte) GeoTessProfileType::SURFACE_EMPTY.ordinal()); }
305 virtual void write(IFStreamAscii& ofs)
306 { ofs.writeInt(GeoTessProfileType::SURFACE_EMPTY.ordinal()); ofs.writeNL();}
316 virtual int findClosestRadiusIndex(
double radius)
const {
return -1; }
325 virtual void setPointIndex(
int nodeIndex,
int pntIndex) { }
334 virtual void resetPointIndices() { }
343 virtual int getPointIndex(
int nodeIndex)
const {
return -1; }
348 virtual GeoTessProfile* copy() {
return new GeoTessProfileSurfaceEmpty(); }
357 #endif // PROFILESURFACE_EMPTY_OBJECT_H
static string class_name()
Returns the class name.
Definition: GeoTessProfileSurfaceEmpty.h:85
virtual float getRadiusBottom() const
Get the radius at the bottom of the profile, in km.
Definition: GeoTessProfileSurfaceEmpty.h:261
virtual LONG_INT getMemory()
Definition: GeoTessProfileSurfaceEmpty.h:92
A Profile object that defines a single Data object and no radius value.
Definition: GeoTessProfileSurfaceEmpty.h:77
virtual int getNData() const
Get the number of Data objects that comprise this profile.
Definition: GeoTessProfileSurfaceEmpty.h:271
virtual GeoTessData ** getData()
Retrieve a reference to all of the Data obects associated with this Profile.
Definition: GeoTessProfileSurfaceEmpty.h:159
virtual void setData(int index, GeoTessData *inData)
Resets the data object at index to the new input data.
Definition: GeoTessProfileSurfaceEmpty.h:153
virtual const GeoTessData & getDataBottom() const
Get the Data object at the bottom of the profile.
Definition: GeoTessProfileSurfaceEmpty.h:230
virtual double getValue(int attributeIndex, int nodeIndex) const
Retrieve the value of the specified attribute from this profile at the specified node index...
Definition: GeoTessProfileSurfaceEmpty.h:114
virtual float getRadius(int i) const
Get the i'th radius value in this profile in km.
Definition: GeoTessProfileSurfaceEmpty.h:243
Definition: ArrayReuse.h:55
Opens a file for binary read and write access.
Definition: IFStreamBinary.h:79
virtual float getRadiusTop() const
Get the radius at the top of the profile, in km.
Definition: GeoTessProfileSurfaceEmpty.h:256
Enumeration of the interpolation algorithms supported by GeoTess including LINEAR, NATURAL_NEIGHBOR and CUBIC_SPLINE.
Definition: GeoTessInterpolatorType.h:71
virtual bool isNaN(int nodeIndex, int attributeIndex)
Return true if the specified Data value is NaN.
Definition: GeoTessProfileSurfaceEmpty.h:134
Enumeration of the valid Profile types, including EMPTY, THIN, CONSTANT, NPOINT and SURFACE...
Definition: GeoTessProfileType.h:69
virtual const GeoTessProfileType & getType() const
One of EMPTY, THIN, CONSTANT, NPOINT, SURFACE.
virtual void setRadius(int index, float radius)
Replace the radius at the specified nodeIndex.
Definition: GeoTessProfileSurfaceEmpty.h:250
virtual int getNRadii() const
Get the number of radii that comprise this profile.
Definition: GeoTessProfileSurfaceEmpty.h:266
Manages a single data value attached to a grid node.
Definition: GeoTessData.h:63
virtual GeoTessData * getDataBottom()
Get the Data object at the bottom of the profile.
Definition: GeoTessProfileSurfaceEmpty.h:218
virtual const GeoTessProfileType & getType() const
Returns ProfileType (SURFACE).
Definition: GeoTessProfileSurfaceEmpty.h:99
virtual GeoTessData * getData(int i)
Retrieve a reference the i'th Data object.
Definition: GeoTessProfileSurfaceEmpty.h:171
An exception class for all GeoTess objects.
Definition: GeoTessException.h:65
virtual const GeoTessData & getDataTop() const
Get the Data object at the top of the profile.
Definition: GeoTessProfileSurfaceEmpty.h:206
#define byte
signed-byte typedef
Definition: CPPGlobals.h:94
virtual int class_size() const
Returns the class size.
Definition: GeoTessProfileSurfaceEmpty.h:90
virtual void setRadii(const vector< float > &newRadii)
Replace the radii currently associated with this Profile with new values.
Definition: GeoTessProfileSurfaceEmpty.h:248
virtual void setData(const vector< GeoTessData * > &inData)
Resets the data object to the new input data.
Definition: GeoTessProfileSurfaceEmpty.h:148
#define LONG_INT
Definition: CPPGlobals.h:111
Abstract class that manages the radii and data values that span a single layer associated with a sing...
Definition: GeoTessProfile.h:96
Abstract base class that manages the data values attached to a single grid point. ...
Definition: GeoTessData.h:75
virtual const GeoTessData & getData(int i) const
Retrieve a reference the i'th Data object.
Definition: GeoTessProfileSurfaceEmpty.h:183
virtual double getValueTop(int attributeIndex) const
Retrieve the value of the specified attribute at the top of the layer.
Definition: GeoTessProfileSurfaceEmpty.h:122
virtual float * getRadii()
Returns NULL.
Definition: GeoTessProfileSurfaceEmpty.h:276
GeoTessProfileSurfaceEmpty()
Definition: GeoTessProfileSurfaceEmpty.h:80
virtual GeoTessData * getDataTop()
Get the Data object at the top of the profile.
Definition: GeoTessProfileSurfaceEmpty.h:194
#define GEOTESS_EXP_IMP
Definition: CPPGlobals.h:71
virtual double getValue(const GeoTessInterpolatorType &rInterpType, int attributeIndex, double radius, bool allowRadiusOutOfRange) const
Retrieve the value of the specified attribute interpolated at the specified radius.
Definition: GeoTessProfileSurfaceEmpty.h:140