28#ifndef PROJECTDEFMEMORY_H
29#define PROJECTDEFMEMORY_H
39#include "../gui/listgenreport.h"
51static wxString PRJDEF_EXPORT_TYPE_STRING[] = {wxTRANSLATE(
"Shapefiles"), wxTRANSLATE(
"Graphics (EPS)")};
55static wxString PRJDEF_UNIT_TYPE_STRING[] = {wxTRANSLATE(
"Meters"), wxTRANSLATE(
"Degrees (DD)"),
56 wxTRANSLATE(
"Degrees (DMS)")};
57enum PRJDEF_UNIT_TYPE {
62static const int PRJDEF_UNIT_TYPE_NUMBER = 3;
64const wxString TABLE_COMMENT_ENUMERATION = _T(
"ENUMERATION");
68static wxString PRJDEF_PROJ_TYPE_STRING[] = {
69 wxTRANSLATE(
"Swiss projection (CH1903)"),
70 wxTRANSLATE(
"Swiss projection (CH1903+ / LV95)"),
71 wxTRANSLATE(
"World (WGS84)"),
73enum PRJDEF_PROJ_TYPE {
74 PROJ_SWISS_CH1903 = 0,
75 PROJ_SWISS_CH1903PLUS,
78static const int PRJDEF_PROJ_TYPE_NUMBER = 3;
82static wxString PRJDEF_FIELD_TYPE_STRING[] = {wxTRANSLATE(
"Enumeration"), wxTRANSLATE(
"Text"), wxTRANSLATE(
"Integer"),
83 wxTRANSLATE(
"Float"), wxTRANSLATE(
"Date")};
84enum PRJDEF_FIELD_TYPE {
85 TM_FIELD_ENUMERATION = 0,
91static const int PRJDEF_FIELD_TYPE_NUMBER = 5;
93static wxString PRJDEF_FIELD_ORIENTATION_STRING[] = {wxTRANSLATE(
"Yes"), wxTRANSLATE(
"")};
95enum PRJDEF_FIELD_ORIENTATION {
96 TM_FIELD_ORIENT_YES = 0,
110static wxString PRJDEF_LAYERS_TYPE_STRING[] = {wxTRANSLATE(
"Line"), wxTRANSLATE(
"Point"), wxTRANSLATE(
"Polygon")};
111enum PRJDEF_LAYERS_TYPE {
116static const int PRJDEF_LAYERS_TYPE_NUMBER = 3;
120static wxString PRJDEF_OBJECTS_FREQ_STRING[] = {_T(
""), wxTRANSLATE(
"Frequent")};
121enum PRJDEF_OBJECTS_FREQ {
122 OBJECT_LESS_FREQUENT = 0,
125static const int PRJDEF_OBJECTSS_FREQ_NUMBER = 2;
127static const long NULL_LONG_VALUE = -9999;
128static const wxString NULL_LONG_STRING_VALUE = _T(
"-9999");
139 void InitMemberValues();
143 wxString m_ValueCode;
144 wxString m_ValueName;
172 wxString m_ObjectCode;
174 wxString m_ObjectName;
175 PRJDEF_OBJECTS_FREQ m_ObjectFreq;
177 wxString m_ParentLayerName;
183 void InitMemberValues();
200 void InitMemberValues();
202 wxString ExtractValuesFromString(
const wxString& fielddef);
206 wxString m_Fieldname;
207 wxString m_FieldOldName;
208 PRJDEF_FIELD_TYPE m_FieldType;
209 int m_FieldPrecision;
211 bool m_FieldOrientation;
212 bool m_FieldConstrain;
215 wxArrayLong m_StoreDeleteCodedValues;
218 PrjMemFieldCodedValArray m_pCodedValueArray;
224 bool SetValues(
const wxString& fieldname,
const wxString& fielddef,
const wxString& fieldcomment = _T(
""));
228 static wxString GetOrientationName() {
229 return _T(
"ORIENTATION");
248 void InitMemberValues();
252 PRJDEF_LAYERS_TYPE m_LayerType;
253 wxString m_LayerName;
255 wxString m_LayerPolygonDefaultValue;
263 wxArrayString m_StoreDeleteFields;
278 void InitMemberValues();
Storing coded val linked to a field in memory.
Definition projectdefmemory.h:137
ProjectDefMemoryFieldsCodedVal & operator=(const ProjectDefMemoryFieldsCodedVal &source)
Copy fields coded values.
Definition projectdefmemory.cpp:76
static int ExtractCodedValuesFromString(const wxString &codedvalue, wxArrayString &results)
Tokenize coded values.
Definition projectdefmemory.cpp:50
Storing Fields property in memory.
Definition projectdefmemory.h:198
bool SetValues(const wxString &fieldname, const wxString &fielddef, const wxString &fieldcomment=_T(""))
Assign values based on string.
Definition projectdefmemory.cpp:182
ProjectDefMemoryFields & operator=(const ProjectDefMemoryFields &source)
Copy Field values (and array of coded values)
Definition projectdefmemory.cpp:120
bool GetStringTypeFromValues(wxString &sResult)
Create string type.
Definition projectdefmemory.cpp:271
Storing layers properties in memory.
Definition projectdefmemory.h:246
~ProjectDefMemoryLayers()
Definition projectdefmemory.cpp:312
PrjMemFieldArray m_pLayerFieldArray
list of fields related to a layer
Definition projectdefmemory.h:258
ProjectDefMemoryLayers & operator=(const ProjectDefMemoryLayers &source)
Overloading = operator.
Definition projectdefmemory.cpp:344
PrjMemObjectsArray m_pLayerObjectArray
list of objects related to a layer
Definition projectdefmemory.h:260
Storing object properties in memory.
Definition projectdefmemory.h:168
Definition projectdefmemory.h:276
PRJDEF_EXPORT_TYPE
Type of export we want.
Definition projectdefmemory.h:46
@ EXPORT_SHAPEFILE
shapefile is selected (default)
Definition projectdefmemory.h:47
@ EXPORT_GRAPHIC
we specify export to graphical format
Definition projectdefmemory.h:48