Documentation ¶
Index ¶
- func ClientsMap[T any](clients map[string]T) func(string) (T, error)
- func EqualRecord(a, b Record) bool
- type AccountRecord
- func (v *AccountRecord) Copy() *AccountRecord
- func (v *AccountRecord) CopyAsInterface() interface{}
- func (v *AccountRecord) Equal(u *AccountRecord) bool
- func (v *AccountRecord) IsValid() error
- func (v *AccountRecord) MarshalBinary() ([]byte, error)
- func (v *AccountRecord) MarshalJSON() ([]byte, error)
- func (*AccountRecord) Type() RecordType
- func (v *AccountRecord) UnmarshalBinary(data []byte) error
- func (v *AccountRecord) UnmarshalBinaryFrom(rd io.Reader) error
- func (v *AccountRecord) UnmarshalJSON(data []byte) error
- type ChainState
- func (v *ChainState) Copy() *ChainState
- func (v *ChainState) CopyAsInterface() interface{}
- func (v *ChainState) Equal(u *ChainState) bool
- func (v *ChainState) IsValid() error
- func (v *ChainState) MarshalBinary() ([]byte, error)
- func (v *ChainState) MarshalJSON() ([]byte, error)
- func (v *ChainState) UnmarshalBinary(data []byte) error
- func (v *ChainState) UnmarshalBinaryFrom(rd io.Reader) error
- func (v *ChainState) UnmarshalJSON(data []byte) error
- type DatabaseQueryModule
- func (m *DatabaseQueryModule) QuerySet(_ context.Context, account *url.URL, fragment []string, opts QuerySetOptions) (Record, error)
- func (m *DatabaseQueryModule) QueryState(_ context.Context, account *url.URL, fragment []string, opts QueryStateOptions) (Record, error)
- func (m *DatabaseQueryModule) Search(_ context.Context, scope *url.URL, query string, opts SearchOptions) (Record, error)
- type Faucet
- type FaucetModule
- type NetworkMetrics
- func (v *NetworkMetrics) Copy() *NetworkMetrics
- func (v *NetworkMetrics) CopyAsInterface() interface{}
- func (v *NetworkMetrics) Equal(u *NetworkMetrics) bool
- func (v *NetworkMetrics) IsValid() error
- func (v *NetworkMetrics) MarshalBinary() ([]byte, error)
- func (v *NetworkMetrics) UnmarshalBinary(data []byte) error
- func (v *NetworkMetrics) UnmarshalBinaryFrom(rd io.Reader) error
- type NetworkModule
- type NodeDescription
- type NodeMetrics
- func (v *NodeMetrics) Copy() *NodeMetrics
- func (v *NodeMetrics) CopyAsInterface() interface{}
- func (v *NodeMetrics) Equal(u *NodeMetrics) bool
- func (v *NodeMetrics) IsValid() error
- func (v *NodeMetrics) MarshalBinary() ([]byte, error)
- func (v *NodeMetrics) UnmarshalBinary(data []byte) error
- func (v *NodeMetrics) UnmarshalBinaryFrom(rd io.Reader) error
- type NodeModule
- type NodeStatus
- func (v *NodeStatus) Copy() *NodeStatus
- func (v *NodeStatus) CopyAsInterface() interface{}
- func (v *NodeStatus) Equal(u *NodeStatus) bool
- func (v *NodeStatus) IsValid() error
- func (v *NodeStatus) MarshalBinary() ([]byte, error)
- func (v *NodeStatus) UnmarshalBinary(data []byte) error
- func (v *NodeStatus) UnmarshalBinaryFrom(rd io.Reader) error
- type NodeVersion
- func (v *NodeVersion) Copy() *NodeVersion
- func (v *NodeVersion) CopyAsInterface() interface{}
- func (v *NodeVersion) Equal(u *NodeVersion) bool
- func (v *NodeVersion) IsValid() error
- func (v *NodeVersion) MarshalBinary() ([]byte, error)
- func (v *NodeVersion) UnmarshalBinary(data []byte) error
- func (v *NodeVersion) UnmarshalBinaryFrom(rd io.Reader) error
- type QueryModule
- type QuerySetOptions
- func (v *QuerySetOptions) Copy() *QuerySetOptions
- func (v *QuerySetOptions) CopyAsInterface() interface{}
- func (v *QuerySetOptions) Equal(u *QuerySetOptions) bool
- func (v *QuerySetOptions) IsValid() error
- func (v *QuerySetOptions) MarshalBinary() ([]byte, error)
- func (v *QuerySetOptions) UnmarshalBinary(data []byte) error
- func (v *QuerySetOptions) UnmarshalBinaryFrom(rd io.Reader) error
- type QueryStateOptions
- func (v *QueryStateOptions) Copy() *QueryStateOptions
- func (v *QueryStateOptions) CopyAsInterface() interface{}
- func (v *QueryStateOptions) Equal(u *QueryStateOptions) bool
- func (v *QueryStateOptions) IsValid() error
- func (v *QueryStateOptions) MarshalBinary() ([]byte, error)
- func (v *QueryStateOptions) MarshalJSON() ([]byte, error)
- func (v *QueryStateOptions) UnmarshalBinary(data []byte) error
- func (v *QueryStateOptions) UnmarshalBinaryFrom(rd io.Reader) error
- func (v *QueryStateOptions) UnmarshalJSON(data []byte) error
- type Receipt
- func (v *Receipt) Copy() *Receipt
- func (v *Receipt) CopyAsInterface() interface{}
- func (v *Receipt) Equal(u *Receipt) bool
- func (v *Receipt) IsValid() error
- func (v *Receipt) MarshalBinary() ([]byte, error)
- func (v *Receipt) UnmarshalBinary(data []byte) error
- func (v *Receipt) UnmarshalBinaryFrom(rd io.Reader) error
- type Record
- type RecordType
- type RoutedQueryLayer
- func (r *RoutedQueryLayer) QuerySet(ctx context.Context, account *url.URL, fragment []string, opts QuerySetOptions) (Record, error)
- func (r *RoutedQueryLayer) QueryState(ctx context.Context, account *url.URL, fragment []string, ...) (Record, error)
- func (r *RoutedQueryLayer) Search(ctx context.Context, scope *url.URL, query string, opts SearchOptions) (Record, error)
- type RoutedSubmitLayer
- type SearchOptions
- func (v *SearchOptions) Copy() *SearchOptions
- func (v *SearchOptions) CopyAsInterface() interface{}
- func (v *SearchOptions) Equal(u *SearchOptions) bool
- func (v *SearchOptions) IsValid() error
- func (v *SearchOptions) MarshalBinary() ([]byte, error)
- func (v *SearchOptions) UnmarshalBinary(data []byte) error
- func (v *SearchOptions) UnmarshalBinaryFrom(rd io.Reader) error
- type Submission
- func (v *Submission) Copy() *Submission
- func (v *Submission) CopyAsInterface() interface{}
- func (v *Submission) Equal(u *Submission) bool
- func (v *Submission) IsValid() error
- func (v *Submission) MarshalBinary() ([]byte, error)
- func (v *Submission) MarshalJSON() ([]byte, error)
- func (v *Submission) UnmarshalBinary(data []byte) error
- func (v *Submission) UnmarshalBinaryFrom(rd io.Reader) error
- func (v *Submission) UnmarshalJSON(data []byte) error
- type SubmitMode
- type SubmitModule
- type SubmitOptions
- func (v *SubmitOptions) Copy() *SubmitOptions
- func (v *SubmitOptions) CopyAsInterface() interface{}
- func (v *SubmitOptions) Equal(u *SubmitOptions) bool
- func (v *SubmitOptions) IsValid() error
- func (v *SubmitOptions) MarshalBinary() ([]byte, error)
- func (v *SubmitOptions) UnmarshalBinary(data []byte) error
- func (v *SubmitOptions) UnmarshalBinaryFrom(rd io.Reader) error
- type TendermintSubmitModule
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EqualRecord ¶
EqualRecord is used to compare the values of the union
Types ¶
type AccountRecord ¶
type AccountRecord struct { Account protocol.Account `json:"account,omitempty" form:"account" query:"account" validate:"required"` Chains []*ChainState `json:"chains,omitempty" form:"chains" query:"chains" validate:"required"` Proof *Receipt `json:"proof,omitempty" form:"proof" query:"proof" validate:"required"` // contains filtered or unexported fields }
func (*AccountRecord) Copy ¶
func (v *AccountRecord) Copy() *AccountRecord
func (*AccountRecord) CopyAsInterface ¶
func (v *AccountRecord) CopyAsInterface() interface{}
func (*AccountRecord) Equal ¶
func (v *AccountRecord) Equal(u *AccountRecord) bool
func (*AccountRecord) IsValid ¶
func (v *AccountRecord) IsValid() error
func (*AccountRecord) MarshalBinary ¶
func (v *AccountRecord) MarshalBinary() ([]byte, error)
func (*AccountRecord) MarshalJSON ¶
func (v *AccountRecord) MarshalJSON() ([]byte, error)
func (*AccountRecord) Type ¶
func (*AccountRecord) Type() RecordType
func (*AccountRecord) UnmarshalBinary ¶
func (v *AccountRecord) UnmarshalBinary(data []byte) error
func (*AccountRecord) UnmarshalBinaryFrom ¶
func (v *AccountRecord) UnmarshalBinaryFrom(rd io.Reader) error
func (*AccountRecord) UnmarshalJSON ¶
func (v *AccountRecord) UnmarshalJSON(data []byte) error
type ChainState ¶
type ChainState struct { Name string `json:"name,omitempty" form:"name" query:"name" validate:"required"` Type protocol.ChainType `json:"type,omitempty" form:"type" query:"type" validate:"required"` Height uint64 `json:"height,omitempty" form:"height" query:"height" validate:"required"` Roots [][]byte `json:"roots,omitempty" form:"roots" query:"roots" validate:"required"` // contains filtered or unexported fields }
func (*ChainState) Copy ¶
func (v *ChainState) Copy() *ChainState
func (*ChainState) CopyAsInterface ¶
func (v *ChainState) CopyAsInterface() interface{}
func (*ChainState) Equal ¶
func (v *ChainState) Equal(u *ChainState) bool
func (*ChainState) IsValid ¶
func (v *ChainState) IsValid() error
func (*ChainState) MarshalBinary ¶
func (v *ChainState) MarshalBinary() ([]byte, error)
func (*ChainState) MarshalJSON ¶
func (v *ChainState) MarshalJSON() ([]byte, error)
func (*ChainState) UnmarshalBinary ¶
func (v *ChainState) UnmarshalBinary(data []byte) error
func (*ChainState) UnmarshalBinaryFrom ¶
func (v *ChainState) UnmarshalBinaryFrom(rd io.Reader) error
func (*ChainState) UnmarshalJSON ¶
func (v *ChainState) UnmarshalJSON(data []byte) error
type DatabaseQueryModule ¶
func (*DatabaseQueryModule) QuerySet ¶
func (m *DatabaseQueryModule) QuerySet(_ context.Context, account *url.URL, fragment []string, opts QuerySetOptions) (Record, error)
func (*DatabaseQueryModule) QueryState ¶
func (m *DatabaseQueryModule) QueryState(_ context.Context, account *url.URL, fragment []string, opts QueryStateOptions) (Record, error)
type Faucet ¶
type Faucet struct {
SubmitModule
}
func (Faucet) Faucet ¶
func (f Faucet) Faucet(ctx context.Context, account *url.URL, opts SubmitOptions) (*Submission, error)
type FaucetModule ¶
type FaucetModule interface { SubmitModule Faucet(ctx context.Context, account *url.URL, opts SubmitOptions) (*Submission, error) }
type NetworkMetrics ¶
type NetworkMetrics struct { TPS float64 `json:"tps,omitempty" form:"tps" query:"tps" validate:"required"` // contains filtered or unexported fields }
func (*NetworkMetrics) Copy ¶
func (v *NetworkMetrics) Copy() *NetworkMetrics
func (*NetworkMetrics) CopyAsInterface ¶
func (v *NetworkMetrics) CopyAsInterface() interface{}
func (*NetworkMetrics) Equal ¶
func (v *NetworkMetrics) Equal(u *NetworkMetrics) bool
func (*NetworkMetrics) IsValid ¶
func (v *NetworkMetrics) IsValid() error
func (*NetworkMetrics) MarshalBinary ¶
func (v *NetworkMetrics) MarshalBinary() ([]byte, error)
func (*NetworkMetrics) UnmarshalBinary ¶
func (v *NetworkMetrics) UnmarshalBinary(data []byte) error
func (*NetworkMetrics) UnmarshalBinaryFrom ¶
func (v *NetworkMetrics) UnmarshalBinaryFrom(rd io.Reader) error
type NetworkModule ¶
type NetworkModule interface {
Metrics(context.Context) (*NetworkMetrics, error)
}
type NodeDescription ¶
type NodeMetrics ¶
type NodeMetrics struct { TPS float64 `json:"tps,omitempty" form:"tps" query:"tps" validate:"required"` // contains filtered or unexported fields }
func (*NodeMetrics) Copy ¶
func (v *NodeMetrics) Copy() *NodeMetrics
func (*NodeMetrics) CopyAsInterface ¶
func (v *NodeMetrics) CopyAsInterface() interface{}
func (*NodeMetrics) Equal ¶
func (v *NodeMetrics) Equal(u *NodeMetrics) bool
func (*NodeMetrics) IsValid ¶
func (v *NodeMetrics) IsValid() error
func (*NodeMetrics) MarshalBinary ¶
func (v *NodeMetrics) MarshalBinary() ([]byte, error)
func (*NodeMetrics) UnmarshalBinary ¶
func (v *NodeMetrics) UnmarshalBinary(data []byte) error
func (*NodeMetrics) UnmarshalBinaryFrom ¶
func (v *NodeMetrics) UnmarshalBinaryFrom(rd io.Reader) error
type NodeModule ¶
type NodeModule interface { Status(context.Context) (*NodeStatus, error) Version(context.Context) (*NodeVersion, error) Describe(context.Context) (*NodeDescription, error) Metrics(context.Context) (*NodeMetrics, error) }
type NodeStatus ¶
type NodeStatus struct { Ok bool `json:"ok,omitempty" form:"ok" query:"ok" validate:"required"` // contains filtered or unexported fields }
func (*NodeStatus) Copy ¶
func (v *NodeStatus) Copy() *NodeStatus
func (*NodeStatus) CopyAsInterface ¶
func (v *NodeStatus) CopyAsInterface() interface{}
func (*NodeStatus) Equal ¶
func (v *NodeStatus) Equal(u *NodeStatus) bool
func (*NodeStatus) IsValid ¶
func (v *NodeStatus) IsValid() error
func (*NodeStatus) MarshalBinary ¶
func (v *NodeStatus) MarshalBinary() ([]byte, error)
func (*NodeStatus) UnmarshalBinary ¶
func (v *NodeStatus) UnmarshalBinary(data []byte) error
func (*NodeStatus) UnmarshalBinaryFrom ¶
func (v *NodeStatus) UnmarshalBinaryFrom(rd io.Reader) error
type NodeVersion ¶
type NodeVersion struct { Version string `json:"version,omitempty" form:"version" query:"version" validate:"required"` Commit string `json:"commit,omitempty" form:"commit" query:"commit" validate:"required"` VersionIsKnown bool `json:"versionIsKnown,omitempty" form:"versionIsKnown" query:"versionIsKnown" validate:"required"` IsTestNet bool `json:"isTestNet,omitempty" form:"isTestNet" query:"isTestNet" validate:"required"` // contains filtered or unexported fields }
func (*NodeVersion) Copy ¶
func (v *NodeVersion) Copy() *NodeVersion
func (*NodeVersion) CopyAsInterface ¶
func (v *NodeVersion) CopyAsInterface() interface{}
func (*NodeVersion) Equal ¶
func (v *NodeVersion) Equal(u *NodeVersion) bool
func (*NodeVersion) IsValid ¶
func (v *NodeVersion) IsValid() error
func (*NodeVersion) MarshalBinary ¶
func (v *NodeVersion) MarshalBinary() ([]byte, error)
func (*NodeVersion) UnmarshalBinary ¶
func (v *NodeVersion) UnmarshalBinary(data []byte) error
func (*NodeVersion) UnmarshalBinaryFrom ¶
func (v *NodeVersion) UnmarshalBinaryFrom(rd io.Reader) error
type QueryModule ¶
type QueryModule interface { QueryState(ctx context.Context, account *url.URL, fragment []string, opts QueryStateOptions) (Record, error) QuerySet(ctx context.Context, account *url.URL, fragment []string, opts QuerySetOptions) (Record, error) Search(ctx context.Context, scope *url.URL, query string, opts SearchOptions) (Record, error) }
type QuerySetOptions ¶
type QuerySetOptions struct { // Expand requests an expanded response. Expand bool `json:"expand,omitempty" form:"expand" query:"expand"` // Start is the starting index. Start bool `json:"start,omitempty" form:"start" query:"start"` // Count is the number of requested results. Count bool `json:"count,omitempty" form:"count" query:"count"` // contains filtered or unexported fields }
func (*QuerySetOptions) Copy ¶
func (v *QuerySetOptions) Copy() *QuerySetOptions
func (*QuerySetOptions) CopyAsInterface ¶
func (v *QuerySetOptions) CopyAsInterface() interface{}
func (*QuerySetOptions) Equal ¶
func (v *QuerySetOptions) Equal(u *QuerySetOptions) bool
func (*QuerySetOptions) IsValid ¶
func (v *QuerySetOptions) IsValid() error
func (*QuerySetOptions) MarshalBinary ¶
func (v *QuerySetOptions) MarshalBinary() ([]byte, error)
func (*QuerySetOptions) UnmarshalBinary ¶
func (v *QuerySetOptions) UnmarshalBinary(data []byte) error
func (*QuerySetOptions) UnmarshalBinaryFrom ¶
func (v *QuerySetOptions) UnmarshalBinaryFrom(rd io.Reader) error
type QueryStateOptions ¶
type QueryStateOptions struct { // Prove requests a proof. Prove bool `json:"prove,omitempty" form:"prove" query:"prove"` // Expand requests an expanded response. Expand bool `json:"expand,omitempty" form:"expand" query:"expand"` // Wait blocks until the record is available. Wait time.Duration `json:"wait,omitempty" form:"wait" query:"wait"` // Delivered ignores incomplete transactions. Delivered bool `json:"delivered,omitempty" form:"delivered" query:"delivered"` // contains filtered or unexported fields }
func (*QueryStateOptions) Copy ¶
func (v *QueryStateOptions) Copy() *QueryStateOptions
func (*QueryStateOptions) CopyAsInterface ¶
func (v *QueryStateOptions) CopyAsInterface() interface{}
func (*QueryStateOptions) Equal ¶
func (v *QueryStateOptions) Equal(u *QueryStateOptions) bool
func (*QueryStateOptions) IsValid ¶
func (v *QueryStateOptions) IsValid() error
func (*QueryStateOptions) MarshalBinary ¶
func (v *QueryStateOptions) MarshalBinary() ([]byte, error)
func (*QueryStateOptions) MarshalJSON ¶
func (v *QueryStateOptions) MarshalJSON() ([]byte, error)
func (*QueryStateOptions) UnmarshalBinary ¶
func (v *QueryStateOptions) UnmarshalBinary(data []byte) error
func (*QueryStateOptions) UnmarshalBinaryFrom ¶
func (v *QueryStateOptions) UnmarshalBinaryFrom(rd io.Reader) error
func (*QueryStateOptions) UnmarshalJSON ¶
func (v *QueryStateOptions) UnmarshalJSON(data []byte) error
type Receipt ¶
type Receipt struct { LocalBlock uint64 `json:"localBlock,omitempty" form:"localBlock" query:"localBlock" validate:"required"` LocalBlockTime *time.Time `json:"localBlockTime,omitempty" form:"localBlockTime" query:"localBlockTime" validate:"required"` DirectoryBlock uint64 `json:"directoryBlock,omitempty" form:"directoryBlock" query:"directoryBlock" validate:"required"` Proof managed.Receipt `json:"proof,omitempty" form:"proof" query:"proof" validate:"required"` Error *errors2.Error `json:"error,omitempty" form:"error" query:"error" validate:"required"` // contains filtered or unexported fields }
func (*Receipt) CopyAsInterface ¶
func (v *Receipt) CopyAsInterface() interface{}
func (*Receipt) MarshalBinary ¶
func (*Receipt) UnmarshalBinary ¶
type Record ¶
type Record interface { encoding.BinaryValue Type() RecordType }
func NewRecord ¶
func NewRecord(typ RecordType) (Record, error)
NewRecord creates a new Record for the specified RecordType.
func UnmarshalRecord ¶
UnmarshalRecord unmarshals a Record.
func UnmarshalRecordFrom ¶
func UnmarshalRecordFrom(rd io.ReadSeeker) (Record, error)
UnmarshalRecordFrom unmarshals a Record.
func UnmarshalRecordJSON ¶
UnmarshalRecordJson unmarshals a Record.
type RecordType ¶
type RecordType uint64
const RecordTypeAccount RecordType = 1
RecordTypeAccount .
const RecordTypeTransaction RecordType = 2
RecordTypeTransaction .
func RecordTypeByName ¶
func RecordTypeByName(name string) (RecordType, bool)
RecordTypeByName returns the named Record Type.
func UnmarshalRecordType ¶
func UnmarshalRecordType(r io.Reader) (RecordType, error)
UnmarshalRecordType unmarshals the RecordType from the start of a Record.
func (RecordType) GetEnumValue ¶
func (v RecordType) GetEnumValue() uint64
GetEnumValue returns the value of the Record Type
func (RecordType) MarshalJSON ¶
func (v RecordType) MarshalJSON() ([]byte, error)
MarshalJSON marshals the Record Type to JSON as a string.
func (*RecordType) SetEnumValue ¶
func (v *RecordType) SetEnumValue(id uint64) bool
SetEnumValue sets the value. SetEnumValue returns false if the value is invalid.
func (RecordType) String ¶
func (v RecordType) String() string
String returns the name of the Record Type.
func (*RecordType) UnmarshalJSON ¶
func (v *RecordType) UnmarshalJSON(data []byte) error
UnmarshalJSON unmarshals the Record Type from JSON as a string.
type RoutedQueryLayer ¶
type RoutedQueryLayer struct { Clients func(string) (QueryModule, error) Router router }
func (*RoutedQueryLayer) QuerySet ¶
func (r *RoutedQueryLayer) QuerySet(ctx context.Context, account *url.URL, fragment []string, opts QuerySetOptions) (Record, error)
func (*RoutedQueryLayer) QueryState ¶
func (r *RoutedQueryLayer) QueryState(ctx context.Context, account *url.URL, fragment []string, opts QueryStateOptions) (Record, error)
type RoutedSubmitLayer ¶
type RoutedSubmitLayer struct { Clients func(string) (SubmitModule, error) Router router }
func (*RoutedSubmitLayer) Submit ¶
func (r *RoutedSubmitLayer) Submit(ctx context.Context, envelope *protocol.Envelope, opts SubmitOptions) (*Submission, error)
type SearchOptions ¶
type SearchOptions struct { // Kind is the kind of record to search for. Kind string `json:"kind,omitempty" form:"kind" query:"kind" validate:"required"` // contains filtered or unexported fields }
func (*SearchOptions) Copy ¶
func (v *SearchOptions) Copy() *SearchOptions
func (*SearchOptions) CopyAsInterface ¶
func (v *SearchOptions) CopyAsInterface() interface{}
func (*SearchOptions) Equal ¶
func (v *SearchOptions) Equal(u *SearchOptions) bool
func (*SearchOptions) IsValid ¶
func (v *SearchOptions) IsValid() error
func (*SearchOptions) MarshalBinary ¶
func (v *SearchOptions) MarshalBinary() ([]byte, error)
func (*SearchOptions) UnmarshalBinary ¶
func (v *SearchOptions) UnmarshalBinary(data []byte) error
func (*SearchOptions) UnmarshalBinaryFrom ¶
func (v *SearchOptions) UnmarshalBinaryFrom(rd io.Reader) error
type Submission ¶
type Submission struct { TransactionHashes [][32]byte `json:"transactionHashes,omitempty" form:"transactionHashes" query:"transactionHashes" validate:"required"` SignatureHashes [][32]byte `json:"signatureHashes,omitempty" form:"signatureHashes" query:"signatureHashes" validate:"required"` Status []*protocol.TransactionStatus `json:"status,omitempty" form:"status" query:"status" validate:"required"` // contains filtered or unexported fields }
func (*Submission) Copy ¶
func (v *Submission) Copy() *Submission
func (*Submission) CopyAsInterface ¶
func (v *Submission) CopyAsInterface() interface{}
func (*Submission) Equal ¶
func (v *Submission) Equal(u *Submission) bool
func (*Submission) IsValid ¶
func (v *Submission) IsValid() error
func (*Submission) MarshalBinary ¶
func (v *Submission) MarshalBinary() ([]byte, error)
func (*Submission) MarshalJSON ¶
func (v *Submission) MarshalJSON() ([]byte, error)
func (*Submission) UnmarshalBinary ¶
func (v *Submission) UnmarshalBinary(data []byte) error
func (*Submission) UnmarshalBinaryFrom ¶
func (v *Submission) UnmarshalBinaryFrom(rd io.Reader) error
func (*Submission) UnmarshalJSON ¶
func (v *Submission) UnmarshalJSON(data []byte) error
type SubmitMode ¶
type SubmitMode uint64
const SubmitModeAsync SubmitMode = 1
SubmitModeAsync submits the transaction asynchronously.
const SubmitModeCheck SubmitMode = 2
SubmitModeCheck checks the transaction but does not submit it.
const SubmitModeSync SubmitMode = 0
SubmitModeSync submits the transaction and blocks until it is accepted into a block.
func SubmitModeByName ¶
func SubmitModeByName(name string) (SubmitMode, bool)
SubmitModeByName returns the named Submit Mode.
func (SubmitMode) GetEnumValue ¶
func (v SubmitMode) GetEnumValue() uint64
GetEnumValue returns the value of the Submit Mode
func (SubmitMode) MarshalJSON ¶
func (v SubmitMode) MarshalJSON() ([]byte, error)
MarshalJSON marshals the Submit Mode to JSON as a string.
func (*SubmitMode) SetEnumValue ¶
func (v *SubmitMode) SetEnumValue(id uint64) bool
SetEnumValue sets the value. SetEnumValue returns false if the value is invalid.
func (SubmitMode) String ¶
func (v SubmitMode) String() string
String returns the name of the Submit Mode.
func (*SubmitMode) UnmarshalJSON ¶
func (v *SubmitMode) UnmarshalJSON(data []byte) error
UnmarshalJSON unmarshals the Submit Mode from JSON as a string.
type SubmitModule ¶
type SubmitModule interface {
Submit(ctx context.Context, envelope *protocol.Envelope, opts SubmitOptions) (*Submission, error)
}
type SubmitOptions ¶
type SubmitOptions struct { Mode SubmitMode `json:"mode,omitempty" form:"mode" query:"mode" validate:"required"` // contains filtered or unexported fields }
func (*SubmitOptions) Copy ¶
func (v *SubmitOptions) Copy() *SubmitOptions
func (*SubmitOptions) CopyAsInterface ¶
func (v *SubmitOptions) CopyAsInterface() interface{}
func (*SubmitOptions) Equal ¶
func (v *SubmitOptions) Equal(u *SubmitOptions) bool
func (*SubmitOptions) IsValid ¶
func (v *SubmitOptions) IsValid() error
func (*SubmitOptions) MarshalBinary ¶
func (v *SubmitOptions) MarshalBinary() ([]byte, error)
func (*SubmitOptions) UnmarshalBinary ¶
func (v *SubmitOptions) UnmarshalBinary(data []byte) error
func (*SubmitOptions) UnmarshalBinaryFrom ¶
func (v *SubmitOptions) UnmarshalBinaryFrom(rd io.Reader) error
type TendermintSubmitModule ¶
type TendermintSubmitModule struct {
Connection connections.ConnectionContext
}
func (TendermintSubmitModule) Submit ¶
func (m TendermintSubmitModule) Submit(ctx context.Context, envelope *protocol.Envelope, opts SubmitOptions) (*Submission, error)