pdoMap
[ class tree: pdoMap ] [ index: pdoMap ] [ all elements ]

Class: pdoMap_Field

Source Location: /field.class.php

Class Overview


STRING OR VARIANT FIELD - SERIALIZED LIKE STRING


Methods


Child classes:

pdoMap_Date
PDO DATE FIELDS
pdoMap_String
PDO STRING/TEXTE FIELDS
pdoMap_Integer
PDO INTEGER/NUMERIC FIELDS
pdoMap_FK
PDO FOREIGN KEY FIELDS

Class Details

[line 18]
STRING OR VARIANT FIELD - SERIALIZED LIKE STRING

Represents a casted dbo field




[ Top ]


Class Methods


constructor __construct [line 28]

pdoMap_Field __construct( string $name, [string $value = NULL])

Field Constructor



Tags:

access:  public


Overridden in child classes as:

pdoMap_FK::__construct()

Parameters:

string   $name   Field Bind Name
string   $value   Default assigned value

[ Top ]

method get [line 81]

void get( )

Getting field value



Tags:

access:  public


[ Top ]

method getFunction [line 60]

string getFunction( )

Returns current function name



Tags:

return:  Used function
access:  public


[ Top ]

method map [line 94]

string map( )

Getting field value as SQL syntax



Tags:

return:  SQL value
access:  public


[ Top ]

method MD5 [line 67]

void MD5( string $value)

Easy convert value to MD5 encrypted string



Tags:

access:  public


Parameters:

string   $value   Indicate string value to encrypt

[ Top ]

method name [line 87]

void name( )

Getting binding field name



Tags:

access:  public


[ Top ]

method set [line 74]

void set( $value)

Setting field value



Tags:

access:  public


Overridden in child classes as:

pdoMap_FK::set()

Parameters:

   $value  

[ Top ]

method setFunction [line 52]

void setFunction( string $name, [boolean $arithmetic = false])

Assign a function value

Example :

  1.  $field new pdoMap_Field('UserPassword');
  2.  $field->setFunction('MD5');
  3.  $field->set('password');

Example use of arithmetic functions :

  1.  $field new pdoMap_Field('UserFullName');
  2.  $field->setFunction('CONCAT'true);
  3.  $field->set('UserName + User');




Tags:

access:  public


Parameters:

string   $name   Function name
boolean   $arithmetic   Indicate if value is an arithmetic expression or a user defined value

[ Top ]


Documentation generated on Thu, 10 Apr 2008 11:51:02 +0200 by phpDocumentor 1.4.1