dmptilematrixset.h
1.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
/**************************************************************************
* file: dmptilematrixset.h
* Author: wanzhongping
* Date: 2021-11-16 15:52:27
* Email: zhongpingw@chinadci.com
* copyright: 广州城市信息研究所有限公司
***************************************************************************/
#ifndef __dmptilematrixset_h__
#define __dmptilematrixset_h__
#include "dmap_core.h"
#include <string>
#include <vector>
#include <boost/property_tree/ptree.hpp>
#include "dmppoint.h"
typedef struct
{
int id;
double scaleDenominator;
double resolution;
} TileLevel;
class CORE_EXPORT DmpTileMatrixSet
{
public:
DmpTileMatrixSet();
~DmpTileMatrixSet();
bool readXml(const boost::property_tree::ptree &matrixSetNode);
bool writeXml(boost::property_tree::ptree &matrixSetNode);
std::string id() const { return id_;}
std::string crs() const { return crs_; }
int tileCols() const { return tileCols_; }
int tileRows() const { return tileRows_; }
int dpi() const { return dpi_; }
DmpPoint *tileOrigin() const { return tileOrigin_; }
std::vector<TileLevel*> tileLevels() const { return tileLevels_; }
private:
std::string id_;
std::string crs_;
int tileCols_;
int tileRows_;
int dpi_;
DmpPoint *tileOrigin_;
std::vector<TileLevel*> tileLevels_;
};
#endif // __dmptilematrixset_h__