types

package
v0.0.0-...-b535dc5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 2, 2023 License: MIT Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var CommandKindValues = []any{"submitTx", "interrogateTx", "speedUpTx", "createAccount", "listAccount", "disableAccount"}
View Source
var EventKindValues = []any{"submitted", "interrogated", "speededup", "completed"}
View Source
var PriorityValues = []any{"low", "standard", "fast"}

Functions

This section is empty.

Types

type Command

type Command struct {
	Kind    *CommandKind `json:"kind" mapstructure:"kind"`
	Details interface{}  `json:"details" mapstructure:"details"`
}

Command represents a Command model.

type CommandKind

type CommandKind uint

CommandKind represents an enum of CommandKind.

const (
	CommandKindSubmitTx CommandKind = iota
	CommandKindInterrogateTx
	CommandKindSpeedUpTx
	CommandKindCreateAccount
	CommandKindListAccount
	CommandKindDisableAccount
)

func (CommandKind) Value

func (op CommandKind) Value() any

Value returns the value of the enum.

type Event

type Event struct {
	Kind    *EventKind  `json:"kind" mapstructure:"kind"`
	Details interface{} `json:"details" mapstructure:"details"`
}

Event represents a Event model.

type EventKind

type EventKind uint

EventKind represents an enum of EventKind.

const (
	EventKindSubmitted EventKind = iota
	EventKindInterrogated
	EventKindSpeededup
	EventKindCompleted
)

func (EventKind) Value

func (op EventKind) Value() any

Value returns the value of the enum.

type InterrogateTransaction

type InterrogateTransaction struct {
	Blockchain string     `json:"blockchain" mapstructure:"blockchain"`
	Context    *TxContext `json:"context" mapstructure:"context"`
}

InterrogateTransaction represents a InterrogateTransaction model.

type ModelError

type ModelError struct {
	Code        int    `json:"code" mapstructure:"code"`
	Key         string `json:"key" mapstructure:"key"`
	Message     string `json:"message" mapstructure:"message"`
	ExternalRef string `json:"external_ref" mapstructure:"external_ref"`
}

ModelError represents a ModelError model.

type Priority

type Priority uint

Priority represents an enum of Priority.

const (
	PriorityLow Priority = iota
	PriorityStandard
	PriorityFast
)

func (Priority) Value

func (op Priority) Value() any

Value returns the value of the enum.

type SpeedUpTransaction

type SpeedUpTransaction struct {
	Context    *TxContext `json:"context" mapstructure:"context"`
	Blockchain string     `json:"blockchain" mapstructure:"blockchain"`
	Priority   *Priority  `json:"priority" mapstructure:"priority"`
}

SpeedUpTransaction represents a SpeedUpTransaction model.

type SubmitTransaction

type SubmitTransaction struct {
	Context    *TxContext `json:"context" mapstructure:"context"`
	BinaryHex  string     `json:"binary_hex" mapstructure:"binary_hex"`
	Blockchain string     `json:"blockchain" mapstructure:"blockchain"`
	Priority   *Priority  `json:"priority" mapstructure:"priority"`
	Retry      bool       `json:"retry" mapstructure:"retry"`
}

SubmitTransaction represents a SubmitTransaction model.

type TransactionCanceled

type TransactionCanceled struct {
	Id      string     `json:"id" mapstructure:"id"`
	Context *TxContext `json:"context" mapstructure:"context"`
}

TransactionCanceled represents a TransactionCanceled model.

type TransactionCompleted

type TransactionCompleted struct {
	Id      string              `json:"id" mapstructure:"id"`
	Details *TransactionDetails `json:"details" mapstructure:"details"`
	Context *TxContext          `json:"context" mapstructure:"context"`
}

TransactionCompleted represents a TransactionCompleted model.

type TransactionDetails

type TransactionDetails struct {
	Status string `json:"status" mapstructure:"status"`
	Hash   string `json:"hash" mapstructure:"hash"`
}

TransactionDetails represents a TransactionDetails model.

type TransactionInterrogated

type TransactionInterrogated struct {
	Id      string              `json:"id" mapstructure:"id"`
	Details *TransactionDetails `json:"details" mapstructure:"details"`
	Context *TxContext          `json:"context" mapstructure:"context"`
}

TransactionInterrogated represents a TransactionInterrogated model.

type TransactionSpeededUp

type TransactionSpeededUp struct {
	Id      string     `json:"id" mapstructure:"id"`
	Context *TxContext `json:"context" mapstructure:"context"`
}

TransactionSpeededUp represents a TransactionSpeededUp model.

type TransactionSubmitted

type TransactionSubmitted struct {
	Id      string     `json:"id" mapstructure:"id"`
	Context *TxContext `json:"context" mapstructure:"context"`
}

TransactionSubmitted represents a TransactionSubmitted model.

type TxContext

type TxContext struct {
	ExternalRef string `json:"external_ref" mapstructure:"external_ref"`
	AccountRef  string `json:"account_ref" mapstructure:"account_ref"`
}

TxContext represents a TxContext model.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL