setValue((int)$val); } /** * Returns a raw mime-dir representation of the value. * * @return string */ function getRawMimeDirValue() { return $this->value; } /** * Returns the type of value. * * This corresponds to the VALUE= parameter. Every property also has a * 'default' valueType. * * @return string */ function getValueType() { return 'INTEGER'; } /** * Returns the value, in the format it should be encoded for json. * * This method must always return an array. * * @return array */ function getJsonValue() { return [(int)$this->getValue()]; } /** * Hydrate data from a XML subtree, as it would appear in a xCard or xCal * object. * * @param array $value * * @return void */ function setXmlValue(array $value) { $value = array_map('intval', $value); parent::setXmlValue($value); } }