Exemple #1
0
 def __init__(self, _id, members, events):
     validate_unique_method_ids(members.values())
     for key in members:
         validate_identifier(key)
     self._id = _id
     self.members = members
     self.events = events
Exemple #2
0
 def __init__(self, name: str, members: dict) -> None:
     for key in members.keys():
         validate_identifier(key)
     self.name = name
     if len(members.keys()) > 256:
         raise EnumDeclarationException("Enums are limited to 256 members!")
     self.members = members
Exemple #3
0
 def __init__(self, name: str, arguments: OrderedDict,
              indexed: List) -> None:
     for key in arguments:
         validate_identifier(key)
     self.name = name
     self.arguments = arguments
     self.indexed = indexed
     self.event_id = int(keccak256(self.signature.encode()).hex(), 16)
Exemple #4
0
 def __init__(self, _id, members):
     for key in members:
         validate_identifier(key)
     self._id = _id
     self.members = members