phpDocumentor openbiz.bin.data
[ class tree: openbiz.bin.data ] [ index: openbiz.bin.data ] [ all elements ]

Class: BizField

Source Location: /data/BizField.php

Class BizField

Inherited Properties, Constants, and Methods
Property Summary
mixed   $m_Alias  
mixed   $m_BizObjName  
mixed   $m_Column  
mixed   $m_DefaultValue  
mixed   $m_Format  
mixed   $m_Index  
mixed   $m_Join  
mixed   $m_Length  
mixed   $m_OldValue  
mixed   $m_OnAudit  
mixed   $m_Required  
mixed   $m_SqlExpression  
mixed   $m_Type  
mixed   $m_Validator  
mixed   $m_Value  
mixed   $m_ValueExpression  
mixed   $m_ValueOnCreate  
mixed   $m_ValueOnUpdate  

[ Top ]
Method Summary
void   __construct()   Initialize BizField with xml array
void   AdjustBizObjName()   Change the BizDataObj name. This function is used in case of the current BizDataObj inheriting from another BizDataObj, BizField's BizDataObj name should be changed to current BizDataObj name, not the parent object name.
boolean   CheckRequired()   Check if the field is a required field
void   CheckValueType()  
BizDataObj   GetDataObj()   Get the data object instance
string   GetDefaultValue()   Get default value
string   GetInsertLobValue()   Get insert lob value when execute insert SQL. For a lob column, insert SQL first inserts an empty entry in the lob column. Then use update to actually add the lob data.
string   GetProperty()   Get property value
string   GetSqlValue()   Get string used in sql - with single quote, or without single quote in case of number
mixed   GetValue()   Get the value of the field.
string   GetValueOnCreate()   Get the value when a new record is created
string   GetValueOnUpdate()   Get the value when a record is updated
boolean   IsLobField()   Check if the field is a LOB type column
void   SaveOldValue()   Save the old value to an internal variable
void   SetValue()   Set the value of the field.
void   UseDefaultFormat()   Use default format if no format is given
boolean   Validate()   Check if the field has valid value

[ Top ]
Properties
mixed   $m_Alias = null [line 30]
API Tags:
Access:  public


[ Top ]
mixed   $m_BizObjName [line 27]
API Tags:
Access:  public


[ Top ]
mixed   $m_Column = null [line 29]
API Tags:
Access:  public


[ Top ]
mixed   $m_DefaultValue = null [line 39]
API Tags:
Access:  public


[ Top ]
mixed   $m_Format = null [line 33]
API Tags:
Access:  public


[ Top ]
mixed   $m_Index [line 31]
API Tags:
Access:  public


[ Top ]
mixed   $m_Join = null [line 28]
API Tags:
Access:  public


[ Top ]
mixed   $m_Length = null [line 34]
API Tags:
Access:  public


[ Top ]
mixed   $m_OldValue = null [line 45]
API Tags:
Access:  public


[ Top ]
mixed   $m_OnAudit = false [line 42]
API Tags:
Access:  public


[ Top ]
mixed   $m_Required = null [line 36]
API Tags:
Access:  public


[ Top ]
mixed   $m_SqlExpression = null [line 38]
API Tags:
Access:  public


[ Top ]
mixed   $m_Type = null [line 32]
API Tags:
Access:  public


[ Top ]
mixed   $m_Validator = null [line 37]
API Tags:
Access:  public


[ Top ]
mixed   $m_Value = null [line 44]
API Tags:
Access:  public


[ Top ]
mixed   $m_ValueExpression = null [line 35]
API Tags:
Access:  public


[ Top ]
mixed   $m_ValueOnCreate = null [line 40]
API Tags:
Access:  public


[ Top ]
mixed   $m_ValueOnUpdate = null [line 41]
API Tags:
Access:  public


[ Top ]
Methods
Constructor __construct  [line 54]

  void __construct( array &$xmlArr, BizDataObj $bizObj  )

Initialize BizField with xml array

Parameters:
array   $xmlArr:  xml array
BizDataObj   $bizObj:  BizDataObj instance


Redefinition of:
MetaObject::__construct()

[ Top ]
AdjustBizObjName  [line 114]

  void AdjustBizObjName( string $bizObjName  )

Change the BizDataObj name. This function is used in case of the current BizDataObj inheriting from another BizDataObj, BizField's BizDataObj name should be changed to current BizDataObj name, not the parent object name.

Parameters:
string   $bizObjName:  the name of BizDataObj obejct

API Tags:
Access:  public


[ Top ]
CheckRequired  [line 275]

  boolean CheckRequired( )

Check if the field is a required field


API Tags:
Return:  true if the field is a required field
Access:  public


[ Top ]
CheckValueType  [line 289]

  void CheckValueType( [mixed $value = null]  )


API Tags:
Access:  public


[ Top ]
GetDataObj  [line 264]

  BizDataObj GetDataObj( )

Get the data object instance


API Tags:
Return:  BizDataObj instance
Access:  protected


[ Top ]
GetDefaultValue  [line 228]

  string GetDefaultValue( )

Get default value


API Tags:
Return:  the default value of the field
Access:  public


[ Top ]
GetInsertLobValue  [line 163]

  string GetInsertLobValue( string $dbType  )

Get insert lob value when execute insert SQL. For a lob column, insert SQL first inserts an empty entry in the lob column. Then use update to actually add the lob data.

Parameters:
string   $dbType:  database type

API Tags:
Return:  the insert string for the lob column
Access:  public


[ Top ]
GetProperty  [line 98]

  string GetProperty( string $propertyName  )

Get property value

Parameters:
string   $propertyName:  property name

API Tags:
Return:  property value
Access:  public


Redefinition of:
MetaObject::GetProperty()
Get property

[ Top ]
GetSqlValue  [line 126]

  string GetSqlValue( [mixed $input = null]  )

Get string used in sql - with single quote, or without single quote in case of number

Parameters:
mixed   $input:  the value to add quote. If null, use the current field value

API Tags:
Return:  string used in sql
Access:  public


[ Top ]
GetValue  [line 179]

  mixed GetValue( [boolean $formatted = true]  )

Get the value of the field.

Parameters:
boolean   $formatted:  true if want to get the formatted value

API Tags:
Return:  string or number depending on the field type
Access:  public


[ Top ]
GetValueOnCreate  [line 240]

  string GetValueOnCreate( )

Get the value when a new record is created


API Tags:
Return:  the value of the field
Access:  public


[ Top ]
GetValueOnUpdate  [line 252]

  string GetValueOnUpdate( )

Get the value when a record is updated


API Tags:
Return:  the value of the field
Access:  public


[ Top ]
IsLobField  [line 151]

  boolean IsLobField( )

Check if the field is a LOB type column


API Tags:
Return:  true if the field points a LOB type column
Access:  public


[ Top ]
SaveOldValue  [line 215]

  void SaveOldValue( [mixed $oldVal = null]  )

Save the old value to an internal variable


API Tags:
Access:  public


[ Top ]
SetValue  [line 205]

  void SetValue( mixed $val  )

Set the value of the field.

Parameters:
mixed   $val: 

API Tags:
Access:  public


[ Top ]
UseDefaultFormat  [line 85]

  void UseDefaultFormat( )

Use default format if no format is given


API Tags:
Access:  protected


[ Top ]
Validate  [line 336]

  boolean Validate( )

Check if the field has valid value


API Tags:
Return:  true if validation is good
Access:  public


[ Top ]

Documentation generated on Tue, 22 Dec 2009 03:02:36 -0800 by phpDocumentor 1.3.0RC3