Column
extends Column
in package
Tags
Table of Contents
- $default : mixed
- $isNumber : mixed
- $isText : mixed
- $limit : mixed
- $name : mixed
- $null : mixed
- $precision : mixed
- $scale : mixed
- $sqlType : mixed
- $type : mixed
- $unsigned : mixed
- __construct() : mixed
- Constructor.
- binaryToString() : string
- Used to convert from BLOBs to Strings
- extractDefault() : mixed
- getDefault() : string
- getLimit() : int
- getName() : string
- getSqlType() : string
- getType() : string
- isNull() : bool
- isNumber() : bool
- isText() : bool
- isUnsigned() : bool
- precision() : int
- scale() : int
- stringToDate() : Horde_Date
- stringToDummyTime() : Horde_Date|null
- stringToTime() : Horde_Date
- typeCast() : mixed
- Casts value (which is a String) to an appropriate instance.
- valueToBoolean() : bool
- valueToDecimal() : float
- extractLimit() : int
- extractPrecision() : int
- extractScale() : int
- extractUnsigned() : int
- setSimplifiedType() : mixed
- unquote() : string
- Unquote a string value
Properties
$default
protected
mixed
$default
$isNumber
protected
mixed
$isNumber
$isText
protected
mixed
$isText
$limit
protected
mixed
$limit
$name
protected
mixed
$name
$null
protected
mixed
$null
$precision
protected
mixed
$precision
$scale
protected
mixed
$scale
$sqlType
protected
mixed
$sqlType
$type
protected
mixed
$type
$unsigned
protected
mixed
$unsigned
Methods
__construct()
Constructor.
public
__construct(string $name[, string|null $default = null ][, string|null $sqlType = null ][, bool $null = true ]) : mixed
Parameters
- $name : string
-
The column's name, such as "supplier_id" in "supplier_id int(11)".
- $default : string|null = null
-
The type-casted default value, such as "new" in "sales_stage varchar(20) default 'new'".
- $sqlType : string|null = null
-
Used to extract the column's type, length and signed status, if necessary. For example "varchar" and "60" in "company_name varchar(60)" or "unsigned => true" in "int(10) UNSIGNED".
- $null : bool = true
-
Whether this column allows NULL values. optional
Return values
mixed —binaryToString()
Used to convert from BLOBs to Strings
public
binaryToString(mixed $value) : string
Parameters
- $value : mixed
Return values
string —extractDefault()
public
extractDefault(mixed $default) : mixed
Parameters
- $default : mixed
Return values
mixed —getDefault()
public
getDefault() : string
Return values
string —getLimit()
public
getLimit() : int
Return values
int —getName()
public
getName() : string
Return values
string —getSqlType()
public
getSqlType() : string
Return values
string —getType()
public
getType() : string
Return values
string —isNull()
public
isNull() : bool
Return values
bool —isNumber()
public
isNumber() : bool
Return values
bool —isText()
public
isText() : bool
Return values
bool —isUnsigned()
public
isUnsigned() : bool
Return values
bool —precision()
public
precision() : int
Return values
int —scale()
public
scale() : int
Return values
int —stringToDate()
public
stringToDate(string $string) : Horde_Date
Parameters
- $string : string
Return values
Horde_Date —stringToDummyTime()
public
stringToDummyTime(string $string) : Horde_Date|null
Parameters
- $string : string
Return values
Horde_Date|null —stringToTime()
public
stringToTime(string $string) : Horde_Date
Parameters
- $string : string
Return values
Horde_Date —typeCast()
Casts value (which is a String) to an appropriate instance.
public
typeCast(mixed $value) : mixed
Parameters
- $value : mixed
Return values
mixed —valueToBoolean()
public
valueToBoolean(mixed $value) : bool
Parameters
- $value : mixed
Return values
bool —valueToDecimal()
public
valueToDecimal(mixed $value) : float
Parameters
- $value : mixed
Return values
float —extractLimit()
protected
extractLimit(string $sqlType) : int
Parameters
- $sqlType : string
Return values
int —extractPrecision()
protected
extractPrecision(string $sqlType) : int
Parameters
- $sqlType : string
Return values
int —extractScale()
protected
extractScale(string $sqlType) : int
Parameters
- $sqlType : string
Return values
int —extractUnsigned()
protected
extractUnsigned(string $sqlType) : int
Parameters
- $sqlType : string
Return values
int —setSimplifiedType()
protected
setSimplifiedType() : mixed
Return values
mixed —unquote()
Unquote a string value
protected
unquote(mixed $string) : string
Parameters
- $string : mixed