Documentation ¶
Index ¶
- Constants
- Variables
- func OutputModeNames() []string
- type BlockMessage
- type DeltaWrap
- type DeltasWrap
- type ErrorWrap
- type ModuleWrap
- type OutputMode
- type SessionInitMessage
- type SnapshotDeltaWrap
- type TUI
- func (ui *TUI) Cancel()
- func (ui *TUI) CleanUpTerminal()
- func (ui *TUI) Connected()
- func (ui *TUI) Connecting()
- func (ui *TUI) IncomingMessage(ctx context.Context, resp *pbsubstreamsrpc.Response, testRunner *test.Runner) error
- func (ui *TUI) Init(outputMode string) error
- func (ui *TUI) OnTerminated(f func(error))
- func (ui *TUI) SetRequest(req *pbsubstreamsrpc.Request)
- type UnknownWrap
Constants ¶
View Source
const ( Connecting msg = iota Connected Quit )
Variables ¶
View Source
var ErrInvalidOutputMode = fmt.Errorf("not a valid OutputMode, try [%s]", strings.Join(_OutputModeNames, ", "))
Functions ¶
func OutputModeNames ¶ added in v0.1.0
func OutputModeNames() []string
OutputModeNames returns a list of possible string values of OutputMode.
Types ¶
type BlockMessage ¶
type BlockMessage string
type DeltaWrap ¶ added in v0.0.14
type DeltaWrap struct { Operation string `json:"op"` Ordinal uint64 `json:"ordinal"` Key string `json:"key"` OldValue json.RawMessage `json:"old"` NewValue json.RawMessage `json:"new"` }
type DeltasWrap ¶ added in v0.0.14
type ModuleWrap ¶ added in v0.0.14
type ModuleWrap struct { Module string `json:"@module"` BlockNum uint64 `json:"@block"` Type string `json:"@type"` Data json.RawMessage `json:"@data"` }
type OutputMode ¶ added in v0.1.0
type OutputMode uint
ENUM(TUI, JSON, JSONL)
const ( // OutputModeTUI is a OutputMode of type TUI. OutputModeTUI OutputMode = iota // OutputModeJSON is a OutputMode of type JSON. OutputModeJSON // OutputModeJSONL is a OutputMode of type JSONL. OutputModeJSONL )
func ParseOutputMode ¶ added in v0.1.0
func ParseOutputMode(name string) (OutputMode, error)
ParseOutputMode attempts to convert a string to a OutputMode.
func (OutputMode) IsValid ¶ added in v1.0.2
func (x OutputMode) IsValid() bool
IsValid provides a quick way to determine if the typed value is part of the allowed enumerated values
func (OutputMode) MarshalText ¶ added in v0.1.0
func (x OutputMode) MarshalText() ([]byte, error)
MarshalText implements the text marshaller method.
func (OutputMode) String ¶ added in v0.1.0
func (x OutputMode) String() string
String implements the Stringer interface.
func (*OutputMode) UnmarshalText ¶ added in v0.1.0
func (x *OutputMode) UnmarshalText(text []byte) error
UnmarshalText implements the text unmarshaller method.
type SessionInitMessage ¶ added in v0.1.0
type SessionInitMessage struct {
TraceID string
}
type SnapshotDeltaWrap ¶ added in v0.0.14
type TUI ¶
type TUI struct {
// contains filtered or unexported fields
}
func New ¶
func New(req *pbsubstreamsrpc.Request, pkg *pbsubstreams.Package, outputStreamNames []string) *TUI
func (*TUI) CleanUpTerminal ¶
func (ui *TUI) CleanUpTerminal()
func (*TUI) Connecting ¶
func (ui *TUI) Connecting()
func (*TUI) IncomingMessage ¶
func (*TUI) OnTerminated ¶ added in v0.1.0
func (*TUI) SetRequest ¶
func (ui *TUI) SetRequest(req *pbsubstreamsrpc.Request)
Source Files ¶
Click to show internal directories.
Click to hide internal directories.