- type Account
- type AccountID
- type Rule
Account represents a dex client account.
NewID generates a unique account id with the provided public key bytes.
func (AccountID) MarshalJSON ¶
MarshalJSON satisfies the json.Marshaller interface, and will marshal the id to a hex string.
Scan implements the sql.Scanner interface.
String returns a hexadecimal representation of the AccountID. String implements fmt.Stringer.
type Rule uint8
Rule represents a rule of community conduct.
const ( // NoRule indicates that no rules have been broken. This may be an invalid // value in some contexts. NoRule Rule = iota // PreimageReveal means an account failed to respond with a valid preimage // for their order during epoch processing. PreimageReveal // FailureToAct means that an account has not followed through on one of their // swap negotiation steps. FailureToAct // CancellationRate means the account's cancellation rate has dropped below // the acceptable level. CancellationRate // LowFees means an account made a transaction that didn't pay fees at the // requisite level. LowFees // MaxRule in not an actual rule. It is a placeholder that is used to // determine the total number of rules. It must always be the last // definition in this list. MaxRule )
func (Rule) Description ¶
Description returns a description of the rule.
Duration returns the penalty duration of the rule being broken.
func (Rule) Punishable ¶
Punishable returns whether breaking this rule incurs a penalty.