WXP C++ Library Version 6.74.9
Loading...
Searching...
No Matches
ShapeData.h
1#ifndef _WINC_SHAPEDATA
2#define _WINC_SHAPEDATA
3
4#include <WXP/EarthPoints.h>
5#include <WXP/StrLib.h>
6
7namespace WXP {
8 class ShapeData {
9 int index;
10 char name[100];
11 EarthRange range;
12 EarthPoints pts;
13
14 public:
15 ShapeData();
16 int init();
17 int print();
18 int printData();
19
20 inline int setIndex( int val ){ index = val; return 1; };
21 inline int getIndex(){ return index; };
23 inline const char *getName(){ return name; };
24 inline int setName( const char *rname ){ StrLib::copy( name, 100, rname ); return 1; };
25 inline int clearPoints(){ return pts.clear(); };
26 inline int addPoint( EarthPoint &ept ){ return pts.add( ept ); };
27 inline int getNum(){ return pts.getNum(); };
28 inline EarthPoint getPoint( int ind ){ return pts.get( ind ); };
29 inline int setRange( EarthRange &r ){ range = r; return 1; };
30 inline EarthRange getRange(){ return range; };
31
32 friend class ShapeFile;
33 };
34}
35#endif
36
This class creates an array a earth points (lat, lon)
Definition EarthPoints.h:9
int getNum()
Definition EarthPoints.h:52
int add(float lat, float lon)
Definition EarthPoints.cc:141
int clear()
Definition EarthPoints.h:26
int get(int ind, EarthPoint &ept)
Definition EarthPoints.cc:200
This struct stores ShapeFile data.
Definition ShapeData.h:8
const char * getName()
Definition ShapeData.h:23
int print()
Definition ShapeData.cc:32
int init()
Definition ShapeData.cc:22
static int copy(char *s1, int len1, const char s2)
Definition StrLib.cc:506
All WXP classes fall under the WXP namespace.
Definition Angle.h:4
This struct defines a range of latitudes and longitudes.
Definition EarthRange.h:5