本文整理汇总了PHP中Axis::_setParent方法的典型用法代码示例。如果您正苦于以下问题:PHP Axis::_setParent方法的具体用法?PHP Axis::_setParent怎么用?PHP Axis::_setParent使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Axis
的用法示例。
在下文中一共展示了Axis::_setParent方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1:
/**
* Sets the parent. The parent chain should ultimately be a GraPHP object
*
* @see Image_Graph_Common
* @param Image_Graph_Common $parent The parent
* @access private
*/
function _setParent(&$parent)
{
parent::_setParent($parent);
if ($this->_axisX !== null) {
$this->_axisX->_setParent($this);
}
if ($this->_axisY !== null) {
$this->_axisY->_setParent($this);
}
if ($this->_axisYSecondary !== null) {
$this->_axisYSecondary->_setParent($this);
}
}
示例2: elseif
/**
* Image_Graph_Plotarea [Constructor]
* @param Image_Graph_Axis $axisX The X axis (if false or omitted a std. axis is created)
* @param Image_Graph_Axis $axisY The Y axis (if false or omitted a std. axis is created)
*/
function &Image_Graph_Plotarea($axisX = false, $axisY = false)
{
parent::__construct();
$this->_padding = 10;
if (($axisX == null) and ($axisX !== false)) {
$this->_axisX = null;
}
elseif ($axisX !== false) {
$this->_axisX = & $axisX;
} else {
$this->_axisX = & new Image_Graph_Axis(IMAGE_GRAPH_AXIS_X);
}
if (is_object($this->_axisX)) {
$this->_axisX->_setParent($this);
}
if (($axisY == null) and ($axisY !== false)) {
$this->_axisY = null;
}
elseif ($axisY !== false) {
$this->_axisY = & $axisY;
} else {
$this->_axisY = & new Image_Graph_Axis(IMAGE_GRAPH_AXIS_Y);
}
if (is_object($this->_axisY)) {
$this->_axisY->_setParent($this);
$this->_axisY->_setMinimum(0);
}
}