Argument
open class Argument : Disposable, AutoCloseable, ArgumentInterface
An argument to a programmable transaction command
BCS
The BCS serialized form of this type is specified in bcs-schema.abnf.
Functions
| Name | Summary |
|---|---|
| close | @Synchronized open override fun close() |
| destroy | open override fun destroy() |
| equals | open operator override fun equals(other: Any?): Boolean |
| nestedResult | open override fun nestedResult(ix: UShort): Argument? Get the nested result for this result at the given index. Returns None if this is not a Result. |
| toBcs | open override fun toBcs(): ByteArray Convert this type to BCS encoded bytes. |
| toDisplayString | open override fun toDisplayString(): String Render this type as human-readable text. |
| toJson | open override fun toJson(): String Convert this type to a JSON encoded string. |
| toString | open override fun toString(): String |
Companion object functions
| Name | Summary |
|---|---|
| fromBcs | fun fromBcs(bcs: ByteArray): Argument Create this type from BCS encoded bytes. |
| fromJson | fun fromJson(json: String): Argument Create this type from a JSON encoded string. |
| newGas | fun newGas(): Argument The gas coin. The gas coin can only be used by-ref, except for with TransferObjects, which can use it by-value. |
| newInput | fun newInput(input: UShort): Argument One of the input objects or primitive values (from ProgrammableTransaction inputs) |
| newNestedResult | fun newNestedResult(commandIndex: UShort, subresultIndex: UShort): Argument Like a Result but it accesses a nested result. Currently, the only usage of this is to access a value from a Move call with multiple return values. |
| newResult | fun newResult(result: UShort): Argument The result of another command (from ProgrammableTransaction commands) |