A property is a basic class that has a value and a default value.
It provides functionality to handle the value :
- Set current value to a new value
- Reset current value (make empty)
- Set current value to default
- Get value (read out)
- Check if value is empty
Methods
Constructor, defines database column class
__construct(string $columnName, string $columnValue, string $columnType, int $columnLength) : void
Defines current value and default value.
Parameters
$columnName
string
Column name
$columnValue
string
Column value
$columnType
string
Database column type (optional, default : null)
$columnLength
int
Database column length (optional, default : null)
Disables trimming whitespace of object name
disableTrimName() : void
Inherited
inherited_from |
\Formaid_Object::disableTrimName() |
inherited_from |
\Formaid_Property::disableTrimName() |
Display object
display() : void
Inherited
The name of the object is printed to stdout.
inherited_from |
\Formaid_Object::display() |
inherited_from |
\Formaid_Property::display() |
Enables trimming whitespace of object name
enableTrimName() : void
Inherited
inherited_from |
\Formaid_Object::enableTrimName() |
inherited_from |
\Formaid_Property::enableTrimName() |
Get display mode
getDisplayMode() : string
Returns
string
display mode
Get display seperator
getDisplaySeparator() : string
Inherited
inherited_from |
\Formaid_Property::getDisplaySeparator() |
Returns
string
String separating columns
Get formatted Database column
getDisplayString(bool $withValue, bool $discardEmptyValue) : string
Parameters
$withValue
bool
append value to column
(optional, default : true)
$discardEmptyValue
bool
discard columns with empty values
(optional, default : false)
Returns
string
Returns name of the object
getName() : string
Inherited
inherited_from |
\Formaid_Object::getName() |
inherited_from |
\Formaid_Property::getName() |
Returns
string
object name
Returns current value
getValue() : string
Inherited
inherited_from |
\Formaid_Property::getValue() |
Returns
string
current value
Checks if current value is empty
isEmpty() : bool
Inherited
inherited_from |
\Formaid_Property::isEmpty() |
Returns
bool
true if empty
Checks if object name is empty
isNameEmpty() : bool
Inherited
inherited_from |
\Formaid_Object::isNameEmpty() |
inherited_from |
\Formaid_Property::isNameEmpty() |
Returns
bool
true if empty
Resets current value
resetValue() : void
Inherited
inherited_from |
\Formaid_Property::resetValue() |
Sets current value to default
setDefault(string $value) : void
Inherited
When the parameter is set,
the default value is changed to the new default value.
Then the current value is set to the (new) default value.
inherited_from |
\Formaid_Property::setDefault() |
Parameters
$value
string
New default value
Set display mode
setDisplayMode(string $mode, string $separator) : void
$seperator is ignored, because it doesn't apply to this kind of object,
it is present to match the interface.
Parameters
$mode
string
display mode : list, (binary) logic
$separator
string
string separating columns
Sets new name for the object
setName(string $new_name) : void
Inherited
inherited_from |
\Formaid_Object::setName() |
inherited_from |
\Formaid_Property::setName() |
Parameters
Sets current value to new value
setValue(string $new_value) : void
Inherited
inherited_from |
\Formaid_Property::setValue() |
Parameters
$new_value
string
New value
Show object
show() : void
Inherited
The name of the object is printed to stdout.
inherited_from |
\Formaid_Object::show() |
inherited_from |
\Formaid_Property::show() |
Returns name formatted for displaying
getDisplayName() : string
Returns
string
formatted object name
Returns value formatted for displaying
getDisplayValue() : string
Returns
string
formatted object value
Properties
$current_value : string
Inherited
access |
protected |
inherited_from |
\Formaid_Property::$$current_value |
$default_value : string
Inherited
access |
protected |
inherited_from |
\Formaid_Property::$$default_value |
$displaySeparator : string
Inherited
access |
protected |
inherited_from |
\Formaid_Property::$$displaySeparator |
$encoding : string
Inherited
access |
protected |
inherited_from |
\Formaid_Object::$$encoding |
inherited_from |
\Formaid_Property::$$encoding |
$name : string
Inherited
access |
protected |
inherited_from |
\Formaid_Object::$$name |
inherited_from |
\Formaid_Property::$$name |
$_dbConn
access |
private |
type |
object |
$_trimName : bool
Inherited
access |
private |
inherited_from |
\Formaid_Object::$$_trimName |
inherited_from |
\Formaid_Property::$$_trimName |