Documentation
¶
Index ¶
- type AuthenticationResponse
- type Client
- func (c Client) DeleteFile(fileName string) (err error)
- func (c Client) DeleteMeta(fileName string) (err error)
- func (c Client) GetMeta(fileName string) (meta MetaInfo, err error)
- func (c Client) ListFiles() (f []FileEntry, err error)
- func (c Client) Ping() (err error)
- func (c Client) SetMeta(fileName string, meta MetaInfo) (err error)
- func (c Client) UploadFile(fileName string, reader io.Reader) (ur UploadResponse, err error)
- type FileEntry
- type GateKeeper
- func (gk GateKeeper) IssueClient(bucket string) (Client, error)
- func (gk GateKeeper) IssueUploadToken(bucket ...string) (token UploadToken, err error)
- func (gk GateKeeper) NewClient(bucket string, uploadToken UploadToken) (Client, error)
- func (gk GateKeeper) NewMultiClient(uploadToken UploadToken, buckets ...string) (MultiClient, error)
- type ListResponse
- type MetaInfo
- type MultiClient
- type UploadAuthenticationRequest
- type UploadResponse
- type UploadToken
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AuthenticationResponse ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
func (Client) DeleteFile ¶
func (Client) DeleteMeta ¶
func (Client) UploadFile ¶
type GateKeeper ¶
type GateKeeper struct {
// contains filtered or unexported fields
}
This "class" provides methods for tokens management
func NewGateKeeper ¶
func NewGateKeeper(endpoint string, masterKey string, uploadKey string) (GateKeeper, error)
This function creates new Statika GateKeeper client, it's responsible
func (GateKeeper) IssueClient ¶
func (gk GateKeeper) IssueClient(bucket string) (Client, error)
IssueClient This method gets new upload token from Statika server, and returns a client instance with this token
func (GateKeeper) IssueUploadToken ¶
func (gk GateKeeper) IssueUploadToken(bucket ...string) (token UploadToken, err error)
func (GateKeeper) NewClient ¶
func (gk GateKeeper) NewClient(bucket string, uploadToken UploadToken) (Client, error)
NewClient This method creates new client with existing upload token
func (GateKeeper) NewMultiClient ¶ added in v0.0.14
func (gk GateKeeper) NewMultiClient(uploadToken UploadToken, buckets ...string) (MultiClient, error)
type ListResponse ¶
type MultiClient ¶ added in v0.0.14
type MultiClient struct {
// contains filtered or unexported fields
}
func (MultiClient) Bucket ¶ added in v0.0.14
func (mc MultiClient) Bucket(bucket string) (c Client)
func (MultiClient) Check ¶ added in v0.0.14
func (mc MultiClient) Check(bucket string) (ok bool)
type UploadResponse ¶
type UploadToken ¶
type UploadToken string
Click to show internal directories.
Click to hide internal directories.