@ApiAudience.Public @ApiStability.Unstable public interface ContractOperation
Modifier and Type | Method and Description |
---|---|
ContractTxHash |
deploy(Account creator,
ContractDefinition contractDefinition,
long nonce)
Deprecated.
|
ContractTxHash |
deploy(Account creator,
ContractDefinition contractDefinition,
long nonce,
Fee fee)
Deprecated.
|
ContractTxHash |
deploy(Signer signer,
ContractDefinition contractDefinition,
long nonce,
Fee fee)
Deploy smart contract.
|
ContractTxHash |
execute(Account executor,
ContractInvocation contractInvocation,
long nonce)
Deprecated.
|
ContractTxHash |
execute(Account executor,
ContractInvocation contractInvocation,
long nonce,
Fee fee)
Deprecated.
|
ContractTxHash |
execute(Signer signer,
ContractInvocation contractInvocation,
long nonce,
Fee fee)
Execute the smart contract.
|
ContractInterface |
getContractInterface(ContractAddress contractAddress)
Get smart contract interface corresponding to contract address.
|
ContractTxReceipt |
getReceipt(ContractTxHash contractTxHash)
Get receipt of transaction.
|
java.util.List<Event> |
listEvents(EventFilter filter)
List events corresponding to an event filter.
|
ContractResult |
query(ContractInvocation contractInvocation)
Query the smart contract state by calling smart contract function.
|
ContractTxHash |
redeploy(Signer signer,
ContractAddress existingContract,
ContractDefinition contractDefinition,
long nonce,
Fee fee)
Re-deploy smart contract.
|
Subscription<Event> |
subscribeEvent(EventFilter filter,
StreamObserver<Event> observer)
Subscribe event corresponding to an event filter.
|
ContractTxReceipt getReceipt(ContractTxHash contractTxHash)
contractTxHash
- contract transaction hash@Deprecated ContractTxHash deploy(Account creator, ContractDefinition contractDefinition, long nonce)
deploy(Signer, ContractDefinition, long, Fee)
instead.creator
- an creator accountcontractDefinition
- contract definitionnonce
- an nonce used in making transaction@Deprecated ContractTxHash deploy(Account creator, ContractDefinition contractDefinition, long nonce, Fee fee)
deploy(Signer, ContractDefinition, long, Fee)
instead.creator
- an creator accountcontractDefinition
- contract definitionnonce
- an nonce used in making transactionfee
- transaction feeContractTxHash deploy(Signer signer, ContractDefinition contractDefinition, long nonce, Fee fee)
signer
- a signer whose principal is smart contract creator.contractDefinition
- a contract definitionnonce
- an nonce used in making transactionfee
- a transaction feeContractTxHash redeploy(Signer signer, ContractAddress existingContract, ContractDefinition contractDefinition, long nonce, Fee fee)
signer
must be creator and
contractAddress
must be existing one.signer
- a signer whose principal is smart contract creator.existingContract
- an existing contract addresscontractDefinition
- contract definition to re-deploynonce
- an nonce used in making transactionfee
- a transaction feeContractInterface getContractInterface(ContractAddress contractAddress)
contractAddress
- contract address@Deprecated ContractTxHash execute(Account executor, ContractInvocation contractInvocation, long nonce)
execute(Signer, ContractInvocation, long, Fee)
instead.executor
- an executor accountcontractInvocation
- ContractInvocation
nonce
- an nonce used in making transaction@Deprecated ContractTxHash execute(Account executor, ContractInvocation contractInvocation, long nonce, Fee fee)
execute(Signer, ContractInvocation, long, Fee)
instead.executor
- an executor accountcontractInvocation
- ContractInvocation
nonce
- an nonce used in making transactionfee
- transaction feeContractTxHash execute(Signer signer, ContractInvocation contractInvocation, long nonce, Fee fee)
signer
- a signer which will execute smart contract.contractInvocation
- ContractInvocation
nonce
- an nonce used in making transactionfee
- transaction feeContractResult query(ContractInvocation contractInvocation)
contractInvocation
- ContractInvocation
java.util.List<Event> listEvents(EventFilter filter)
filter
- an event filterSubscription<Event> subscribeEvent(EventFilter filter, StreamObserver<Event> observer)
filter
- an event filterobserver
- a stream observer which is invoked on event