Package Gnumed :: Package business :: Module gmPathLab :: Class cMeasurementType
[frames] | no frames]

Class cMeasurementType

source code

                                   object --+    
                                            |    
pycommon.gmBusinessDBObject.cBusinessDBObject --+
                                                |
                                               cMeasurementType

Represents one test result type.

Instance Methods
 
get_most_recent_results(self, patient=None, no_of_results=1) source code
 
get_oldest_result(self, patient=None) source code
 
get_meta_test_type(self, real_one_only=True) source code
 
get_temporally_closest_normal_range(self, unit, timestamp=None)
Returns the closest test result which does have normal range information.
source code
 
get_temporally_closest_target_range(self, unit, patient, timestamp=None)
Returns the closest test result which does have target range information.
source code
 
get_temporally_closest_unit(self, timestamp=None)
Returns the unit of the closest test result.
source code
 
format(self, patient=None) source code

Inherited from pycommon.gmBusinessDBObject.cBusinessDBObject: __del__, __getitem__, __init__, __setitem__, __str__, fields_as_dict, get_fields, get_patient, get_updatable_fields, is_modified, refetch_payload, same_payload, save, save_payload

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __subclasshook__

Class Variables
  in_use = property(_get_in_use, lambda x: x)
  test_panels = property(_get_test_panels, lambda x: x)
  meta_test_type = property(get_meta_test_type, lambda x: x)
  temporally_closest_unit = property(get_temporally_closest_unit...
Properties

Inherited from object: __class__

Method Details

get_temporally_closest_normal_range(self, unit, timestamp=None)

source code 
Returns the closest test result which does have normal range information.

- needs <unit>
- if <timestamp> is None it will assume now() and thus return the most recent

get_temporally_closest_target_range(self, unit, patient, timestamp=None)

source code 
Returns the closest test result which does have target range information.

- needs <unit>
- needs <patient> (as target will be per-patient)
- if <timestamp> is None it will assume now() and thus return the most recent

get_temporally_closest_unit(self, timestamp=None)

source code 
Returns the unit of the closest test result.

- if <timestamp> is None it will assume now() and thus return the most recent

format(self, patient=None)

source code 
Overrides: pycommon.gmBusinessDBObject.cBusinessDBObject.format

Class Variable Details

temporally_closest_unit

Value:
property(get_temporally_closest_unit, lambda x: x)