Package org.stellar.sdk.xdr
Class Claimant.ClaimantV0
java.lang.Object
org.stellar.sdk.xdr.Claimant.ClaimantV0
- All Implemented Interfaces:
XdrElement
- Enclosing class:
Claimant
ClaimantV0's original definition in the XDR file is:
struct
{
AccountID destination; // The account that can use this condition
ClaimPredicate predicate; // Claimable if predicate is true
}
-
Nested Class Summary
Nested Classes -
Field Summary
Fields inherited from interface org.stellar.sdk.xdr.XdrElement
gson -
Constructor Summary
ConstructorsConstructorDescriptionClaimantV0(AccountID destination, ClaimPredicate predicate) Creates a newClaimantV0instance. -
Method Summary
Modifier and TypeMethodDescriptionbuilder()static Claimant.ClaimantV0decode(XdrDataInputStream stream) static Claimant.ClaimantV0decode(XdrDataInputStream stream, int maxDepth) voidencode(XdrDataOutputStream stream) Encodes this value to XDR and writes it to the provided stream.booleanstatic Claimant.ClaimantV0static Claimant.ClaimantV0fromXdrBase64(String xdr) static Claimant.ClaimantV0fromXdrByteArray(byte[] xdr) Value of thedestinationfield.Value of thepredicatefield.inthashCode()voidsetDestination(AccountID destination) Value of thedestinationfield.voidsetPredicate(ClaimPredicate predicate) Value of thepredicatefield.toJson()Serializes this value to JSON.toString()Methods inherited from interface org.stellar.sdk.xdr.XdrElement
toXdrBase64, toXdrByteArray
-
Constructor Details
-
ClaimantV0
public ClaimantV0() -
ClaimantV0
Creates a newClaimantV0instance.- Parameters:
destination- thedestinationfield valuepredicate- thepredicatefield value
-
-
Method Details
-
encode
Description copied from interface:XdrElementEncodes this value to XDR and writes it to the provided stream.- Specified by:
encodein interfaceXdrElement- Parameters:
stream- the destination XDR output stream- Throws:
IOException- if an I/O error occurs while writing the value
-
decode
public static Claimant.ClaimantV0 decode(XdrDataInputStream stream, int maxDepth) throws IOException - Throws:
IOException
-
decode
- Throws:
IOException
-
fromXdrBase64
- Throws:
IOException
-
fromXdrByteArray
- Throws:
IOException
-
toJson
Description copied from interface:XdrElementSerializes this value to JSON.- Specified by:
toJsonin interfaceXdrElement- Returns:
- the JSON representation of this value
-
fromJson
-
builder
-
toBuilder
-
getDestination
Value of thedestinationfield.- Returns:
- the
destinationfield value
-
getPredicate
Value of thepredicatefield.- Returns:
- the
predicatefield value
-
setDestination
Value of thedestinationfield.- Parameters:
destination- thedestinationfield value
-
setPredicate
Value of thepredicatefield.- Parameters:
predicate- thepredicatefield value
-
equals
-
hashCode
public int hashCode() -
toString
-