sdk

package
v0.0.0-...-a4ebe3d Latest Latest
Warning

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

Go to latest
Published: Jan 7, 2025 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WithPasswordAuth

func WithPasswordAuth(pwd string) *auth.PasswordAuthOption

Types

type Client

type Client struct {
	// contains filtered or unexported fields
}

Client is not thread-safe

func NewClient

func NewClient(host string, port int, options ...option.Optioner) (c *Client, err error)

NewClient creates a new client with the given host and port.

The client will use the given options to configure the client. You can use the sdk.WithPasswordAuth option to set the password for the client.

AS: sdk.NewClient("127.0.0.1", 8080, sdk.WithPasswordAuth("password"))

func NewClientWithPassword

func NewClientWithPassword(host string, port int, password string) (c *Client, err error)

func NewClientWithServer

func NewClientWithServer(host string, port int) (*Client, error)

func (*Client) AdoptCandidateAuth

func (c *Client) AdoptCandidateAuth()

func (*Client) DiscardCandidateAuth

func (c *Client) DiscardCandidateAuth()

func (*Client) Execute

func (c *Client) Execute(request request.Request, response responselib.Response) (err error)

func (*Client) GetAuth

func (c *Client) GetAuth() auth.Auther

func (*Client) GetHost

func (c *Client) GetHost() string

func (*Client) GetPort

func (c *Client) GetPort() int

func (*Client) GetServer

func (c *Client) GetServer() string

func (*Client) SetAuth

func (c *Client) SetAuth(auth auth.Auther)

func (*Client) SetCandidateAuth

func (c *Client) SetCandidateAuth(auth auth.Auther)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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