PHP Class Pimcore\Model\Object\ClassDefinition\Data\Numeric

Inheritance: extends Pimcore\Model\Object\ClassDefinition\Data
Show file Open project: pimcore/pimcore

Public Properties

Property Type Description
$columnType string Type for the column
$decimalPrecision integer
$defaultValue float
$fieldtype string Static type of this element
$integer boolean
$maxValue float
$minValue float
$phpdocType string Type for the generated phpdoc
$queryColumnType string Type for the column to query
$unsigned boolean
$width float

Public Methods

Method Description
checkValidity ( mixed $data, boolean $omitMandatoryCheck = false ) Checks if data is valid for current data field
getColumnType ( ) : string
getDataForEditmode ( float $data, null | AbstractObject $object = null, mixed $params = [] ) : float
getDataForQueryResource ( float $data, null | AbstractObject $object = null, mixed $params = [] ) : float
getDataForResource ( float $data, null | AbstractObject $object = null, mixed $params = [] ) : float
getDataFromEditmode ( float $data, null | AbstractObject $object = null, mixed $params = [] ) : float
getDataFromResource ( float $data, null | AbstractObject $object = null, mixed $params = [] ) : float
getDecimalPrecision ( ) : integer
getDefaultValue ( ) : integer
getForCsvExport ( AbstractObject $object, array $params = [] ) : string converts object data to a simple string value or CSV Export
getFromCsvImport ( string $importValue, null | AbstractObject $object = null, mixed $params = [] ) : float fills object field data values from CSV Import String
getInteger ( ) : boolean
getMaxValue ( ) : float
getMinValue ( ) : float
getQueryColumnType ( ) : string
getUnsigned ( ) : boolean
getVersionPreview ( float $data, null | Object\AbstractObject $object = null, mixed $params = [] ) : float
getWidth ( ) : integer
isDiffChangeAllowed ( string $object, mixed $params = [] ) : boolean True if change is allowed in edit mode.
isEmpty ( $data ) : boolean
setDecimalPrecision ( integer $decimalPrecision )
setDefaultValue ( integer $defaultValue ) : void
setInteger ( boolean $integer )
setMaxValue ( float $maxValue )
setMinValue ( float $minValue )
setUnsigned ( boolean $unsigned )
setWidth ( integer $width )

Protected Methods

Method Description
toNumeric ( $value ) : float | integer

Method Details

checkValidity() public method

Checks if data is valid for current data field
public checkValidity ( mixed $data, boolean $omitMandatoryCheck = false )
$data mixed
$omitMandatoryCheck boolean

getColumnType() public method

public getColumnType ( ) : string
return string

getDataForEditmode() public method

See also: Object\ClassDefinition\Data::getDataForEditmode
public getDataForEditmode ( float $data, null | AbstractObject $object = null, mixed $params = [] ) : float
$data float
$object null | Pimcore\Model\Object\AbstractObject
$params mixed
return float

getDataForQueryResource() public method

See also: Object\ClassDefinition\Data::getDataForQueryResource
public getDataForQueryResource ( float $data, null | AbstractObject $object = null, mixed $params = [] ) : float
$data float
$object null | Pimcore\Model\Object\AbstractObject
$params mixed
return float

getDataForResource() public method

See also: Object\ClassDefinition\Data::getDataForResource
public getDataForResource ( float $data, null | AbstractObject $object = null, mixed $params = [] ) : float
$data float
$object null | Pimcore\Model\Object\AbstractObject
$params mixed
return float

getDataFromEditmode() public method

See also: Model\Object\ClassDefinition\Data::getDataFromEditmode
public getDataFromEditmode ( float $data, null | AbstractObject $object = null, mixed $params = [] ) : float
$data float
$object null | Pimcore\Model\Object\AbstractObject
$params mixed
return float

getDataFromResource() public method

See also: Object\ClassDefinition\Data::getDataFromResource
public getDataFromResource ( float $data, null | AbstractObject $object = null, mixed $params = [] ) : float
$data float
$object null | Pimcore\Model\Object\AbstractObject
$params mixed
return float

getDecimalPrecision() public method

public getDecimalPrecision ( ) : integer
return integer

getDefaultValue() public method

public getDefaultValue ( ) : integer
return integer

getForCsvExport() public method

converts object data to a simple string value or CSV Export
public getForCsvExport ( AbstractObject $object, array $params = [] ) : string
$object Pimcore\Model\Object\AbstractObject
$params array
return string

getFromCsvImport() public method

fills object field data values from CSV Import String
public getFromCsvImport ( string $importValue, null | AbstractObject $object = null, mixed $params = [] ) : float
$importValue string
$object null | Pimcore\Model\Object\AbstractObject
$params mixed
return float

getInteger() public method

public getInteger ( ) : boolean
return boolean

getMaxValue() public method

public getMaxValue ( ) : float
return float

getMinValue() public method

public getMinValue ( ) : float
return float

getQueryColumnType() public method

public getQueryColumnType ( ) : string
return string

getUnsigned() public method

public getUnsigned ( ) : boolean
return boolean

getVersionPreview() public method

See also: Object\ClassDefinition\Data::getVersionPreview
public getVersionPreview ( float $data, null | Object\AbstractObject $object = null, mixed $params = [] ) : float
$data float
$object null | Object\AbstractObject
$params mixed
return float

getWidth() public method

public getWidth ( ) : integer
return integer

isDiffChangeAllowed() public method

True if change is allowed in edit mode.
public isDiffChangeAllowed ( string $object, mixed $params = [] ) : boolean
$object string
$params mixed
return boolean

isEmpty() public method

public isEmpty ( $data ) : boolean
$data
return boolean

setDecimalPrecision() public method

public setDecimalPrecision ( integer $decimalPrecision )
$decimalPrecision integer

setDefaultValue() public method

public setDefaultValue ( integer $defaultValue ) : void
$defaultValue integer
return void

setInteger() public method

public setInteger ( boolean $integer )
$integer boolean

setMaxValue() public method

public setMaxValue ( float $maxValue )
$maxValue float

setMinValue() public method

public setMinValue ( float $minValue )
$minValue float

setUnsigned() public method

public setUnsigned ( boolean $unsigned )
$unsigned boolean

setWidth() public method

public setWidth ( integer $width )
$width integer

toNumeric() protected method

protected toNumeric ( $value ) : float | integer
$value
return float | integer

Property Details

$columnType public property

Type for the column
public string $columnType
return string

$decimalPrecision public property

public int $decimalPrecision
return integer

$defaultValue public property

public float $defaultValue
return float

$fieldtype public property

Static type of this element
public string $fieldtype
return string

$integer public property

public bool $integer
return boolean

$maxValue public property

public float $maxValue
return float

$minValue public property

public float $minValue
return float

$phpdocType public property

Type for the generated phpdoc
public string $phpdocType
return string

$queryColumnType public property

Type for the column to query
public string $queryColumnType
return string

$unsigned public property

public bool $unsigned
return boolean

$width public property

public float $width
return float