ValueMapRenderer.h
1.7 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
53
54
#pragma once
#ifndef _ValueMapRenderer_H_
#define _ValueMapRenderer_H_
#include<map>
using namespace std;
#include"Renderer.h"
#include <boost/property_tree/ptree.hpp>
#include <boost/property_tree/xml_parser.hpp>
#include <boost/foreach.hpp>
namespace DmapCore_30
{
class ValueMapRendererComponent;
class DataCollection;
class clsCrSurf;
class CORE_EXPORT ValueMapRenderer :public Renderer
{
public:
ValueMapRenderer();
~ValueMapRenderer();
static ValueMapRenderer* CreateNew();
virtual int RendererType();
virtual bool Parse(boost::property_tree::ptree &pt, AppendBuffer *f);
virtual bool DrawData(clsCrSurf* pClsCS, DataCollection* data, bool drawSimpleData, char* pFlag = NULL);
virtual bool DrawData(clsCrSurf* pClsCS, DataCollection* data, int dataIndex, char* pFlag = NULL);
virtual bool DrawLegend(clsCrSurf* pClsCS, shared_ptr<legendParamater> pLegendParamater,int layerType, char* pFlag = NULL);
virtual void ToJson(AppendBuffer *ab);
virtual bool ParsePtree( boost::property_tree::ptree &pt);
const char* GetTag();
bool SetTag(const char* sTag);
Renderer* GetDefaultSymbol();
bool SetDefaultSymbol(Renderer* defaultSymbol);
const char* GetField();
bool SetField(const char* sField);
int GetComponentCount();
ValueMapRendererComponent* GetComponent(int index);
bool SetComponent(int index, ValueMapRendererComponent* component);
bool AddComponent(ValueMapRendererComponent* component);
bool RemoveComponent(int index);
bool ClearComponents();
void TryAddField(vector<string>&pvField);
bool TryFindHeatRenderer(){ return false; }
string m_sTag;
Renderer* m_pDefaultSymbol;
string m_sField;
vector<ValueMapRendererComponent*> m_vComponents;
};
}
#endif