Tradehub.Tx.Type behaviour (Tradehub v0.1.17) View Source

The abstract module for type defination.

Link to this section Summary

Callbacks

Define the type of the transaction.

This function trying to validate the given payload and returns the payload itself, if no errors found. Or else, an Tradehub.Tx.MsgInvalid error will be raised.

Link to this section Callbacks

Specs

type() :: String.t()

Define the type of the transaction.

Specs

validate!(term()) :: term()

This function trying to validate the given payload and returns the payload itself, if no errors found. Or else, an Tradehub.Tx.MsgInvalid error will be raised.