コード例 #1
0
ファイル: tables.py プロジェクト: pbugni/pheme.warehouse
    def compare_str(self):
        """Generates a string representation of the instance safe to
        use in comparisons w/ similar types.  (i.e. HL7_Dx and
        Diagnosis)

        """
        return stringFields((self.dx_code, self.dx_type))
コード例 #2
0
ファイル: tables.py プロジェクト: pbugni/pheme.warehouse
    def compare_str(self):
        """Generates a string representation of the instance safe to
        use in comparisons w/ similar types.  (i.e. HL7_Dx and
        Diagnosis)

        """
        return stringFields((self.dx_code,self.dx_type))
コード例 #3
0
ファイル: tables.py プロジェクト: pbugni/pheme.warehouse
    def compare_str(self):
        """Generates a string representation of the instance safe to
        use in comparisons w/ similar types. (i.e. HL7_Obr & Obr)

        """
        # When we get a loinc_code, we also get loinc_text - don't
        # need both in comparisons.
        return stringFields((self.loinc_code, self.alt_text))
コード例 #4
0
ファイル: tables.py プロジェクト: pbugni/pheme.warehouse
    def compare_str(self):
        """Generates a string representation of the instance safe to
        use in comparisons w/ similar types. (i.e. HL7_Obr & Obr)

        """
        # When we get a loinc_code, we also get loinc_text - don't
        # need both in comparisons.
        return stringFields((self.loinc_code, self.alt_text))
コード例 #5
0
ファイル: tables.py プロジェクト: pbugni/pheme.warehouse
    def compare_str(self):
        """Generates a string representation of the instance safe to
        use in comparisons w/ similar types. (i.e. HL7_Obx & Obx)

        """
        # Boolean logic for the value of hl7_obr_id - its value
        # would naturally be different between the two types.
        return stringFields(
            (self.hl7_obr_id and 't' or 'f', self.value_type,
             self.observation_id, self.observation_text,
             self.observation_result, self.units, self.result_status))
コード例 #6
0
ファイル: tables.py プロジェクト: pbugni/pheme.warehouse
    def compare_str(self):
        """Generates a string representation of the instance safe to
        use in comparisons w/ similar types. (i.e. HL7_Obx & Obx)

        """
        # Boolean logic for the value of hl7_obr_id - its value
        # would naturally be different between the two types.
        return stringFields((self.hl7_obr_id and 't' or 'f', 
                         self.value_type,
                         self.observation_id,
                         self.observation_text,
                         self.observation_result,
                         self.units,
                         self.result_status)) 
コード例 #7
0
ファイル: test_util.py プロジェクト: pbugni/pheme.util
def test_stringFields():
    assert('' == stringFields((None,)))
    assert('1:2:3:four' == stringFields((1,2,None,3,"four")))
コード例 #8
0
ファイル: test_util.py プロジェクト: pbugni/pheme.util
def test_stringFields():
    assert ('' == stringFields((None, )))
    assert ('1:2:3:four' == stringFields((1, 2, None, 3, "four")))