26 #ifndef __TERRALIB_DATAACCESS_INTERNAL_FIELDNAMEVALIDATOR_H 
   27 #define __TERRALIB_DATAACCESS_INTERNAL_FIELDNAMEVALIDATOR_H 
   29 #include "../Config.h" 
   56       bool addFieldName(
const std::string& fieldName, std::string& adjustedFieldName);
 
   58       bool exists(
const std::string& fieldName) 
const;
 
This class is responsible for validating field names. It can handle size limits, fix special characte...
 
bool addFieldName(const std::string &fieldName, std::string &adjustedFieldName)
 
bool m_replaceDotForUnderline
If TRUE, all 'dots' characters present in a "table.property" format will be replaced by an underline ...
 
std::vector< std::string > m_vecAdjustedNames
Internal vector containing the ajusted (or the original if no adjustment hasbeen needed) names.
 
bool exists(const std::string &fieldName) const
 
bool addFieldName(const std::string &fieldName)
 
static std::string adjustFieldNameMaxSize(const std::string &fieldName, int fieldNameMaxSize)
 
static std::string replaceSpecialCharacters(const std::string &fieldName)
 
std::set< std::string > m_setAdjustedNames
Internal set used to make a fast check to make sure there arent repeated field names.
 
FieldNameValidator(int fieldNameMaxSize, bool replaceDotForUnderline, bool replaceSpecialChars)
 
const std::vector< std::string > & getAdjustedNames() const
 
bool m_replaceSpecialChars
If TRUE, the special chars will be replaced.
 
static std::string replaceDotForUnderline(const std::string &fieldName)
 
int m_fieldNameMaxSize
The field name maximum size. -1 means no limit.
 
#define TEDATAACCESSEXPORT
You can use this macro in order to export/import classes and functions from this module.