file

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: May 24, 2019 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	Prefix string
}

Client used to test with config from file

func New

func New(path string) (*Client, error)

New constructor of EtcdClient

func (*Client) BasePrefix

func (c *Client) BasePrefix() string

BasePrefix return base prefix

func (*Client) Close

func (c *Client) Close() error

Close do nothing

func (*Client) Create

func (c *Client) Create(path string, data []byte) error

Create do nothing

func (*Client) Delete

func (c *Client) Delete(path string) error

Delete delete path

func (*Client) List

func (c *Client) List(path string) ([]string, error)

List list path, return slice of all files

func (*Client) Read

func (c *Client) Read(file string) ([]byte, error)

Read read file data

func (*Client) Update

func (c *Client) Update(path string, data []byte) error

Update do nothing

func (*Client) UpdateWithTTL

func (c *Client) UpdateWithTTL(path string, data []byte, ttl time.Duration) error

UpdateWithTTL update path with data and ttl

Jump to

Keyboard shortcuts

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