forked from jact/openclinic
/
History.php
483 lines (441 loc) · 10.2 KB
/
History.php
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
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
<?php
/**
* History.php
*
* Contains the class History
*
* Licensed under the GNU GPL. For full terms see the file LICENSE.
*
* @package OpenClinic
* @copyright 2002-2013 jact
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL
* @version CVS: $Id: History.php,v 1.10 2013/01/16 19:04:07 jact Exp $
* @author jact <jachavar@gmail.com>
*/
require_once(dirname(__FILE__) . "/../lib/Check.php");
/*
* History represents personal and family antecedents of a patient.
*
* Methods:
* bool validateData(void)
* int getIdPatient(void)
* string getBirthGrowth(void)
* string getGrowthSexuality(void)
* string getFeed(void)
* string getHabits(void)
* string getPeristalticConditions(void)
* string getPsychological(void)
* string getChildrenComplaint(void)
* string getVenerealDisease(void)
* string getAccidentSurgicalOperation(void)
* string getMedicinalIntolerance(void)
* string getMentalIllness(void)
* string getParentsStatusHealth(void)
* string getBrothersStatusHealth(void)
* string getSpouseChildsStatusHealth(void)
* string getFamilyIllness(void)
* void setIdPatient(int $value)
* void setBirthGrowth(string $value)
* void setGrowthSexuality(string $value)
* void setFeed(string $value)
* void setHabits(string $value)
* void setPeristalticConditions(string $value)
* void setPsychological(string $value)
* void setChildrenComplaint(string $value)
* void setVenerealDisease(string $value)
* void setAccidentSurgicalOperation(string $value)
* void setMedicinalIntolerance(string $value)
* void setMentalIllness(string $value)
* void setParentsStatusHealth(string $value)
* void setBrothersStatusHealth(string $value)
* void setSpouseChildsStatusHealth(string $value)
* void setFamilyIllness(string $value)
* string __toString(void)
*
* @package OpenClinic
* @author jact <jachavar@gmail.com>
* @access public
*/
class History
{
private $_idPatient = 0;
private $_birthGrowth = "";
private $_growthSexuality = "";
private $_feed = "";
private $_habits = "";
private $_peristalticConditions = "";
private $_psychological = "";
private $_childrenComplaint = "";
private $_venerealDisease = "";
private $_accidentSurgicalOperation = "";
private $_medicinalIntolerance = "";
private $_mentalIllness = "";
private $_parentsStatusHealth = "";
private $_brothersStatusHealth = "";
private $_spouseChildsStatusHealth = "";
private $_familyIllness = "";
private $_trans; // to translate htmlspecialchars()
public function History()
{
$this->_trans = array_flip(get_html_translation_table(HTML_SPECIALCHARS));
}
/*
* bool validateData(void)
*
* @return boolean true if data is valid, otherwise false.
* @access public
*/
public function validateData()
{
$valid = true;
return $valid;
}
/**
* int getIdPatient(void)
*
* @return int
* @access public
*/
public function getIdPatient()
{
return intval($this->_idPatient);
}
/**
* string getBirthGrowth(void)
*
* @return string
* @access public
*/
public function getBirthGrowth()
{
return stripslashes(strtr($this->_birthGrowth, $this->_trans));
}
/**
* string getGrowthSexuality(void)
*
* @return string
* @access public
*/
public function getGrowthSexuality()
{
return stripslashes(strtr($this->_growthSexuality, $this->_trans));
}
/**
* string getFeed(void)
*
* @return string
* @access public
*/
public function getFeed()
{
return stripslashes(strtr($this->_feed, $this->_trans));
}
/**
* string getHabits(void)
*
* @return string
* @access public
*/
public function getHabits()
{
return stripslashes(strtr($this->_habits, $this->_trans));
}
/**
* string getPeristalticConditions(void)
*
* @return string
* @access public
*/
public function getPeristalticConditions()
{
return stripslashes(strtr($this->_peristalticConditions, $this->_trans));
}
/**
* string getPsychological(void)
*
* @return string
* @access public
*/
public function getPsychological()
{
return stripslashes(strtr($this->_psychological, $this->_trans));
}
/**
* string getChildrenComplaint(void)
*
* @return string
* @access public
*/
public function getChildrenComplaint()
{
return stripslashes(strtr($this->_childrenComplaint, $this->_trans));
}
/**
* string getVenerealDisease(void)
*
* @return string
* @access public
*/
public function getVenerealDisease()
{
return stripslashes(strtr($this->_venerealDisease, $this->_trans));
}
/**
* string getAccidentSurgicalOperation(void)
*
* @return string
* @access public
*/
public function getAccidentSurgicalOperation()
{
return stripslashes(strtr($this->_accidentSurgicalOperation, $this->_trans));
}
/**
* string getMedicinalIntolerance(void)
*
* @return string
* @access public
*/
public function getMedicinalIntolerance()
{
return stripslashes(strtr($this->_medicinalIntolerance, $this->_trans));
}
/**
* string getMentalIllness(void)
*
* @return string
* @access public
*/
public function getMentalIllness()
{
return stripslashes(strtr($this->_mentalIllness, $this->_trans));
}
/**
* string getParentsStatusHealth(void)
*
* @return string
* @access public
*/
public function getParentsStatusHealth()
{
return stripslashes(strtr($this->_parentsStatusHealth, $this->_trans));
}
/**
* string getBrothersStatusHealth(void)
*
* @return string
* @access public
*/
public function getBrothersStatusHealth()
{
return stripslashes(strtr($this->_brothersStatusHealth, $this->_trans));
}
/**
* string getSpouseChildsStatusHealth(void)
*
* @return string
* @access public
*/
public function getSpouseChildsStatusHealth()
{
return stripslashes(strtr($this->_spouseChildsStatusHealth, $this->_trans));
}
/**
* string getFamilyIllness(void)
*
* @return string
* @access public
*/
public function getFamilyIllness()
{
return stripslashes(strtr($this->_familyIllness, $this->_trans));
}
/**
* void setIdPatient(int $value)
*
* @param int $value new value to set
* @return void
* @access public
*/
public function setIdPatient($value)
{
$this->_idPatient = intval($value);
}
/**
* void setBirthGrowth(string $value)
*
* @param string $value new value to set
* @return void
* @access public
*/
public function setBirthGrowth($value)
{
$this->_birthGrowth = Check::safeText($value);
}
/**
* void setGrowthSexuality(string $value)
*
* @param string $value new value to set
* @return void
* @access public
*/
public function setGrowthSexuality($value)
{
$this->_growthSexuality = Check::safeText($value);
}
/**
* void setFeed(string $value)
*
* @param string $value new value to set
* @return void
* @access public
*/
public function setFeed($value)
{
$this->_feed = Check::safeText($value);
}
/**
* void setHabits(string $value)
*
* @param string $value new value to set
* @return void
* @access public
*/
public function setHabits($value)
{
$this->_habits = Check::safeText($value);
}
/**
* void setPeristalticConditions(string $value)
*
* @param string $value new value to set
* @return void
* @access public
*/
public function setPeristalticConditions($value)
{
$this->_peristalticConditions = Check::safeText($value);
}
/**
* void setPsychological(string $value)
*
* @param string $value new value to set
* @return void
* @access public
*/
public function setPsychological($value)
{
$this->_psychological = Check::safeText($value);
}
/**
* void setChildrenComplaint(string $value)
*
* @param string $value new value to set
* @return void
* @access public
*/
public function setChildrenComplaint($value)
{
$this->_childrenComplaint = Check::safeText($value);
}
/**
* void setVenerealDisease(string $value)
*
* @param string $value new value to set
* @return void
* @access public
*/
public function setVenerealDisease($value)
{
$this->_venerealDisease = Check::safeText($value);
}
/**
* void setAccidentSurgicalOperation(string $value)
*
* @param string $value new value to set
* @return void
* @access public
*/
public function setAccidentSurgicalOperation($value)
{
$this->_accidentSurgicalOperation = Check::safeText($value);
}
/**
* void setMedicinalIntolerance(string $value)
*
* @param string $value new value to set
* @return void
* @access public
*/
public function setMedicinalIntolerance($value)
{
$this->_medicinalIntolerance = Check::safeText($value);
}
/**
* void setMentalIllness(string $value)
*
* @param string $value new value to set
* @return void
* @access public
*/
public function setMentalIllness($value)
{
$this->_mentalIllness = Check::safeText($value);
}
/**
* void setParentsStatusHealth(string $value)
*
* @param string $value new value to set
* @return void
* @access public
*/
public function setParentsStatusHealth($value)
{
$this->_parentsStatusHealth = Check::safeText($value);
}
/**
* void setBrothersStatusHealth(string $value)
*
* @param string $value new value to set
* @return void
* @access public
*/
public function setBrothersStatusHealth($value)
{
$this->_brothersStatusHealth = Check::safeText($value);
}
/**
* void setSpouseChildsStatusHealth(string $value)
*
* @param string $value new value to set
* @return void
* @access public
*/
public function setSpouseChildsStatusHealth($value)
{
$this->_spouseChildsStatusHealth = Check::safeText($value);
}
/**
* void setFamilyIllness(string $value)
*
* @param string $value new value to set
* @return void
* @access public
*/
public function setFamilyIllness($value)
{
$this->_familyIllness = Check::safeText($value);
}
/**
* string __toString(void)
*
* @return string class name
* @access public
* @since 0.8
*/
public function __toString()
{
return __CLASS__;
}
} // end class
?>