Logo Search packages:      
Sourcecode: aap version File versions

def aap-1.090::aapre::MatchObject::span (   self,
  g = 0 
)

span([group=0]) -> tuple

Return the 2-tuple (m.start(group), m.end(group)). Note that
if group did not contribute to the match, this is (-1,
-1). Group defaults to zero (meaning the whole matched
substring).

Definition at line 571 of file aapre.py.

00571                          :
        """span([group=0]) -> tuple

        Return the 2-tuple (m.start(group), m.end(group)). Note that
        if group did not contribute to the match, this is (-1,
        -1). Group defaults to zero (meaning the whole matched
        substring).

        """
        if type(g) == type(''):
            try:
                g = self.re.groupindex[g]
            except (KeyError, TypeError):
                raise IndexError, 'group %s is undefined' % `g`
        return self.regs[g]

    def groups(self, default=None):


Generated by  Doxygen 1.6.0   Back to index