Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class UnknownPrefix(Exception):
- '''Raised if a given prefix does not map to any items'''
- def __init__(self,prefix,*args):
- Exception.__init__(self,*args)
- self.prefix = prefix
- class AmbiguousPrefix(Exception):
- '''Raised if a given prefix maps to multiple items'''
- def __init__(self,prefix,choices,*args):
- Exception.__init__(self,*args)
- self.prefix = prefix
- self.choices = choices
Add Comment
Please, Sign In to add comment