public CordaRPCOps extends RPCOps
RPC operations that the node exposes to clients using the Java client library. These can be called from client apps and are implemented by the node in the CordaRPCOpsImpl class.
Modifier and Type | Method and Description |
---|---|
void |
addVaultTransactionNote(SecureHash txnId,
java.lang.String txnNote) |
boolean |
attachmentExists(SecureHash id)
Checks whether an attachment with the given hash is stored on the node.
|
void |
authoriseContractUpgrade(StateAndRef<?> state,
java.lang.Class<? extends net.corda.core.contracts.UpgradedContract<?,?>> upgradedContractClass)
Authorise a contract state upgrade.
This will store the upgrade authorisation in the vault, and will be queried by ContractUpgradeFlow.Acceptor during contract upgrade process.
Invoking this method indicate the node is willing to upgrade the state using the upgradedContractClass.
This method will NOT initiate the upgrade process. To start the upgrade process, see ContractUpgradeFlow.Instigator.
|
java.time.Instant |
currentNodeTime()
Returns the node's current time.
|
void |
deauthoriseContractUpgrade(StateAndRef<?> state)
Authorise a contract state upgrade.
This will remove the upgrade authorisation from the vault.
|
java.lang.Iterable<java.lang.String> |
getVaultTransactionNotes(SecureHash txnId) |
kotlin.Pair<java.util.List,rx.Observable> |
networkMapUpdates()
Returns all parties currently visible on the network with their advertised services and an observable of future updates to the network.
|
NodeInfo |
nodeIdentity()
Returns Node's identity, assuming this will not change while the node is running.
|
java.io.InputStream |
openAttachment(SecureHash id)
Download an attachment JAR by ID
|
Party |
partyFromKey(CompositeKey key)
Returns the
class Party corresponding to the given key, if found. |
Party |
partyFromName(java.lang.String name)
Returns the
class Party with the given name as it's Party.name |
<T> FlowHandle<T> |
startFlowDynamic(java.lang.Class<? extends net.corda.core.flows.FlowLogic<? extends T>> logicType,
java.lang.Object args)
Start the given flow with the given arguments, returning an Observable with a single observation of the
result of running the flow.
|
kotlin.Pair<java.util.List,rx.Observable> |
stateMachineRecordedTransactionMapping()
Returns a snapshot list of existing state machine id - recorded transaction hash mappings, and a stream of future
such mappings as well.
|
kotlin.Pair<java.util.List,rx.Observable> |
stateMachinesAndUpdates()
Returns a pair of currently in-progress state machine infos and an observable of future state machine adds/removes.
|
SecureHash |
uploadAttachment(java.io.InputStream jar)
Uploads a jar to the node, returns it's hash.
|
java.lang.String |
uploadFile(java.lang.String dataType,
java.lang.String name,
java.io.InputStream file)
Deprecated.
|
kotlin.Pair<java.util.List,rx.Observable> |
vaultAndUpdates()
Returns a pair of head states in the vault and an observable of future updates to the vault.
|
kotlin.Pair<java.util.List,rx.Observable> |
verifiedTransactions()
Returns a pair of all recorded transactions and an observable of future recorded ones.
|
com.google.common.util.concurrent.ListenableFuture<kotlin.Unit> |
waitUntilRegisteredWithNetworkMap()
Returns a ListenableFuture which completes when the node has registered wih the network map service. It can also
complete with an exception if it is unable to.
|
getProtocolVersion
kotlin.Pair<java.util.List,rx.Observable> stateMachinesAndUpdates()
Returns a pair of currently in-progress state machine infos and an observable of future state machine adds/removes.
kotlin.Pair<java.util.List,rx.Observable> vaultAndUpdates()
Returns a pair of head states in the vault and an observable of future updates to the vault.
kotlin.Pair<java.util.List,rx.Observable> verifiedTransactions()
Returns a pair of all recorded transactions and an observable of future recorded ones.
kotlin.Pair<java.util.List,rx.Observable> stateMachineRecordedTransactionMapping()
Returns a snapshot list of existing state machine id - recorded transaction hash mappings, and a stream of future such mappings as well.
kotlin.Pair<java.util.List,rx.Observable> networkMapUpdates()
Returns all parties currently visible on the network with their advertised services and an observable of future updates to the network.
<T> FlowHandle<T> startFlowDynamic(java.lang.Class<? extends net.corda.core.flows.FlowLogic<? extends T>> logicType, java.lang.Object args)
Start the given flow with the given arguments, returning an Observable with a single observation of the result of running the flow.
NodeInfo nodeIdentity()
Returns Node's identity, assuming this will not change while the node is running.
void addVaultTransactionNote(SecureHash txnId, java.lang.String txnNote)
java.lang.Iterable<java.lang.String> getVaultTransactionNotes(SecureHash txnId)
boolean attachmentExists(SecureHash id)
Checks whether an attachment with the given hash is stored on the node.
java.io.InputStream openAttachment(SecureHash id)
Download an attachment JAR by ID
SecureHash uploadAttachment(java.io.InputStream jar)
Uploads a jar to the node, returns it's hash.
java.lang.String uploadFile(java.lang.String dataType, java.lang.String name, java.io.InputStream file)
void authoriseContractUpgrade(StateAndRef<?> state, java.lang.Class<? extends net.corda.core.contracts.UpgradedContract<?,?>> upgradedContractClass)
Authorise a contract state upgrade. This will store the upgrade authorisation in the vault, and will be queried by ContractUpgradeFlow.Acceptor during contract upgrade process. Invoking this method indicate the node is willing to upgrade the state using the upgradedContractClass. This method will NOT initiate the upgrade process. To start the upgrade process, see ContractUpgradeFlow.Instigator.
void deauthoriseContractUpgrade(StateAndRef<?> state)
Authorise a contract state upgrade. This will remove the upgrade authorisation from the vault.
java.time.Instant currentNodeTime()
Returns the node's current time.
com.google.common.util.concurrent.ListenableFuture<kotlin.Unit> waitUntilRegisteredWithNetworkMap()
Returns a ListenableFuture which completes when the node has registered wih the network map service. It can also complete with an exception if it is unable to.
Party partyFromKey(CompositeKey key)
Returns the class Party
corresponding to the given key, if found.
class Party
Party partyFromName(java.lang.String name)
Returns the class Party
with the given name as it's Party.name
class Party