Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members   Related Pages  

DBOBJDefinitionField Class Reference

#include <dbobjdefinition.hpp>

Inheritance diagram for DBOBJDefinitionField:

Inheritance graph
[legend]
Collaboration diagram for DBOBJDefinitionField:

Collaboration graph
[legend]
List of all members.

Detailed Description

This class represents the definition of a field.

Definition at line 77 of file dbobjdefinition.hpp.

Public Methods

 DBOBJDefinitionField ()
 Constructor. Inits private data members.

 ~DBOBJDefinitionField ()
 Destructor. Releases private data members.

const char * getName () const
 Returns field name.

const char * getDBField () const
 Returns the name of the column on which the field is mapped.

const char * getDBAlias () const
 Returns the alias used in SQL statements for this field.

const char * getMap () const
 Returns field's reduced type (numeric / alphanumeric).

const char * getIValue () const
 Returns the value that is given to the field in case of an INSERT action.

const char * getUValue () const
 Returns the value that is given to the field in case of an UPDATE action.

const char * getDValue () const
 Returns the value that is given to the field in case of an DELETE action.

const char * getValue () const
 Returns the value that is given to the field in case of an INSERT, UPDATE or DELETE action.

const char * getDateFormat () const
 Returns the date format.

const char * getDBSpecProps () const
 Returns field's DB specific type properties list. This list is composed of type codes specific to RDBMS vendor. The format of this list is : ( OTL Type, DB Type, Size, Scale, Precision, Null OK ).

bool isAttribute () const
 Returns true if the field is rendered as an attribute in the XML stream.

bool isHidden () const
 Returns true if the field is hidden in the XML stream.

bool isPkey () const
 Returns true if the field is a primary key of its parent node.

DBOBJDefinitionNodegetParent () const
 Returns field's parent definition node.

void setName (const char *p_szName)
 Sets field's name.

void setDBField (const char *p_szDBField)
 Sets field's mapping column name.

void setDBAlias (const char *p_szDBAlias)
 Sets field's SQL alias.

void setMap (const char *p_szMap)
 Sets field's reduces type.

void setIValue (const char *p_szIValue)
 Sets field's value for INSERT actions.

void setUValue (const char *p_szUValue)
 Sets field's value for UPDATE actions.

void setDValue (const char *p_szDValue)
 Sets field's value for DELETE actions.

void setValue (const char *p_szValue)
 Sets field's value for all actions.

void setDateFormat (const char *p_szDateFormat)
 Sets field's value for all actions.

void setDBSpecProps (const char *p_szDBSpecProps)
 Sets field's RDMS vendor specific properties. The format of this list is : ( OTL Type, DB Type, Size, Scale, Precision, Null OK ).

void setAttribute (bool p_boolAttribute)
 Sets whether the field is rendered as an attribute in the XML stream.

void setHidden (bool p_boolHidden)
 Sets whether the field is rendered as an attribute in the XML stream.

void setPkey (bool p_boolPkey)
 Sets whether the field is a primary key of parent node.

void setParent (DBOBJDefinitionNode *p_pParentDefinition)
 Sets field's parent definition node.

void getXML (XMLStreamConsumer *p_pXMLBufOut)
 Outputs Definition objects XML stream.


Constructor & Destructor Documentation

BEGIN_XDFLENGINE_NS DBOBJDefinitionField::DBOBJDefinitionField  
 

Constructor. Inits private data members.

Definition at line 55 of file dbobjdefinition.cpp.

References DEBUG_CREATE, and importCharBuffer().

DBOBJDefinitionField::~DBOBJDefinitionField  
 

Destructor. Releases private data members.

Definition at line 83 of file dbobjdefinition.cpp.

References DEBUG_DEL, and releaseCharBuffer().


Member Function Documentation

const char * DBOBJDefinitionField::getDateFormat   const
 

Returns the date format.

Returns:
(string) Field's date format.

Definition at line 186 of file dbobjdefinition.cpp.

References DEBUG_FUNC, and exportCharBuffer().

Referenced by DBOBJSetStreamer::getFieldBindVar(), DBOBJSetStreamer::getFieldValue(), and getXML().

const char * DBOBJDefinitionField::getDBAlias   const
 

Returns the alias used in SQL statements for this field.

Returns:
(string) Field DB column alias.

Definition at line 132 of file dbobjdefinition.cpp.

References DEBUG_FUNC, and exportCharBuffer().

const char * DBOBJDefinitionField::getDBField   const
 

Returns the name of the column on which the field is mapped.

Returns:
(string) Field DB column Name.

Definition at line 123 of file dbobjdefinition.cpp.

References DEBUG_FUNC, and exportCharBuffer().

Referenced by DBOBJSetStreamer::buildINSERTStatement(), DBOBJSetStreamer::buildUPDATEStatement(), DBOBJSetStreamer::buildWHEREclause(), AutodescStreamer::completeDefinitionNode(), getXML(), and DDLStreamer::makeNodeDDL().

const char * DBOBJDefinitionField::getDBSpecProps   const
 

Returns field's DB specific type properties list. This list is composed of type codes specific to RDBMS vendor. The format of this list is : ( OTL Type, DB Type, Size, Scale, Precision, Null OK ).

Returns:
(string) Field's DB specific type properties list.

Definition at line 195 of file dbobjdefinition.cpp.

References DEBUG_FUNC, and exportCharBuffer().

Referenced by DBOBJSetStreamer::getFieldBindVar(), getXML(), and DDLStreamer::makeNodeDDL().

const char * DBOBJDefinitionField::getDValue   const
 

Returns the value that is given to the field in case of an DELETE action.

Returns:
(string) Field's DELETE value.

Definition at line 168 of file dbobjdefinition.cpp.

References DEBUG_FUNC, and exportCharBuffer().

Referenced by DBObjectField::getValue(), and getXML().

const char * DBOBJDefinitionField::getIValue   const
 

Returns the value that is given to the field in case of an INSERT action.

Returns:
(string) Field's INSERT value.

Definition at line 150 of file dbobjdefinition.cpp.

References DEBUG_FUNC, and exportCharBuffer().

Referenced by DBObjectField::getValue(), and getXML().

const char * DBOBJDefinitionField::getMap   const
 

Returns field's reduced type (numeric / alphanumeric).

Returns:
(string) Field's reduced type.

Definition at line 141 of file dbobjdefinition.cpp.

References DEBUG_FUNC, and exportCharBuffer().

Referenced by DBOBJSetStreamer::getFieldBindVar(), DBOBJSetStreamer::getFieldValue(), getXML(), DDLStreamer::makeNodeDDL(), and SAXDBOBJDefinitionBuilder::startElement().

const char * DBOBJDefinitionField::getName   const
 

Returns field name.

Returns:
Field Name (string) .

Definition at line 114 of file dbobjdefinition.cpp.

References DEBUG_FUNC, and exportCharBuffer().

Referenced by DBOBJDefinitionNode::addField(), DBOBJSetStreamer::buildINSERTStatement(), DBOBJSetStreamer::buildUPDATEStatement(), DBOBJSetStreamer::buildWHEREclause(), DBOBJDefinitionNode::getXML(), getXML(), DBObjectField::setDefinition(), and SAXDBOBJDefinitionBuilder::startElement().

DBOBJDefinitionNode * DBOBJDefinitionField::getParent   const
 

Returns field's parent definition node.

Returns:
(DBOBJDefinitionNode*) Parent definition node.

Definition at line 231 of file dbobjdefinition.cpp.

References DEBUG_FUNC.

const char * DBOBJDefinitionField::getUValue   const
 

Returns the value that is given to the field in case of an UPDATE action.

Returns:
(string) Field's UPDATE value.

Definition at line 159 of file dbobjdefinition.cpp.

References DEBUG_FUNC, and exportCharBuffer().

Referenced by DBObjectField::getValue(), and getXML().

const char * DBOBJDefinitionField::getValue   const
 

Returns the value that is given to the field in case of an INSERT, UPDATE or DELETE action.

Returns:
(string) Field's value.

Definition at line 177 of file dbobjdefinition.cpp.

References DEBUG_FUNC, and exportCharBuffer().

Referenced by DBObjectField::getValue(), and getXML().

void DBOBJDefinitionField::getXML XMLStreamConsumer   p_pXMLBufOut
 

Outputs Definition objects XML stream.

Parameters:
p_pXMLBufOut (XMLStreamBuffer*) XML Buffer to output XML stream in.

Definition at line 370 of file dbobjdefinition.cpp.

References DBOBJDEFFIELD_DATE_FORMAT, DBOBJDEFFIELD_DBSPEC, DBOBJDEFFIELD_DVALUE, DBOBJDEFFIELD_FIELD, DBOBJDEFFIELD_HIDDEN, DBOBJDEFFIELD_IVALUE, DBOBJDEFFIELD_MAP, DBOBJDEFFIELD_NAME, DBOBJDEFFIELD_TAGNAME, DBOBJDEFFIELD_UVALUE, DBOBJDEFFIELD_VALUE, DEBUG_FUNC, getDateFormat(), getDBField(), getDBSpecProps(), getDValue(), getIValue(), getMap(), getName(), getUValue(), getValue(), isHidden(), REQ_FALSE, and REQ_TRUE.

Referenced by DBOBJDefinitionNode::getXML().

bool DBOBJDefinitionField::isAttribute   const
 

Returns true if the field is rendered as an attribute in the XML stream.

Returns:
(bool) TRUE if the field is rendered as an attribute.

Definition at line 204 of file dbobjdefinition.cpp.

References DEBUG_FUNC.

Referenced by DBOBJSetStreamer::getFieldBindVar(), and DBObjectField::setDefinition().

bool DBOBJDefinitionField::isHidden   const
 

Returns true if the field is hidden in the XML stream.

Returns:
(bool) TRUE if the field is hidden.

Definition at line 213 of file dbobjdefinition.cpp.

References DEBUG_FUNC.

Referenced by getXML().

bool DBOBJDefinitionField::isPkey   const
 

Returns true if the field is a primary key of its parent node.

Returns:
(bool) TRUE if the field is primary key.

Definition at line 222 of file dbobjdefinition.cpp.

References DEBUG_FUNC.

Referenced by DBOBJSetStreamer::buildUPDATEStatement().

void DBOBJDefinitionField::setAttribute bool    p_boolAttribute
 

Sets whether the field is rendered as an attribute in the XML stream.

Parameters:
p_boolAttribute (bool) If TRUE, field is rendered as an attribute in the XML stream.

Definition at line 332 of file dbobjdefinition.cpp.

References DEBUG_FUNC.

Referenced by AutodescStreamer::completeDefinitionNode(), and SAXDBOBJDefinitionBuilder::startElement().

void DBOBJDefinitionField::setDateFormat const char *    p_szDateFormat
 

Sets field's value for all actions.

Parameters:
p_szValue (string) Field's value.

Definition at line 314 of file dbobjdefinition.cpp.

References DEBUG_FUNC, and importCharBuffer().

Referenced by AutodescStreamer::completeDefinitionNode(), and SAXDBOBJDefinitionBuilder::startElement().

void DBOBJDefinitionField::setDBAlias const char *    p_szDBAlias
 

Sets field's SQL alias.

Parameters:
p_szDBAlias (string) Field's SQL alias.

Definition at line 260 of file dbobjdefinition.cpp.

References DEBUG_FUNC, and importCharBuffer().

Referenced by AutodescStreamer::completeDefinitionNode(), and SAXDBOBJDefinitionBuilder::startElement().

void DBOBJDefinitionField::setDBField const char *    p_szDBField
 

Sets field's mapping column name.

Parameters:
p_szDBField (string) Field's mapping column name.

Definition at line 251 of file dbobjdefinition.cpp.

References DEBUG_FUNC, and importCharBuffer().

Referenced by AutodescStreamer::completeDefinitionNode(), and SAXDBOBJDefinitionBuilder::startElement().

void DBOBJDefinitionField::setDBSpecProps const char *    p_szDBSpecProps
 

Sets field's RDMS vendor specific properties. The format of this list is : ( OTL Type, DB Type, Size, Scale, Precision, Null OK ).

Parameters:
p_szDBSpecProps (string) RDMS vendor specific properties.

Definition at line 323 of file dbobjdefinition.cpp.

References DEBUG_FUNC, and importCharBuffer().

Referenced by AutodescStreamer::completeDefinitionNode(), and SAXDBOBJDefinitionBuilder::startElement().

void DBOBJDefinitionField::setDValue const char *    p_szDValue
 

Sets field's value for DELETE actions.

Parameters:
p_szDValue (string) Field's DELETE value.

Definition at line 296 of file dbobjdefinition.cpp.

References DEBUG_FUNC, and importCharBuffer().

Referenced by SAXDBOBJDefinitionBuilder::startElement().

void DBOBJDefinitionField::setHidden bool    p_boolHidden
 

Sets whether the field is rendered as an attribute in the XML stream.

Parameters:
p_boolHidden (bool) If TRUE, field is rendered as an attribute in the XML stream.

Definition at line 341 of file dbobjdefinition.cpp.

References DEBUG_FUNC.

Referenced by SAXDBOBJDefinitionBuilder::startElement().

void DBOBJDefinitionField::setIValue const char *    p_szIValue
 

Sets field's value for INSERT actions.

Parameters:
p_szIValue (string) Field's INSERT value.

Definition at line 278 of file dbobjdefinition.cpp.

References DEBUG_FUNC, and importCharBuffer().

Referenced by SAXDBOBJDefinitionBuilder::startElement().

void DBOBJDefinitionField::setMap const char *    p_szMap
 

Sets field's reduces type.

Parameters:
p_szMap (string) Field's reduces type.

Definition at line 269 of file dbobjdefinition.cpp.

References DEBUG_FUNC, and importCharBuffer().

Referenced by AutodescStreamer::completeDefinitionNode(), and SAXDBOBJDefinitionBuilder::startElement().

void DBOBJDefinitionField::setName const char *    p_szName
 

Sets field's name.

Parameters:
p_szName (string) Field's Name.

Definition at line 242 of file dbobjdefinition.cpp.

References DEBUG_FUNC, and importCharBuffer().

Referenced by AutodescStreamer::completeDefinitionNode(), and SAXDBOBJDefinitionBuilder::startElement().

void DBOBJDefinitionField::setParent DBOBJDefinitionNode   p_pParentDefinition
 

Sets field's parent definition node.

Parameters:
p_pParentDefinition (DBOBJDefinitionNode*) Field's parent definition node.

Definition at line 359 of file dbobjdefinition.cpp.

References DEBUG_FUNC.

Referenced by DBOBJDefinitionNode::addField().

void DBOBJDefinitionField::setPkey bool    p_boolPkey
 

Sets whether the field is a primary key of parent node.

Parameters:
p_boolPkey (bool) If TRUE, field is a primary key.

Definition at line 350 of file dbobjdefinition.cpp.

References DEBUG_FUNC.

Referenced by DBOBJDefinitionNode::addPkey(), and DBOBJDefinitionNode::remPkey().

void DBOBJDefinitionField::setUValue const char *    p_szUValue
 

Sets field's value for UPDATE actions.

Parameters:
p_szUValue (string) Field's UPDATE value.

Definition at line 287 of file dbobjdefinition.cpp.

References DEBUG_FUNC, and importCharBuffer().

Referenced by SAXDBOBJDefinitionBuilder::startElement().

void DBOBJDefinitionField::setValue const char *    p_szValue
 

Sets field's value for all actions.

Parameters:
p_szValue (string) Field's value.

Definition at line 305 of file dbobjdefinition.cpp.

References DEBUG_FUNC, and importCharBuffer().

Referenced by SAXDBOBJDefinitionBuilder::startElement().


The documentation for this class was generated from the following files:
Generated on Sat Oct 4 13:23:36 2003 for XDFLengine by doxygen1.3-rc2