Documentation
¶
Index ¶
- func Sign(req *http.Request, cred auth.Credential, now time.Time) error
- type APIError
- type COSBucket
- type COSObject
- type Client
- type Driver
- func (d *Driver) GetBuckets(ctx context.Context) ([]schema.Storage, error)
- func (d *Driver) ListObjects(ctx context.Context, buckets map[string]string) ([]schema.BucketResult, error)
- func (d *Driver) SetClientOptions(opts ...Option)
- func (d *Driver) TotalObjects(ctx context.Context, buckets map[string]string) ([]schema.BucketResult, error)
- type HTTPStatusError
- type ListBucketsResponse
- type ListObjectsResponse
- type Option
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type APIError ¶ added in v0.2.2
type Client ¶ added in v0.2.2
type Client struct {
// contains filtered or unexported fields
}
func (*Client) ListBuckets ¶ added in v0.2.2
func (c *Client) ListBuckets(ctx context.Context) (*ListBucketsResponse, error)
func (*Client) ListObjects ¶ added in v0.2.2
type Driver ¶ added in v0.0.9
type Driver struct {
Credential auth.Credential
Client *Client
// contains filtered or unexported fields
}
func NewDriver ¶ added in v0.2.5
func NewDriver(cred auth.Credential, opts ...Option) *Driver
NewDriver creates a COS driver with optional client injections.
func (*Driver) GetBuckets ¶ added in v0.0.9
func (*Driver) ListObjects ¶ added in v0.2.2
func (*Driver) SetClientOptions ¶ added in v0.2.5
SetClientOptions replaces the client options used by lazy client creation.
func (*Driver) TotalObjects ¶ added in v0.2.2
type HTTPStatusError ¶ added in v0.2.2
func (*HTTPStatusError) Error ¶ added in v0.2.2
func (e *HTTPStatusError) Error() string
type ListBucketsResponse ¶ added in v0.2.2
type ListObjectsResponse ¶ added in v0.2.2
type Option ¶ added in v0.2.2
type Option func(*Client)
func WithHTTPClient ¶ added in v0.2.2
func WithRetryPolicy ¶ added in v0.2.2
func WithRetryPolicy(p api.RetryPolicy) Option
func WithServiceEndpoint ¶ added in v0.2.2
Click to show internal directories.
Click to hide internal directories.