public static FeeBumpTransactionInnerTx Decode(XdrDataInputStream stream) { FeeBumpTransactionInnerTx decodedFeeBumpTransactionInnerTx = new FeeBumpTransactionInnerTx(); EnvelopeType discriminant = EnvelopeType.Decode(stream); decodedFeeBumpTransactionInnerTx.Discriminant = discriminant; switch (decodedFeeBumpTransactionInnerTx.Discriminant.InnerValue) { case EnvelopeType.EnvelopeTypeEnum.ENVELOPE_TYPE_TX: decodedFeeBumpTransactionInnerTx.V1 = TransactionV1Envelope.Decode(stream); break; } return(decodedFeeBumpTransactionInnerTx); }
public static TransactionEnvelope Decode(XdrDataInputStream stream) { TransactionEnvelope decodedTransactionEnvelope = new TransactionEnvelope(); EnvelopeType discriminant = EnvelopeType.Decode(stream); decodedTransactionEnvelope.Discriminant = discriminant; switch (decodedTransactionEnvelope.Discriminant.InnerValue) { case EnvelopeType.EnvelopeTypeEnum.ENVELOPE_TYPE_TX_V0: decodedTransactionEnvelope.V0 = TransactionV0Envelope.Decode(stream); break; case EnvelopeType.EnvelopeTypeEnum.ENVELOPE_TYPE_TX: decodedTransactionEnvelope.V1 = TransactionV1Envelope.Decode(stream); break; case EnvelopeType.EnvelopeTypeEnum.ENVELOPE_TYPE_TX_FEE_BUMP: decodedTransactionEnvelope.FeeBump = FeeBumpTransactionEnvelope.Decode(stream); break; } return(decodedTransactionEnvelope); }