ToolMap
Loading...
Searching...
No Matches
ProjectDefMemoryFields Class Reference

Storing Fields property in memory. More...

#include <projectdefmemory.h>

Public Member Functions

bool SetValues (const wxString &fieldname, const wxString &fielddef, const wxString &fieldcomment=_T(""))
 Assign values based on string.
 
bool GetStringTypeFromValues (wxString &sResult)
 Create string type.
 
ProjectDefMemoryFieldsoperator= (const ProjectDefMemoryFields &source)
 Copy Field values (and array of coded values)
 

Static Public Member Functions

static wxString GetOrientationName ()
 

Public Attributes

int m_FieldID
 
wxString m_Fieldname
 
wxString m_FieldOldName
 
PRJDEF_FIELD_TYPE m_FieldType
 
int m_FieldPrecision
 
int m_FieldScale
 
bool m_FieldOrientation
 
bool m_FieldConstrain
 
wxArrayLong m_StoreDeleteCodedValues
 
PrjMemFieldCodedValArray m_pCodedValueArray
 

Detailed Description

Storing Fields property in memory.

This class is used in PrjMemFieldArray, a wxArray type class for storing all fields related to a layer.

Author
Lucien Schreiber (c) CREALP 2007
Date
18 December 2007

Member Function Documentation

◆ GetStringTypeFromValues()

bool ProjectDefMemoryFields::GetStringTypeFromValues ( wxString &  sResult)

Create string type.

This function create string type :

  • DATE
  • ENUM(item1,item2,...)
  • VARCHAR(Length)
  • DECIMAL(Precision, Scale)
  • INT from the stored field type ProjectDefMemoryFields::m_FieldType
    Parameters
    sResultWill be modified to contain the string type who could be used for adding or modifing columns
    Returns
    Always true for the moment
    Author
    Lucien Schreiber (c) CREALP 2007
    Date
    24 April 2008

◆ operator=()

ProjectDefMemoryFields & ProjectDefMemoryFields::operator= ( const ProjectDefMemoryFields source)

Copy Field values (and array of coded values)

Returns
always true
Author
Lucien Schreiber (c) CREALP 2009
Date
17 March 2009

◆ SetValues()

bool ProjectDefMemoryFields::SetValues ( const wxString &  fieldname,
const wxString &  fielddef,
const wxString &  fieldcomment = _T("") 
)

Assign values based on string.

This function may be used for assigning values to a ProjectDefMemoryFields object from a string (for applications see string extracted from some SQL query like 'SHOW FULL COLUMNS FROM ...'

Parameters
fielddefan Array of String containing minimum 2 items (verified internally), the first item should be the field name and the second is a string with the width of the field or the values in case of enumerations
Returns
TRUE if values were assigned
Author
Lucien Schreiber (c) CREALP 2007
Date
17 April 2008

The documentation for this class was generated from the following files: