This method adds the taxon-group content to the
XML being built.
# - - - B i r d F o r m . _ _ w r i t e T a x o n G r o u p
def __writeTaxonGroup ( self, formNode ):
"""Attach taxon-group content to formNode.
[ formNode is an et.Element ->
formNode +:= self's taxon-group content ]
"""
The ab6 attribute is required. The rel attribute is optional, but if it is used, there
must also be an alt attribute. Finally, the
notable attribute is optional.
#-- 1 --
# [ formNode +:= an rnc.AB6_A attribute made from self.ab6 ]
formNode.attrib [ rnc.AB6_A ] = self.ab6
#-- 2 --
# [ if self.rel ->
# formNode := formNode with an rnc.REL_A attribute
# made from self.rel and an rnc.ALT_A attribute
# made from self.alt
# else -> I ]
if self.rel:
formNode.attrib [ rnc.REL_A ] = self.rel
formNode.attrib [ rnc.ALT_A ] = self.alt
#-- 3 --
if self.notable:
formNode.attrib [ rnc.NOTABLE_A ] = self.notable