mode

package
v0.9.0 Latest Latest
Warning

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

Go to latest
Published: May 3, 2020 License: MIT Imports: 30 Imported by: 0

Documentation

Overview

Package mode provides entrypoints for all modes that are provided from Evans.

Index

Constants

This section is empty.

Variables

View Source
var DefaultCLIReader io.Reader = os.Stdin

DefaultCLIReader is the reader that is read for inputting request values. It is exported for E2E testing.

Functions

func IsCLIMode

func IsCLIMode(file string) bool

IsCLIMode returns whether Evans is launched as CLI mode or not.

func RunAsCLIMode

func RunAsCLIMode(cfg *config.Config, invoker CLIInvoker) error

RunAsCLIMode starts Evans as CLI mode.

func RunAsREPLMode

func RunAsREPLMode(cfg *config.Config, ui cui.UI, cache *cache.Cache) error

Types

type CLIInvoker added in v0.9.0

type CLIInvoker func(context.Context) error

CLIInvoker represents an invokable function for CLI mode.

func NewCallCLIInvoker added in v0.9.0

func NewCallCLIInvoker(ui cui.UI, methodName, filePath string, headers config.Header, enrich bool, formatType string) (CLIInvoker, error)

NewCallCLIInvoker returns an CLIInvoker implementation for calling RPCs. If filePath is empty, the invoker tries to read input from stdin.

func NewDescribeCLIInvoker added in v0.9.0

func NewDescribeCLIInvoker(ui cui.UI, fqn string) CLIInvoker

func NewListCLIInvoker added in v0.9.0

func NewListCLIInvoker(ui cui.UI, fqn, format string) CLIInvoker

Jump to

Keyboard shortcuts

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