From 8eb5d88b9b8d46e00450d26472a151a0f916d2de Mon Sep 17 00:00:00 2001 From: Andrew Chiw Date: Wed, 10 Apr 2019 15:30:21 +0200 Subject: [PATCH] docs: add minor comments on exported functions --- aeternity/hashing.go | 1 + aeternity/transactions.go | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/aeternity/hashing.go b/aeternity/hashing.go index 58a81b9c..a221e013 100644 --- a/aeternity/hashing.go +++ b/aeternity/hashing.go @@ -157,6 +157,7 @@ func buildIDTag(IDTag uint8, encodedHash string) (v []uint8, err error) { return } +// DecodeRLPMessage transforms a plain stream of bytes into a structure of bytes that represents the object that was serialized func DecodeRLPMessage(rawBytes []byte) []interface{} { res := []interface{}{} rlp.DecodeBytes(rawBytes, &res) diff --git a/aeternity/transactions.go b/aeternity/transactions.go index 3fdddb7e..8168717d 100644 --- a/aeternity/transactions.go +++ b/aeternity/transactions.go @@ -259,7 +259,6 @@ func NewNameClaimTx(accountID, name string, nameSalt utils.BigInt, fee utils.Big } // NameUpdateTx represents a transaction where one extends the lifetime of a reserved name on AENS - type NameUpdateTx struct { AccountID string NameID string @@ -508,6 +507,7 @@ func (t *OracleQueryTx) RLP() (rlpRawMsg []byte, err error) { return } +// JSON representation of a Tx is useful for querying the node's debug endpoint func (t *OracleQueryTx) JSON() (string, error) { responseTTLTypeStr := ttlTypeIntToStr(t.ResponseTTLType) queryTTLTypeStr := ttlTypeIntToStr(t.QueryTTLType)