1: <?php
2:
3: /**
4: * Copyright 2015 AutEne.com.
5: *
6: * This work is licensed under the
7: * Creative Commons Attribution-NonCommercial-NoDerivs 3.0 Unported License.
8: * To view a copy of this license, visit
9: *
10: * http://creativecommons.org/licenses/by-nc-nd/3.0/
11: *
12: * or send a letter to Creative Commons, 444 Castro Street, Suite 900,
13: * Mountain View, California, 94041, USA.
14: * Unless required by applicable law or agreed to in writing, software
15: * distributed under the License is distributed on an "AS IS" BASIS,
16: * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17: * See the License for the specific language governing permissions and
18: * limitations under the License.
19: */
20:
21: /**
22: * Description of Radiacion
23: *
24: * La clase Radiacion.php gestiona las propiedades de Radiación Horizontal Mensual
25: * en las diferentes Provincias. Define una propiedad por cada mes del año "$mesxxx"
26: * y al ser una clase extendida de la clase Provincia, también define la propiedad
27: * $provincia. Instanciamos un objeto Radiacion por cada fila $row de la tabla
28: * aut_rad_hor. El constructor de la clase toma como parametros de entrada la fila
29: * $row para instanciar cada objeto, la propiedad $provincia con una llamada al
30: * constructor de la clase Provincia:
31: * Provincia::__construct($row);
32: * y la propiedad "$mesxxx" asignandola directamente:
33: * $this->mesxxx = $row['MesXXX'];
34: *
35: * @author antonio horrillo horrillo
36: */
37: class Radiacion extends Provincia {
38:
39: ////////////////////////////////////////////////////////////////////////////////
40: // Propiedades de Radiacion
41: ////////////////////////////////////////////////////////////////////////////////
42:
43: protected $enero;
44: protected $febrero;
45: protected $marzo;
46: protected $abril;
47: protected $mayo;
48: protected $junio;
49: protected $julio;
50: protected $agosto;
51: protected $septiembre;
52: protected $octubre;
53: protected $noviembre;
54: protected $diciembre;
55:
56: ////////////////////////////////////////////////////////////////////////////////
57: // Método Get
58: ////////////////////////////////////////////////////////////////////////////////
59:
60: public function getEnero() {
61: return $this->enero;
62: }
63:
64: public function getFebrero() {
65: return $this->febrero;
66: }
67:
68: public function getMarzo() {
69: return $this->marzo;
70: }
71:
72: public function getAbril() {
73: return $this->abril;
74: }
75:
76: public function getMayo() {
77: return $this->mayo;
78: }
79:
80: public function getJunio() {
81: return $this->junio;
82: }
83:
84: public function getJulio() {
85: return $this->julio;
86: }
87:
88: public function getAgosto() {
89: return $this->agosto;
90: }
91:
92: public function getSeptiembre() {
93: return $this->septiembre;
94: }
95:
96: public function getOctubre() {
97: return $this->octubre;
98: }
99:
100: public function getNoviembre() {
101: return $this->noviembre;
102: }
103:
104: public function getDiciembre() {
105: return $this->diciembre;
106: }
107:
108: ////////////////////////////////////////////////////////////////////////////////
109: // Método Set
110: ////////////////////////////////////////////////////////////////////////////////
111:
112: public function setEnero($enero) {
113: $this->enero = $enero;
114: }
115:
116: public function setFebrero($febrero) {
117: $this->febrero = $febrero;
118: }
119:
120: public function setMarzo($marzo) {
121: $this->marzo = $marzo;
122: }
123:
124: public function setAbril($abril) {
125: $this->abril = $abril;
126: }
127:
128: public function setMayo($mayo) {
129: $this->mayo = $mayo;
130: }
131:
132: public function setJunio($junio) {
133: $this->junio = $junio;
134: }
135:
136: public function setJulio($julio) {
137: $this->julio = $julio;
138: }
139:
140: public function setAgosto($agosto) {
141: $this->agosto = $agosto;
142: }
143:
144: public function setSeptiembre($septiembre) {
145: $this->septiembre = $septiembre;
146: }
147:
148: public function setOctubre($octubre) {
149: $this->octubre = $octubre;
150: }
151:
152: public function setNoviembre($noviembre) {
153: $this->noviembre = $noviembre;
154: }
155:
156: public function setDiciembre($diciembre) {
157: $this->diciembre = $diciembre;
158: }
159:
160: ////////////////////////////////////////////////////////////////////////////////
161: // Constructor de Clase Radiacion
162: ////////////////////////////////////////////////////////////////////////////////
163:
164: public function __construct($row) {
165: Provincia::__construct($row);
166: $this->enero = $row['Enero'];
167: $this->febrero = $row['Febrero'];
168: $this->marzo = $row['Marzo'];
169: $this->abril = $row['Abril'];
170: $this->mayo = $row['Mayo'];
171: $this->junio = $row['Junio'];
172: $this->julio = $row['Julio'];
173: $this->agosto = $row['Agosto'];
174: $this->septiembre = $row['Septiembre'];
175: $this->octubre = $row['Octubre'];
176: $this->noviembre = $row['Noviembre'];
177: $this->diciembre = $row['Diciembre'];
178: }
179: }