Next / Previous / Contents / Shipman's homepage

6.25. UniEntSet.__init__()

The schema gives this structure for a set element. The fpi atribute is the optional public identifier, e.g.: # “ISO 8879:1986//ENTITIES Box and Line Drawing//EN”. We set the instance's .fpi attribute to None if it's missing.

set = element set
{ attribute name { text },
  attribute fpi { text }?
}
unidata.py
# - - -   U n i S e t . _ _ i n i t _ _

    def __init__(self, node):
        '''Constructor.
        '''
        self.name = node.attrib[NAME_A]
        self.fpi = node.attrib.get(FPI_A, None)