-
Notifications
You must be signed in to change notification settings - Fork 1
/
parser_exceptions.py
43 lines (27 loc) · 960 Bytes
/
parser_exceptions.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
class TooManyArgumentsException(Exception):
"""Exception raised for too many arguments for a function
Attributes:
message -- explanation of the error
"""
def __init__(self, message):
self.message = message
class NotEnoughArgumentsException(Exception):
"""Exception raised for too few arguments for a function
Attributes:
message -- explanation of the error
"""
def __init__(self, message):
self.message = message
class NotImplementedException(Exception):
"""Exception raised for not implemented actions
Attributes:
message -- explanation of the error
"""
def __init__(self, message):
self.message = message
class InvalidArgumentException(Exception):
def __init__(self, message: str) -> None:
self.message = message
class InvalidOperationException(Exception):
def __init__(self, message: str) -> None:
self.message = message