public Rlp Encode(Transaction item, RlpBehaviors rlpBehaviors = RlpBehaviors.None) { return(Rlp.Encode(item, false)); }
public void Encode(BigInteger bigInteger, int outputLength = -1) { Rlp rlp = bigInteger == 0 ? Rlp.OfEmptyByteArray : Rlp.Encode(bigInteger.ToBigEndianByteArray(outputLength)); Write(rlp.Bytes); }
public Rlp Encode(TransactionReceipt item, RlpBehaviors rlpBehaviors = RlpBehaviors.None) { if (rlpBehaviors.HasFlag(RlpBehaviors.Storage)) { return(Rlp.Encode( rlpBehaviors.HasFlag(RlpBehaviors.Eip658Receipts) ? Rlp.Encode(item.StatusCode) : Rlp.Encode(item.PostTransactionState), Rlp.Encode(item.BlockHash), Rlp.Encode(item.BlockNumber), Rlp.Encode(item.Index), Rlp.Encode(item.Sender), Rlp.Encode(item.Recipient), Rlp.Encode(item.ContractAddress), Rlp.Encode(item.GasUsed), Rlp.Encode(item.GasUsedTotal), Rlp.Encode(item.Bloom), Rlp.Encode(item.Logs), Rlp.Encode(item.Error))); } return(Rlp.Encode( rlpBehaviors.HasFlag(RlpBehaviors.Eip658Receipts) ? Rlp.Encode(item.StatusCode) : Rlp.Encode(item.PostTransactionState), Rlp.Encode(item.GasUsedTotal), Rlp.Encode(item.Bloom), Rlp.Encode(item.Logs))); }
public Rlp Encode(TransactionReceipt item, RlpBehaviors rlpBehaviors = RlpBehaviors.None) { return(Rlp.Encode( rlpBehaviors.HasFlag(RlpBehaviors.Eip658Receipts) ? Rlp.Encode(item.StatusCode) : Rlp.Encode(item.PostTransactionState), Rlp.Encode(item.GasUsed), Rlp.Encode(item.Bloom), Rlp.Encode(item.Logs))); }