Documentation
¶
Index ¶
- Constants
- type Client
- func (c *Client) AddTarget(ctx context.Context, ...) error
- func (c *Client) Backoff(ctx context.Context, attempts int) bool
- func (c *Client) Get(ctx context.Context, device, path string) (*gnmi.GetResponse, error)
- func (c *Client) Set(ctx context.Context, device string, operations ...SetOperation) (*gnmi.SetResponse, error)
- type Device
- type SetOperation
- type SetOperationType
Constants ¶
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct { Devices map[string]*Device // Reuse connection ReuseConnection bool // Maximum number of retries MaxRetries int // Minimum delay between two retries BackoffMinDelay int // Maximum delay between two retries BackoffMaxDelay int // Backoff delay factor BackoffDelayFactor float64 }
func (*Client) Set ¶
func (c *Client) Set(ctx context.Context, device string, operations ...SetOperation) (*gnmi.SetResponse, error)
type SetOperation ¶
type SetOperation struct { Path string Body string Operation SetOperationType }
type SetOperationType ¶
type SetOperationType string
const ( Update SetOperationType = "update" Replace SetOperationType = "replace" Delete SetOperationType = "delete" )
Click to show internal directories.
Click to hide internal directories.