b2_client v0.0.2 B2Client.Backend behaviour

Summary

Types

Callbacks

authenticate(account_id, application_key)

Specs

authenticate(account_id, application_key) ::
  {:ok, B2Client.Authorization.t} |
  {:error, atom}
delete(arg0, arg1)

Specs

delete(B2Client.Authorization.t, B2Client.File.t) ::
  :ok |
  {:error, atom}
delete(arg0, arg1, arg2)

Specs

delete(B2Client.Authorization.t, B2Client.Bucket.t, Path.t) ::
  :ok |
  {:error, atom}
download(arg0, arg1, arg2)

Specs

download(B2Client.Authorization.t, B2Client.Bucket.t, Path.t) ::
  {:ok, file_contents} |
  {:error, atom}
download_head(arg0, arg1, arg2)

Specs

download_head(B2Client.Authorization.t, B2Client.Bucket.t, Path.t) ::
  {:ok, non_neg_integer} |
  {:error, atom}
get_bucket(arg0, arg1)

Specs

get_bucket(B2Client.Authorization.t, String.t) ::
  {:ok, B2Client.Bucket.t} |
  {:error, atom}
get_upload_url(arg0, arg1)

Specs

get_upload_url(B2Client.Authorization.t, B2Client.Bucket.t) ::
  {:ok, B2Client.UploadAuthorization.t} |
  {:error, atom}
list_file_versions(arg0, arg1, file_name)

Specs

list_file_versions(B2Client.Authorization.t, B2Client.Bucket.t, file_name) ::
  {:ok, [B2Client.File.t, ...]} |
  {:error, atom}
upload(arg0, arg1, file_contents, file_name)