コード例 #1
0
ファイル: exception.py プロジェクト: GunioRobot/xhpy
 def getElementName(cls, that):
   name = that.__class__.__name__
   if name[:5] != 'xhpy_':
     return name
   return class2element(name)
コード例 #2
0
ファイル: exception.py プロジェクト: GunioRobot/xhpy
  def __init__(self, that, rend):
    super(XHPyException, self).__init__("""\
:x:element.render() must reduce an object to an :x:primitive, but `%s` reduced into `%s`
""" % (class2element(that.__class__.__name__), type(rend)))