def iter_children(self, key=None):
        u"""Iterates over children.

        :param key: A key for filtering children by tagname.
        """
        tag = None

        if key:
            tag = self._get_aliases().get(key)

            if not tag:
                raise KeyError(key)

        for child in self._xml.iterchildren(tag=tag):
            if len(child):
                yield self.__class__(child)
            else:
                yield Literal(child)
def iter_children ( self , key = None ) : tag = None if key : tag = self . _get_aliases ( ) . get ( key ) if not tag : raise KeyError ( key ) for child in self . _xml . iterchildren ( tag = tag ) : if len ( child ) : yield self . __class__ ( child ) else : yield Literal ( child )
u"""Iterates over children.

        :param key: A key for filtering children by tagname.