Home  Support  API

Primitive Class Reference
[Types]


Represents a fundamental type abstract box.

Definition at line 24 of file Primitive.class.php.

Inheritance diagram for Primitive:
Inheritance graph

List of all members.

Static Public Member Functions

static cast ($value)
 Casts scalar to the corresponding object wrapper.
static getOrmPropertyType (AssociationMultiplicity $multiplicity)
 Gets the auxiliary type wrapper that describes the type.

Public Member Functions

 __construct ($value)
 __toString ()
 Returns a string representation of an object.
 getValue ()
 Gets the scalar value of an object.
 setValue ($value)
 Sets the internal value.

Protected Member Functions

 isValidValue ($value)
 Checks whether the primitive value is suitable for wrapping with this class.

Constructor & Destructor Documentation

Primitive::__construct ( value  ) 
Exceptions:
TypeCastException 
Parameters:
scalar $value value to be wrapped

Definition at line 35 of file Primitive.class.php.

References setValue().


Member Function Documentation

Primitive::__toString (  ) 

Returns a string representation of an object.

Returns:
string

Implements IStringCastable.

Definition at line 62 of file Primitive.class.php.

static IObjectCastable::cast ( value  )  [static, inherited]

Casts scalar to the corresponding object wrapper.

Parameters:
scalar 
Returns:
IObjectCastable
Exceptions:
TypeCastException 

Implemented in Boolean, Date, Time, Timestamp, Decimal, Float, Integer, Numeric, Scalar, and String.

static IOrmPropertyAssignable::getOrmPropertyType ( AssociationMultiplicity multiplicity  )  [static, inherited]

Gets the auxiliary type wrapper that describes the type.

Returns:
OrmPropertyType

Implemented in Boolean, Date, Time, Timestamp, Float, Integer, and Scalar.

Primitive::getValue (  ) 

Gets the scalar value of an object.

Returns:
scalar

Implements IObjectCastable.

Reimplemented in Float, and Integer.

Definition at line 57 of file Primitive.class.php.

Primitive::isValidValue ( value  )  [protected]

Checks whether the primitive value is suitable for wrapping with this class.

Returns:
boolean

Reimplemented in Boolean, Decimal, Integer, and Numeric.

Definition at line 72 of file Primitive.class.php.

Referenced by setValue().

Primitive::setValue ( value  ) 

Sets the internal value.

Returns:
BuiltInType

Reimplemented in Boolean, and Numeric.

Definition at line 45 of file Primitive.class.php.

References isValidValue().

Referenced by __construct().


The documentation for this class was generated from the following file: