Exemplo n.º 1
0
 def __getattr__(self, name):
     '''Get the value of an attribute or item by B{C{name}}.
     '''
     try:
         return tuple.__getitem__(self, self._Names_.index(name))
     except IndexError:
         raise _IndexError(_DOT_(self.classname, Fmt.ANGLE(_name_)), name)
     except ValueError:
         return tuple.__getattribute__(self, name)
Exemplo n.º 2
0
 def __repr__(self):
     '''Default C{repr(self)}.
     '''
     return Fmt.ANGLE(_SPACE_(self, 'at %#x' % (id(self), )))