input

package
v0.0.0-...-cf56fbf Latest Latest
Warning

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

Go to latest
Published: Dec 7, 2021 License: MIT Imports: 7 Imported by: 5

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RunProvider

func RunProvider(version Version, resources map[string]Resource) error

Types

type Credential

type Credential struct {
	SecretId   string                 `yaml:"secret_id"`
	SecretKey  string                 `yaml:"secret_key"`
	AccountId  string                 `yaml:"account_id"`
	ConnectURL string                 `yaml:"connect_url"`
	Extra      map[string]interface{} `yaml:"extra"`
}

type Params

type Params struct {
	Timestamp  int64
	Credential Credential
	Args       map[string]interface{}
}

type ProviderMaster

type ProviderMaster struct {
	PluginPath string
	// contains filtered or unexported fields
}

func (*ProviderMaster) CheckVersion

func (pm *ProviderMaster) CheckVersion(version string) (matched bool, err error)

func (*ProviderMaster) Init

func (pm *ProviderMaster) Init(credential Credential) error

func (*ProviderMaster) Run

func (pm *ProviderMaster) Run(resource string, args map[string]interface{}) (replay Replay, err error)

type Replay

type Replay struct {
	Result []interface{}
	Next   string
	Query  map[string]interface{}
}

type Resource

type Resource interface {
	Call(params Params, replay *Replay) error
}

type Version

type Version interface {
	Check(version string, matched *bool) error
}

Jump to

Keyboard shortcuts

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