def xml(self, attribs = None,elements = None, skipchildren = False):
        """See :meth:`AbstractElement.xml`"""
        if self.set is False or self.set is None:
            if len(self.data) == 0: #just skip if there are no children
                return None
            else:
                raise ValueError("No set specified or derivable for annotation layer " + self.__class__.__name__)
        return super(AbstractAnnotationLayer, self).xml(attribs, elements, skipchildren)
def xml ( self , attribs = None , elements = None , skipchildren = False ) : if self . set is False or self . set is None : if len ( self . data ) == 0 : return None else : raise ValueError ( "No set specified or derivable for annotation layer " + self . __class__ . __name__ ) return super ( AbstractAnnotationLayer , self ) . xml ( attribs , elements , skipchildren )
See :meth:`AbstractElement.xml`