- check_witness(hash_or_pubkey: Union[boa3.builtin.type.UInt160, boa3.builtin.type.ECPoint]) → bool¶
Verifies that the transactions or block of the calling contract has validated the required script hash.
- notify(state: Any, notification_name: Optional[str] = None)¶
Notifies the client from the executing smart contract.
state (Any) – the notification message
notification_name (str) – name that’ll be linked to the notification
- log(message: str)¶
Show log messages to the client from the executing smart contract.
message (str) – the log message
- get_trigger() → boa3.neo3.contracts.contracttypes.TriggerType¶
Return the smart contract trigger type.
a value that represents the contract trigger type
- Return type
- get_notifications(script_hash: boa3.builtin.type.UInt160 = b'') → List[boa3.builtin.interop.runtime.notification.Notification]¶
This method gets current invocation notifications from specific ‘script_hash’.
- get_network() → int¶
Gets the magic number of the current network.
the magic number of the current network
- Return type
- burn_gas(gas: int)¶
Burns GAS to benefit the NEO ecosystem.
- invocation_counter: int¶
Gets the number of times the current contract has been called during the execution.
- script_container: Any¶
Gets the current script container.
- class TriggerType(value)¶
Represents the triggers for running smart contracts. Triggers enable the contract to execute different logic under different usage scenarios.
Indicate that the contract is triggered by the system to execute the OnPersist method of the native contracts.
Indicate that the contract is triggered by the system to execute the PostPersist method of the native contracts.
The combination of all system triggers.
Indicates that the contract is triggered by the verification of a IVerifiable.
Indicates that the contract is triggered by the execution of transactions.
The combination of all triggers.