client

package
v1.0.3 Latest Latest
Warning

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

Go to latest
Published: Feb 12, 2026 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrUnsupportedScheme = errors.New("unsupported scheme")
	ErrClientIsNil       = errors.New("client is nil")
)

Functions

This section is empty.

Types

type Client

type Client interface {
	MakeDir(ctx context.Context, remotePath string) error
	RemoveDir(ctx context.Context, remotePath string) error

	UploadFile(ctx context.Context, remotePath string, localPath string) error
	RemoveFile(ctx context.Context, remotePath string) error

	Remove(ctx context.Context, remotePath string) error
}

func New

func New(address string) (Client, error)

type FtpClient

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

func NewFtpClient

func NewFtpClient(url string) *FtpClient

func (*FtpClient) MakeDir

func (c *FtpClient) MakeDir(ctx context.Context, remotePath string) error

func (*FtpClient) Remove

func (c *FtpClient) Remove(ctx context.Context, remotePath string) error

func (*FtpClient) RemoveDir

func (c *FtpClient) RemoveDir(ctx context.Context, remotePath string) error

func (*FtpClient) RemoveFile

func (c *FtpClient) RemoveFile(ctx context.Context, remotePath string) error

func (*FtpClient) UploadFile

func (c *FtpClient) UploadFile(ctx context.Context, remotePath string, localPath string) error

Jump to

Keyboard shortcuts

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