RequestOutputPlotInstantSerieNodeClass.php 1.93 KB
<?php

define ("REQUESTOUTPUTPLOTINSTANTSERIE_NAME", "iserie");

define ("REQUESTOUTPUTPLOTINSTANTSERIE_YAXIS", "yAxis");
define ("REQUESTOUTPUTPLOTINSTANTSERIE_XAXIS", "xAxis");
define ("REQUESTOUTPUTPLOTINSTANTSERIE_TABLEONXAXIS", "tableOnXAxis");
define ("REQUESTOUTPUTPLOTINSTANTSERIE_LINE", "line");
define ("REQUESTOUTPUTPLOTINSTANTSERIE_SYMBOL", "symbol");

/**
 * @class RequestOutputPlotInstantSerieNodeClass
 * @brief Definition of a iserie for an instant plot of a plot request
 * @details
*/
class RequestOutputPlotInstantSerieNodeClass extends NodeClass
{
	public function __construct()
	{
		parent::__construct(REQUESTOUTPUTPLOTINSTANTSERIE_NAME);
	}

	public function setYAxisId($axisId)
	{
		$this->setAttribute(REQUESTOUTPUTPLOTINSTANTSERIE_YAXIS, $axisId);
	}

	public function getYAxisId()
	{
		return $this->getAttribute(REQUESTOUTPUTPLOTINSTANTSERIE_YAXIS);
	}

	public function setXAxisId($axisId)
	{
		$this->setAttribute(REQUESTOUTPUTPLOTINSTANTSERIE_XAXIS, $axisId);
	}

	public function getXAxisId()
	{
		return $this->getAttribute(REQUESTOUTPUTPLOTINSTANTSERIE_XAXIS);
	}

	public function setTableOnXAxis($tableOnX)
	{
		$this->setAttribute(REQUESTOUTPUTPLOTINSTANTSERIE_TABLEONXAXIS, $tableOnX);
	}

	public function getTableOnXAxis()
	{
		return $this->getAttribute(REQUESTOUTPUTPLOTINSTANTSERIE_TABLEONXAXIS);
	}
	
	public function getLine()
	{
		$node = $this->getFirstChildByName(REQUESTOUTPUTPLOTINSTANTSERIE_LINE);
	
		if (!isset($node))
		{
			$node = new RequestOutputPlotLineNodeClass(REQUESTOUTPUTPLOTINSTANTSERIE_LINE);
			$this->addChild($node);
		}
	
		return $node;
	}
	
	public function getSymbol()
	{
		$node = $this->getFirstChildByName(REQUESTOUTPUTPLOTINSTANTSERIE_SYMBOL);
		
		if (!isset($node))
		{
			$node = new RequestOutputPlotSymbolNodeClass(REQUESTOUTPUTPLOTINSTANTSERIE_SYMBOL);
			$this->addChild($node);
		}
		
		return $node;
	}
}

?>