public class ChangeTrustAsset extends java.lang.Object implements XdrElement
union ChangeTrustAsset switch (AssetType type) { case ASSET_TYPE_NATIVE: // Not credit void; case ASSET_TYPE_CREDIT_ALPHANUM4: AlphaNum4 alphaNum4; case ASSET_TYPE_CREDIT_ALPHANUM12: AlphaNum12 alphaNum12; case ASSET_TYPE_POOL_SHARE: LiquidityPoolParameters liquidityPool; // add other asset types here in the future };
Modifier and Type | Class and Description |
---|---|
static class |
ChangeTrustAsset.ChangeTrustAssetBuilder |
Constructor and Description |
---|
ChangeTrustAsset() |
ChangeTrustAsset(AssetType discriminant,
AlphaNum4 alphaNum4,
AlphaNum12 alphaNum12,
LiquidityPoolParameters liquidityPool) |
Modifier and Type | Method and Description |
---|---|
static ChangeTrustAsset.ChangeTrustAssetBuilder |
builder() |
static ChangeTrustAsset |
decode(XdrDataInputStream stream) |
void |
encode(XdrDataOutputStream stream) |
boolean |
equals(java.lang.Object o) |
static ChangeTrustAsset |
fromXdrBase64(java.lang.String xdr) |
static ChangeTrustAsset |
fromXdrByteArray(byte[] xdr) |
AlphaNum12 |
getAlphaNum12() |
AlphaNum4 |
getAlphaNum4() |
AssetType |
getDiscriminant() |
LiquidityPoolParameters |
getLiquidityPool() |
int |
hashCode() |
void |
setAlphaNum12(AlphaNum12 alphaNum12) |
void |
setAlphaNum4(AlphaNum4 alphaNum4) |
void |
setDiscriminant(AssetType discriminant) |
void |
setLiquidityPool(LiquidityPoolParameters liquidityPool) |
ChangeTrustAsset.ChangeTrustAssetBuilder |
toBuilder() |
java.lang.String |
toString() |
toXdrBase64, toXdrByteArray
public ChangeTrustAsset()
public ChangeTrustAsset(AssetType discriminant, AlphaNum4 alphaNum4, AlphaNum12 alphaNum12, LiquidityPoolParameters liquidityPool)
public void encode(XdrDataOutputStream stream) throws java.io.IOException
encode
in interface XdrElement
java.io.IOException
public static ChangeTrustAsset decode(XdrDataInputStream stream) throws java.io.IOException
java.io.IOException
public static ChangeTrustAsset fromXdrBase64(java.lang.String xdr) throws java.io.IOException
java.io.IOException
public static ChangeTrustAsset fromXdrByteArray(byte[] xdr) throws java.io.IOException
java.io.IOException
public static ChangeTrustAsset.ChangeTrustAssetBuilder builder()
public ChangeTrustAsset.ChangeTrustAssetBuilder toBuilder()
public AssetType getDiscriminant()
public AlphaNum4 getAlphaNum4()
public AlphaNum12 getAlphaNum12()
public LiquidityPoolParameters getLiquidityPool()
public void setDiscriminant(AssetType discriminant)
public void setAlphaNum4(AlphaNum4 alphaNum4)
public void setAlphaNum12(AlphaNum12 alphaNum12)
public void setLiquidityPool(LiquidityPoolParameters liquidityPool)
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object