public class WriteInstance extends Object
| Modifier and Type | Field and Description |
|---|---|
static String |
ContractId |
| Constructor and Description |
|---|
WriteInstance(CalypsoRPC calypso,
DarcId darcId,
List<Signer> signers,
WriteData wr)
Constructor for creating a new instance.
|
| Modifier and Type | Method and Description |
|---|---|
static WriteInstance |
fromCalypso(CalypsoRPC calypso,
InstanceId writeId)
Fetches an already existing writeInstance from Calypso and returns it.
|
DarcId |
getDarcId() |
Instance |
getInstance()
Get the instance.
|
LTS |
getLts()
Get the LTS configuration.
|
WriteData |
getWrite() |
ReadInstance |
spawnCalypsoRead(CalypsoRPC calypso,
List<Signer> readers)
Spawns a new CalypsoRead instance for this Write Instance.
|
public static String ContractId
public WriteInstance(CalypsoRPC calypso, DarcId darcId, List<Signer> signers, WriteData wr) throws CothorityException
calypso - The CalypsoRPC object which should be already running.darcId - The darc ID for which the signers belong.signers - The list of signers that are authorised to create the instance.wr - The WriteData object, to be stored in the instance.CothorityExceptionpublic LTS getLts()
public Instance getInstance()
public DarcId getDarcId()
public WriteData getWrite() throws CothorityNotFoundException
com.google.protobuf.InvalidProtocolBufferException - if the instance data is corruptCothorityNotFoundException - if the instance does not hold a CalypsoWrite datapublic ReadInstance spawnCalypsoRead(CalypsoRPC calypso, List<Signer> readers) throws CothorityException
calypso - an existing calypso objectreaders - one or more readers that can sign the read spawn instructionCothorityExceptionpublic static WriteInstance fromCalypso(CalypsoRPC calypso, InstanceId writeId) throws CothorityException
calypso - writeId - CothorityExceptionCopyright © 2018. All rights reserved.