provider

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Aug 24, 2021 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package provider convert the content of ProviderSwitch to configuration

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Switch

type Switch interface {
	// GetConfiguration generate configuration from provider switch
	GetConfiguration(ctx context.Context, client client.Client) (*SwitchConfiguration, error)
}

Switch is a interface of provider switch

type SwitchConfiguration

type SwitchConfiguration struct {
	// which os this provider switch used
	OS string
	// Switch's host
	Host string
	// Certificate of switch
	Cert *certificate.Certificate
	// Which backend to use
	Backend string
	Options map[string]interface{}
}

SwitchConfiguration is configuration of device provider

type TestSwitch

type TestSwitch struct {
}

TestSwitch is a instance of provider switch

func (*TestSwitch) GetConfiguration

func (t *TestSwitch) GetConfiguration(ctx context.Context, client client.Client) (*SwitchConfiguration, error)

GetConfiguration generate configuration from provider switch

Jump to

Keyboard shortcuts

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