Options
All
  • Public
  • Public/Protected
  • All
Menu

Class ShareFolderClient

A client for accessing a share folder instance.

Hierarchy

  • ShareFolderClient

Index

Constructors

constructor

Properties

account

account: Account

The account to use.

host

host: string

Gets the address of the host.

port

port: number

Gets the TCP port of the host.

ssl

ssl: boolean

Gets if SSL should be used or not.

Methods

Private delete

download

  • download(path: string, stream?: WritableStream): Promise<Buffer | undefined>
  • Downloads a file.

    Parameters

    • path: string

      The path to the remote file.

    • Optional stream: WritableStream

    Returns Promise<Buffer | undefined>

    The promise with the downloaded data (if 'stream' is not defined).

Private get

list

  • Lists a directory.

    Parameters

    • Default value path: string = "/"

    Returns Promise<DirectoryEntry[]>

    The list of entries.

Private post

Private put

remove

  • Removes a file or folder.

    Parameters

    • path: string

      The path to the file or folder.

    Returns Promise<DirectoryEntry>

    The promise with the entry of the removed item.

Private request

upload

  • Uploads a file.

    Parameters

    • path: string

      The path to the remote file.

    • data: any

      The data (can be a stream) to upload.

    Returns Promise<DirectoryEntry>

    The directory entry of the file.

Generated using TypeDoc