/** * Property write access * * @throws ezcBasePropertyNotFoundException * If Option could not be found * @throws ezcBaseValueException * If value is out of range * @param string $propertyName Option name * @param mixed $propertyValue Option value; * @return void * @ignore */ public function __set($propertyName, $propertyValue) { switch ($propertyName) { case 'axis': if ($propertyValue instanceof ezcGraphChartElementAxis) { $this->addElement('axis', $propertyValue); $this->elements['axis']->position = ezcGraph::BOTTOM; $this->elements['axis']->axisLabelRenderer = new ezcGraphAxisRadarLabelRenderer(); $this->renderElement['axis'] = false; } else { throw new ezcBaseValueException($propertyName, $propertyValue, 'ezcGraphChartElementAxis'); } break; case 'rotationAxis': if ($propertyValue instanceof ezcGraphChartElementAxis) { $this->addElement('rotationAxis', $propertyValue); $this->renderElement['rotationAxis'] = false; } else { throw new ezcBaseValueException($propertyName, $propertyValue, 'ezcGraphChartElementAxis'); } break; case 'renderer': if ($propertyValue instanceof ezcGraphRadarRenderer) { parent::__set($propertyName, $propertyValue); } else { throw new ezcBaseValueException($propertyName, $propertyValue, 'ezcGraphRadarRenderer'); } break; default: parent::__set($propertyName, $propertyValue); } }
/** * Options write access * * @throws ezcBasePropertyNotFoundException * If Option could not be found * @throws ezcBaseValueException * If value is out of range * @param mixed $propertyName Option name * @param mixed $propertyValue Option value; * @return mixed * @ignore */ public function __set($propertyName, $propertyValue) { switch ($propertyName) { case 'xAxis': if ($propertyValue instanceof ezcGraphChartElementAxis) { $this->addElement('xAxis', $propertyValue); $this->elements['xAxis']->position = ezcGraph::LEFT; } else { throw new ezcBaseValueException($propertyName, $propertyValue, 'ezcGraphChartElementAxis'); } break; case 'yAxis': if ($propertyValue instanceof ezcGraphChartElementAxis) { $this->addElement('yAxis', $propertyValue); $this->elements['yAxis']->position = ezcGraph::BOTTOM; } else { throw new ezcBaseValueException($propertyName, $propertyValue, 'ezcGraphChartElementAxis'); } break; default: parent::__set($propertyName, $propertyValue); } }
/** * Property write access * * @throws ezcBasePropertyNotFoundException * If Option could not be found * @throws ezcBaseValueException * If value is out of range * @param string $propertyName Option name * @param mixed $propertyValue Option value; * @return void * @ignore */ public function __set($propertyName, $propertyValue) { switch ($propertyName) { case 'axis': if ($propertyValue instanceof ezcGraphChartElementAxis) { $this->addElement('axis', $propertyValue); $this->elements['axis']->axisLabelRenderer = new ezcGraphAxisCenteredLabelRenderer(); $this->elements['axis']->axisLabelRenderer->showZeroValue = true; $this->elements['axis']->position = ezcGraph::LEFT; $this->elements['axis']->axisSpace = 0.05; } else { throw new ezcBaseValueException($propertyName, $propertyValue, 'ezcGraphChartElementAxis'); } break; case 'renderer': if ($propertyValue instanceof ezcGraphOdometerRenderer) { parent::__set($propertyName, $propertyValue); } else { throw new ezcBaseValueException($propertyName, $propertyValue, 'ezcGraphOdometerRenderer'); } break; default: parent::__set($propertyName, $propertyValue); } }