示例#1
0
def extract_unii_name(tree):
    unii_name_xpath = '//identifiedSubstance/name/descendant::text()'
    return extract.first_match_or_empty_string(
        tree.getroot().xpath(unii_name_xpath))
示例#2
0
def extract_unii(tree):
    unii_xpath = '//id[@root="%s"]/@extension' % UNII_OID
    return extract.first_match_or_empty_string(
        tree.getroot().xpath(unii_xpath))
示例#3
0
def extract_set_id(tree):
    return extract.first_match_or_empty_string(
        tree.getroot().xpath('/document/setId/@root'))
示例#4
0
def extract_unii_name(tree):
  unii_name_xpath = '//identifiedSubstance/name/descendant::text()'
  return extract.first_match_or_empty_string(
    tree.getroot().xpath(unii_name_xpath))
示例#5
0
def extract_unii(tree):
  unii_xpath = '//id[@root="%s"]/@extension' % UNII_OID
  return extract.first_match_or_empty_string(tree.getroot().xpath(unii_xpath))
示例#6
0
def extract_set_id(tree):
  return extract.first_match_or_empty_string(
    tree.getroot().xpath('/document/setId/@root'))