type
- Event()
Describes an action that happened in the blockchain. Neo3-Boa compiler won’t recognize the __init__ of this class. To create a new Event, use the method CreateNewEvent:
Check out Neo’s Documentation to learn more about Events.
>>> from boa3.builtin.compile_time import CreateNewEvent ... new_event: Event = CreateNewEvent( # create a new Event with the CreateNewEvent method ... [ ... ('name', str), ... ('amount', int) ... ], ... 'New Event' ... )
Deprecated since version 1.3.0: This module is deprecated. Use
boa3.sc.types
instead
- class ECPoint(arg: bytes)
Bases:
bytes
Represents a coordinate pair for elliptic curve cryptography (ECC) structures.
- Address
A type used only to indicate that a parameter or return on the manifest should be treated as an Address. Same as str.
- BlockHash
A type used only to indicate that a parameter or return on the manifest should be treated as a BlockHash. Same as UInt256.
- PublicKey
A type used only to indicate that a parameter or return on the manifest should be treated as a PublicKey. Same as ECPoint.
- ScriptHash
A type used only to indicate that a parameter or return on the manifest should be treated as a ScriptHash. Same as UInt160.
- ScriptHashLittleEndian
A type used only to indicate that a parameter or return on the manifest should be treated as a ScriptHashLittleEndian. Same as UInt160.
- TransactionId
A type used only to indicate that a parameter or return on the manifest should be treated as a TransactionId. Same as UInt256.
Subpackages
helper
- to_bool(value: bytes) bool
Return a bytes value to the boolean it represents.
>>> to_bool(b'\x00') False
>>> to_bool(b'\x01') True
>>> to_bool(b'\x02') True
Deprecated since version 1.3.0: This module is deprecated. Use
boa3.sc.utils
instead
- to_bytes(value: str | int) bytes
Converts a str or integer value to an array of bytes
>>> to_bytes(65) b'A'
>>> to_bytes('A') b'A'
Deprecated since version 1.3.0: This module is deprecated. Use
boa3.sc.utils
instead
- to_int(value: bytes) int
Converts a bytes value to the integer it represents.
>>> to_int(b'A') 65
Deprecated since version 1.3.0: This module is deprecated. Use
boa3.sc.utils
instead
- to_str(value: bytes) str
Converts a bytes value to a string.
>>> to_str(b'A') 'A'
Deprecated since version 1.3.0: This module is deprecated. Use
boa3.sc.utils
instead