ParamGetConstantParamNodeClass.php
1.99 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
<?php
define ("PARAMGETCONSTANTPARAM_NAME", "param");
define ("PARAMGETCONSTANTPARAM_SAMPLING", "sampling");
define ("PARAMGETCONSTANTPARAM_TYPE", "type");
define ("PARAMGETCONSTANTPARAM_VALUE", "value");
define ("PARAMGETCONSTANTPARAM_DIM1", "dim1");
define ("PARAMGETCONSTANTPARAM_DIM2", "dim2");
/**
* @class ParamGetConstantParamNodeClass
* @brief Definition of a constant parameter
* @details
*/
class ParamGetConstantParamNodeClass extends NodeClass
{
public function __construct()
{
parent::__construct(PARAMGETCONSTANTPARAM_NAME);
}
public function getSampling()
{
return $this->getAttribute(PARAMGETCONSTANTPARAM_SAMPLING);
}
public function setSampling($sampling)
{
$this->setAttribute(PARAMGETCONSTANTPARAM_SAMPLING, $sampling);
}
public function getType()
{
return $this->getAttribute(PARAMGETCONSTANTPARAM_TYPE);
}
public function setType($type)
{
$this->setAttribute(PARAMGETCONSTANTPARAM_TYPE, strtolower($type));
}
public function getConstValue()
{
return $this->getAttribute(PARAMGETCONSTANTPARAM_VALUE);
}
public function setConstValue($value)
{
$this->setAttribute(PARAMGETCONSTANTPARAM_VALUE, $value);
}
public function getDim1()
{
return $this->getAttribute(PARAMGETCONSTANTPARAM_DIM1);
}
public function setDim1($dim1)
{
$this->setAttribute(PARAMGETCONSTANTPARAM_DIM1, $dim1);
}
public function getDim2()
{
return $this->getAttribute(PARAMGETCONSTANTPARAM_DIM2);
}
public function setDim2($dim2)
{
$this->setAttribute(PARAMGETCONSTANTPARAM_DIM2, $dim2);
}
public function loadFromNode($xmlNode)
{
$this->setSampling($this->getXmlNodeAttribute($xmlNode, PARAMGETCONSTANTPARAM_SAMPLING));
$this->setType($this->getXmlNodeAttribute($xmlNode, PARAMGETCONSTANTPARAM_TYPE));
$this->setConstValue($this->getXmlNodeAttribute($xmlNode, PARAMGETCONSTANTPARAM_VALUE));
$this->setDim1($this->getXmlNodeAttribute($xmlNode, PARAMGETCONSTANTPARAM_DIM1));
$this->setDim2($this->getXmlNodeAttribute($xmlNode, PARAMGETCONSTANTPARAM_DIM2));
}
}
?>