aliyun

package
v0.0.0-...-930013b Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 15, 2016 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InitFunc

func InitFunc()

Types

type Bucket

type Bucket struct {
	*Client
	// contains filtered or unexported fields
}

Holds OSS bucket informations

func NewBucket

func NewBucket(name string, region string, client *Client) *Bucket

Initialize a new OSS bucket with the given `name`, `region` and `*Client`.

func (*Bucket) Put

func (b *Bucket) Put(object string, content io.Reader, headers map[string]string) error

PUT the given `content` as `object`.

func (*Bucket) PutFile

func (b *Bucket) PutFile(object, filepath string, headers map[string]string) error

PUT the file at `filepath` to `object`.

type Client

type Client struct {
	*http.Client
	// contains filtered or unexported fields
}

Holds OSS client informations

func NewClient

func NewClient(accessKeyId, accessKeySecret string) *Client

Initialize a new client and sets access_key_id and access_key_secret.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL