Documentation ¶
Index ¶
- type Chunk
- type Client
- func (c *Client) DownloadFile(readToken string, versionID string, filename string, fileID string, ...) error
- func (c *Client) GetContent(URL string) (string, error)
- func (c *Client) GetFileID(content string) (string, error)
- func (c *Client) GetInfo(writeToken string, fileID string, sharedName string) (*Info, error)
- func (c *Client) GetManifest(readToken string, versionID string, fileID string, sharedName string) (string, error)
- func (c *Client) GetRequestToken(content string) (string, error)
- func (c *Client) GetTokens(fileID string, requestToken string, sharedName string) (*Tokens, error)
- func (c *Client) Login()
- type FileVersion
- type Info
- type Tokens
- type WriteCounter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client box client
func (*Client) DownloadFile ¶
func (c *Client) DownloadFile( readToken string, versionID string, filename string, fileID string, sharedName string, resolution string, chunkNum int, threads int, docker bool, ) error
DownloadFile download file
func (*Client) GetManifest ¶
func (c *Client) GetManifest(readToken string, versionID string, fileID string, sharedName string) (string, error)
GetManifest get manifest
func (*Client) GetRequestToken ¶
GetRequestToken request token
type FileVersion ¶
FileVersion file version info
type Info ¶
type Info struct { FileVersion FileVersion `json:"file_version"` AuthenticatedDownloadURL string `json:"authenticated_download_url"` IsDownloadAvailable bool `json:"is_download_available"` Name string `json:"name"` ID string `json:"id"` Etag string `json:"etag"` Extension string `json:"extension"` Size int `json:"size"` Type string `json:"type"` }
Info file info
type WriteCounter ¶
type WriteCounter struct {
Total uint64
}
WriteCounter download size counter
func (WriteCounter) PrintProgress ¶
func (wc WriteCounter) PrintProgress()
PrintProgress prints the progress of a file write
Click to show internal directories.
Click to hide internal directories.