s3api

package
v0.0.0-...-0b345dd Latest Latest
Warning

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

Go to latest
Published: May 6, 2022 License: Apache-2.0 Imports: 53 Imported by: 0

README

see https://blog.aqwari.net/xml-schema-go/

1. go get aqwari.net/xml/cmd/xsdgen
2. xsdgen -o s3api_xsd_generated.go -pkg s3api AmazonS3.xsd



Documentation

Index

Constants

View Source
const (
	Enabled  ruleStatus = "Enabled"
	Disabled ruleStatus = "Disabled"
)

Supported status types

View Source
const (
	S3TAG_PREFIX = xhttp.AmzObjectTagging + "-"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type AccessControlList

type AccessControlList struct {
	Grant []Grant `xml:"Grant,omitempty"`
}

type AccessControlPolicy

type AccessControlPolicy struct {
	Owner             CanonicalUser     `xml:"Owner"`
	AccessControlList AccessControlList `xml:"AccessControlList"`
}

type Action

type Action string

type AmazonCustomerByEmail

type AmazonCustomerByEmail struct {
	EmailAddress string `xml:"http://s3.amazonaws.com/doc/2006-03-01/ EmailAddress"`
}

type And

type And struct {
	XMLName xml.Name `xml:"And"`
	Prefix  Prefix   `xml:"Prefix,omitempty"`
	Tags    []Tag    `xml:"Tag,omitempty"`
}

And - a tag to combine a prefix and multiple tags for lifecycle configuration rule.

type BucketLoggingStatus

type BucketLoggingStatus struct {
	LoggingEnabled LoggingSettings `xml:"http://s3.amazonaws.com/doc/2006-03-01/ LoggingEnabled,omitempty"`
}

type CanonicalUser

type CanonicalUser struct {
	ID          string `xml:"ID"`
	DisplayName string `xml:"DisplayName,omitempty"`
}

type CompleteMultipartUpload

type CompleteMultipartUpload struct {
	Parts []CompletedPart `xml:"Part"`
}

type CompleteMultipartUploadResult

type CompleteMultipartUploadResult struct {
	XMLName xml.Name `xml:"http://s3.amazonaws.com/doc/2006-03-01/ CompleteMultipartUploadResult"`
	s3.CompleteMultipartUploadOutput
}

type CompletedPart

type CompletedPart struct {
	ETag       string
	PartNumber int
}

type CopyObject

type CopyObject struct {
	SourceBucket                string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ SourceBucket"`
	SourceKey                   string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ SourceKey"`
	DestinationBucket           string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ DestinationBucket"`
	DestinationKey              string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ DestinationKey"`
	MetadataDirective           MetadataDirective `xml:"http://s3.amazonaws.com/doc/2006-03-01/ MetadataDirective,omitempty"`
	Metadata                    []MetadataEntry   `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Metadata,omitempty"`
	AccessControlList           AccessControlList `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AccessControlList,omitempty"`
	CopySourceIfModifiedSince   time.Time         `xml:"http://s3.amazonaws.com/doc/2006-03-01/ CopySourceIfModifiedSince,omitempty"`
	CopySourceIfUnmodifiedSince time.Time         `xml:"http://s3.amazonaws.com/doc/2006-03-01/ CopySourceIfUnmodifiedSince,omitempty"`
	CopySourceIfMatch           []string          `xml:"http://s3.amazonaws.com/doc/2006-03-01/ CopySourceIfMatch,omitempty"`
	CopySourceIfNoneMatch       []string          `xml:"http://s3.amazonaws.com/doc/2006-03-01/ CopySourceIfNoneMatch,omitempty"`
	StorageClass                StorageClass      `xml:"http://s3.amazonaws.com/doc/2006-03-01/ StorageClass,omitempty"`
	AWSAccessKeyId              string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp                   time.Time         `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature                   string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential                  string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
}

func (*CopyObject) MarshalXML

func (t *CopyObject) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*CopyObject) UnmarshalXML

func (t *CopyObject) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type CopyObjectResponse

type CopyObjectResponse struct {
	CopyObjectResult CopyObjectResult `xml:"http://s3.amazonaws.com/doc/2006-03-01/ CopyObjectResult"`
}

type CopyObjectResult

type CopyObjectResult struct {
	LastModified time.Time `xml:"http://s3.amazonaws.com/doc/2006-03-01/ LastModified"`
	ETag         string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ETag"`
}

func (*CopyObjectResult) MarshalXML

func (t *CopyObjectResult) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*CopyObjectResult) UnmarshalXML

func (t *CopyObjectResult) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type CopyPartResult

type CopyPartResult struct {
	LastModified time.Time `xml:"LastModified"`
	ETag         string    `xml:"ETag"`
}

type CreateBucket

type CreateBucket struct {
	Bucket            string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	AccessControlList AccessControlList `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AccessControlList,omitempty"`
	AWSAccessKeyId    string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp         time.Time         `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature         string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
}

func (*CreateBucket) MarshalXML

func (t *CreateBucket) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*CreateBucket) UnmarshalXML

func (t *CreateBucket) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type CreateBucketConfiguration

type CreateBucketConfiguration struct {
	LocationConstraint string `xml:"http://s3.amazonaws.com/doc/2006-03-01/ LocationConstraint"`
}

type CreateBucketResponse

type CreateBucketResponse struct {
	CreateBucketReturn CreateBucketResult `xml:"http://s3.amazonaws.com/doc/2006-03-01/ CreateBucketReturn"`
}

type CreateBucketResult

type CreateBucketResult struct {
	BucketName string `xml:"http://s3.amazonaws.com/doc/2006-03-01/ BucketName"`
}

type Credential

type Credential struct {
	AccessKey string
	SecretKey string
}

type DeleteBucket

type DeleteBucket struct {
	Bucket         string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	AWSAccessKeyId string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp      time.Time `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature      string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential     string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
}

func (*DeleteBucket) MarshalXML

func (t *DeleteBucket) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*DeleteBucket) UnmarshalXML

func (t *DeleteBucket) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type DeleteBucketResponse

type DeleteBucketResponse struct {
	DeleteBucketResponse Status `xml:"http://s3.amazonaws.com/doc/2006-03-01/ DeleteBucketResponse"`
}

type DeleteError

type DeleteError struct {
	Code    string
	Message string
	Key     string
}

DeleteError structure.

type DeleteMarkerEntry

type DeleteMarkerEntry struct {
	Key          string        `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Key"`
	VersionId    string        `xml:"http://s3.amazonaws.com/doc/2006-03-01/ VersionId"`
	IsLatest     bool          `xml:"http://s3.amazonaws.com/doc/2006-03-01/ IsLatest"`
	LastModified time.Time     `xml:"http://s3.amazonaws.com/doc/2006-03-01/ LastModified"`
	Owner        CanonicalUser `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Owner,omitempty"`
}

func (*DeleteMarkerEntry) MarshalXML

func (t *DeleteMarkerEntry) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*DeleteMarkerEntry) UnmarshalXML

func (t *DeleteMarkerEntry) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type DeleteObject

type DeleteObject struct {
	Bucket         string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	Key            string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Key"`
	AWSAccessKeyId string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp      time.Time `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature      string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential     string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
}

func (*DeleteObject) MarshalXML

func (t *DeleteObject) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*DeleteObject) UnmarshalXML

func (t *DeleteObject) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type DeleteObjectResponse

type DeleteObjectResponse struct {
	DeleteObjectResponse Status `xml:"http://s3.amazonaws.com/doc/2006-03-01/ DeleteObjectResponse"`
}

type DeleteObjectsRequest

type DeleteObjectsRequest struct {
	// Element to enable quiet mode for the request
	Quiet bool
	// List of objects to be deleted
	Objects []ObjectIdentifier `xml:"Object"`
}

DeleteObjectsRequest - xml carrying the object key names which needs to be deleted.

type DeleteObjectsResponse

type DeleteObjectsResponse struct {
	XMLName xml.Name `xml:"http://s3.amazonaws.com/doc/2006-03-01/ DeleteResult" json:"-"`

	// Collection of all deleted objects
	DeletedObjects []ObjectIdentifier `xml:"Deleted,omitempty"`

	// Collection of errors deleting certain objects.
	Errors []DeleteError `xml:"Error,omitempty"`
}

DeleteObjectsResponse container for multiple object deletes.

type Expiration

type Expiration struct {
	XMLName      xml.Name           `xml:"Expiration"`
	Days         int                `xml:"Days,omitempty"`
	Date         ExpirationDate     `xml:"Date,omitempty"`
	DeleteMarker ExpireDeleteMarker `xml:"ExpiredObjectDeleteMarker"`
	// contains filtered or unexported fields
}

Expiration - expiration actions for a rule in lifecycle configuration.

func (Expiration) MarshalXML

func (e Expiration) MarshalXML(enc *xml.Encoder, startElement xml.StartElement) error

MarshalXML encodes expiration field into an XML form.

type ExpirationDate

type ExpirationDate struct {
	time.Time
}

ExpirationDate is a embedded type containing time.Time to unmarshal Date in Expiration

func (ExpirationDate) MarshalXML

func (eDate ExpirationDate) MarshalXML(e *xml.Encoder, startElement xml.StartElement) error

MarshalXML encodes expiration date if it is non-zero and encodes empty string otherwise

type ExpireDeleteMarker

type ExpireDeleteMarker struct {
	// contains filtered or unexported fields
}

ExpireDeleteMarker represents value of ExpiredObjectDeleteMarker field in Expiration XML element.

func (ExpireDeleteMarker) MarshalXML

func (b ExpireDeleteMarker) MarshalXML(e *xml.Encoder, startElement xml.StartElement) error

MarshalXML encodes delete marker boolean into an XML form.

type Filter

type Filter struct {
	XMLName xml.Name `xml:"Filter"`

	Prefix Prefix

	And And

	Tag Tag
	// contains filtered or unexported fields
}

Filter - a filter for a lifecycle configuration Rule.

func (Filter) MarshalXML

func (f Filter) MarshalXML(e *xml.Encoder, start xml.StartElement) error

MarshalXML encodes Filter field into an XML form.

type GetBucketAccessControlPolicy

type GetBucketAccessControlPolicy struct {
	Bucket         string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	AWSAccessKeyId string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp      time.Time `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature      string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential     string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
}

func (*GetBucketAccessControlPolicy) MarshalXML

func (t *GetBucketAccessControlPolicy) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*GetBucketAccessControlPolicy) UnmarshalXML

func (t *GetBucketAccessControlPolicy) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type GetBucketAccessControlPolicyResponse

type GetBucketAccessControlPolicyResponse struct {
	GetBucketAccessControlPolicyResponse AccessControlPolicy `xml:"http://s3.amazonaws.com/doc/2006-03-01/ GetBucketAccessControlPolicyResponse"`
}

type GetBucketLoggingStatus

type GetBucketLoggingStatus struct {
	Bucket         string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	AWSAccessKeyId string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp      time.Time `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature      string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential     string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
}

func (*GetBucketLoggingStatus) MarshalXML

func (t *GetBucketLoggingStatus) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*GetBucketLoggingStatus) UnmarshalXML

func (t *GetBucketLoggingStatus) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type GetBucketLoggingStatusResponse

type GetBucketLoggingStatusResponse struct {
	GetBucketLoggingStatusResponse BucketLoggingStatus `xml:"http://s3.amazonaws.com/doc/2006-03-01/ GetBucketLoggingStatusResponse"`
}

type GetObject

type GetObject struct {
	Bucket         string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	Key            string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Key"`
	GetMetadata    bool      `xml:"http://s3.amazonaws.com/doc/2006-03-01/ GetMetadata"`
	GetData        bool      `xml:"http://s3.amazonaws.com/doc/2006-03-01/ GetData"`
	InlineData     bool      `xml:"http://s3.amazonaws.com/doc/2006-03-01/ InlineData"`
	AWSAccessKeyId string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp      time.Time `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature      string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential     string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
}

func (*GetObject) MarshalXML

func (t *GetObject) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*GetObject) UnmarshalXML

func (t *GetObject) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type GetObjectAccessControlPolicy

type GetObjectAccessControlPolicy struct {
	Bucket         string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	Key            string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Key"`
	AWSAccessKeyId string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp      time.Time `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature      string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential     string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
}

func (*GetObjectAccessControlPolicy) MarshalXML

func (t *GetObjectAccessControlPolicy) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*GetObjectAccessControlPolicy) UnmarshalXML

func (t *GetObjectAccessControlPolicy) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type GetObjectAccessControlPolicyResponse

type GetObjectAccessControlPolicyResponse struct {
	GetObjectAccessControlPolicyResponse AccessControlPolicy `xml:"http://s3.amazonaws.com/doc/2006-03-01/ GetObjectAccessControlPolicyResponse"`
}

type GetObjectExtended

type GetObjectExtended struct {
	Bucket                                 string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	Key                                    string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Key"`
	GetMetadata                            bool      `xml:"http://s3.amazonaws.com/doc/2006-03-01/ GetMetadata"`
	GetData                                bool      `xml:"http://s3.amazonaws.com/doc/2006-03-01/ GetData"`
	InlineData                             bool      `xml:"http://s3.amazonaws.com/doc/2006-03-01/ InlineData"`
	ByteRangeStart                         int64     `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ByteRangeStart,omitempty"`
	ByteRangeEnd                           int64     `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ByteRangeEnd,omitempty"`
	IfModifiedSince                        time.Time `xml:"http://s3.amazonaws.com/doc/2006-03-01/ IfModifiedSince,omitempty"`
	IfUnmodifiedSince                      time.Time `xml:"http://s3.amazonaws.com/doc/2006-03-01/ IfUnmodifiedSince,omitempty"`
	IfMatch                                []string  `xml:"http://s3.amazonaws.com/doc/2006-03-01/ IfMatch,omitempty"`
	IfNoneMatch                            []string  `xml:"http://s3.amazonaws.com/doc/2006-03-01/ IfNoneMatch,omitempty"`
	ReturnCompleteObjectOnConditionFailure bool      `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ReturnCompleteObjectOnConditionFailure,omitempty"`
	AWSAccessKeyId                         string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp                              time.Time `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature                              string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential                             string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
}

func (*GetObjectExtended) MarshalXML

func (t *GetObjectExtended) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*GetObjectExtended) UnmarshalXML

func (t *GetObjectExtended) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type GetObjectExtendedResponse

type GetObjectExtendedResponse struct {
	GetObjectResponse GetObjectResult `xml:"http://s3.amazonaws.com/doc/2006-03-01/ GetObjectResponse"`
}

type GetObjectResponse

type GetObjectResponse struct {
	GetObjectResponse GetObjectResult `xml:"http://s3.amazonaws.com/doc/2006-03-01/ GetObjectResponse"`
}

type GetObjectResult

type GetObjectResult struct {
	Metadata     []MetadataEntry `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Metadata,omitempty"`
	Data         []byte          `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Data,omitempty"`
	LastModified time.Time       `xml:"http://s3.amazonaws.com/doc/2006-03-01/ LastModified"`
	ETag         string          `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ETag"`
	Status       Status          `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Status"`
}

func (*GetObjectResult) MarshalXML

func (t *GetObjectResult) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*GetObjectResult) UnmarshalXML

func (t *GetObjectResult) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type Grant

type Grant struct {
	Grantee    Grantee    `xml:"Grantee"`
	Permission Permission `xml:"Permission"`
}

type Grantee

type Grantee struct {
	XMLNS       string `xml:"xmlns:xsi,attr"`
	XMLXSI      string `xml:"xsi:type,attr"`
	Type        string `xml:"Type"`
	ID          string `xml:"ID,omitempty"`
	DisplayName string `xml:"DisplayName,omitempty"`
	URI         string `xml:"URI,omitempty"`
}

type Group

type Group struct {
	URI string `xml:"http://s3.amazonaws.com/doc/2006-03-01/ URI"`
}

type Iam

type Iam interface {
	Check(f http.HandlerFunc, actions ...Action) http.HandlerFunc
}

type Identity

type Identity struct {
	Name        string
	Credentials []*Credential
	Actions     []Action
}

type IdentityAccessManagement

type IdentityAccessManagement struct {
	// contains filtered or unexported fields
}

func NewIdentityAccessManagement

func NewIdentityAccessManagement(option *S3ApiServerOption) *IdentityAccessManagement

func (*IdentityAccessManagement) Auth

type InitiateMultipartUploadResult

type InitiateMultipartUploadResult struct {
	XMLName xml.Name `xml:"http://s3.amazonaws.com/doc/2006-03-01/ InitiateMultipartUploadResult"`
	s3.CreateMultipartUploadOutput
}

type Lifecycle

type Lifecycle struct {
	XMLName xml.Name `xml:"LifecycleConfiguration"`
	Rules   []Rule   `xml:"Rule"`
}

Lifecycle - Configuration for bucket lifecycle.

type ListAllMyBuckets

type ListAllMyBuckets struct {
	AWSAccessKeyId string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp      time.Time `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature      string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
}

func (*ListAllMyBuckets) MarshalXML

func (t *ListAllMyBuckets) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*ListAllMyBuckets) UnmarshalXML

func (t *ListAllMyBuckets) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type ListAllMyBucketsEntry

type ListAllMyBucketsEntry struct {
	Name         string    `xml:"Name"`
	CreationDate time.Time `xml:"CreationDate"`
}

func (*ListAllMyBucketsEntry) MarshalXML

func (t *ListAllMyBucketsEntry) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*ListAllMyBucketsEntry) UnmarshalXML

func (t *ListAllMyBucketsEntry) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type ListAllMyBucketsList

type ListAllMyBucketsList struct {
	Bucket []ListAllMyBucketsEntry `xml:"Bucket,omitempty"`
}

type ListAllMyBucketsResponse

type ListAllMyBucketsResponse struct {
	ListAllMyBucketsResponse ListAllMyBucketsResult `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ListAllMyBucketsResponse"`
}

type ListAllMyBucketsResult

type ListAllMyBucketsResult struct {
	XMLName xml.Name `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ListAllMyBucketsResult"`
	Owner   *s3.Owner
	Buckets []*s3.Bucket `xml:"Buckets>Bucket"`
}

type ListBucket

type ListBucket struct {
	Bucket         string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	Prefix         string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Prefix,omitempty"`
	Marker         string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Marker,omitempty"`
	MaxKeys        int       `xml:"http://s3.amazonaws.com/doc/2006-03-01/ MaxKeys,omitempty"`
	Delimiter      string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Delimiter,omitempty"`
	AWSAccessKeyId string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp      time.Time `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature      string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential     string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
}

func (*ListBucket) MarshalXML

func (t *ListBucket) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*ListBucket) UnmarshalXML

func (t *ListBucket) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type ListBucketResponse

type ListBucketResponse struct {
	ListBucketResponse ListBucketResult `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ListBucketResponse"`
}

type ListBucketResult

type ListBucketResult struct {
	XMLName        xml.Name        `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ListBucketResult"`
	Metadata       []MetadataEntry `xml:"Metadata,omitempty"`
	Name           string          `xml:"Name"`
	Prefix         string          `xml:"Prefix"`
	Marker         string          `xml:"Marker"`
	NextMarker     string          `xml:"NextMarker,omitempty"`
	MaxKeys        int             `xml:"MaxKeys"`
	Delimiter      string          `xml:"Delimiter,omitempty"`
	IsTruncated    bool            `xml:"IsTruncated"`
	Contents       []ListEntry     `xml:"Contents,omitempty"`
	CommonPrefixes []PrefixEntry   `xml:"CommonPrefixes,omitempty"`
}

type ListBucketResultV2

type ListBucketResultV2 struct {
	XMLName               xml.Name      `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ListBucketResult"`
	Name                  string        `xml:"Name"`
	Prefix                string        `xml:"Prefix"`
	MaxKeys               int           `xml:"MaxKeys"`
	Delimiter             string        `xml:"Delimiter,omitempty"`
	IsTruncated           bool          `xml:"IsTruncated"`
	Contents              []ListEntry   `xml:"Contents,omitempty"`
	CommonPrefixes        []PrefixEntry `xml:"CommonPrefixes,omitempty"`
	ContinuationToken     string        `xml:"ContinuationToken,omitempty"`
	NextContinuationToken string        `xml:"NextContinuationToken,omitempty"`
	KeyCount              int           `xml:"KeyCount"`
	StartAfter            string        `xml:"StartAfter,omitempty"`
}

type ListEntry

type ListEntry struct {
	Key          string        `xml:"Key"`
	LastModified time.Time     `xml:"LastModified"`
	ETag         string        `xml:"ETag"`
	Size         int64         `xml:"Size"`
	Owner        CanonicalUser `xml:"Owner,omitempty"`
	StorageClass StorageClass  `xml:"StorageClass"`
}

func (*ListEntry) MarshalXML

func (t *ListEntry) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*ListEntry) UnmarshalXML

func (t *ListEntry) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type ListMultipartUploadsResult

type ListMultipartUploadsResult struct {
	XMLName xml.Name `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ListMultipartUploadsResult"`

	// copied from s3.ListMultipartUploadsOutput, the Uploads is not converting to <Upload></Upload>
	Bucket             *string               `type:"string"`
	Delimiter          *string               `type:"string"`
	EncodingType       *string               `type:"string" enum:"EncodingType"`
	IsTruncated        *bool                 `type:"boolean"`
	KeyMarker          *string               `type:"string"`
	MaxUploads         *int64                `type:"integer"`
	NextKeyMarker      *string               `type:"string"`
	NextUploadIdMarker *string               `type:"string"`
	Prefix             *string               `type:"string"`
	UploadIdMarker     *string               `type:"string"`
	Upload             []*s3.MultipartUpload `locationName:"Upload" type:"list" flattened:"true"`
}

type ListPartsResult

type ListPartsResult struct {
	XMLName xml.Name `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ListPartsResult"`

	// copied from s3.ListPartsOutput, the Parts is not converting to <Part></Part>
	Bucket               *string    `type:"string"`
	IsTruncated          *bool      `type:"boolean"`
	Key                  *string    `min:"1" type:"string"`
	MaxParts             *int64     `type:"integer"`
	NextPartNumberMarker *int64     `type:"integer"`
	PartNumberMarker     *int64     `type:"integer"`
	Part                 []*s3.Part `locationName:"Part" type:"list" flattened:"true"`
	StorageClass         *string    `type:"string" enum:"StorageClass"`
	UploadId             *string    `type:"string"`
}

type ListVersionsResponse

type ListVersionsResponse struct {
	ListVersionsResponse ListVersionsResult `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ListVersionsResponse"`
}

type ListVersionsResult

type ListVersionsResult struct {
	Metadata            []MetadataEntry   `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Metadata,omitempty"`
	Name                string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Name"`
	Prefix              string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Prefix"`
	KeyMarker           string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ KeyMarker"`
	VersionIdMarker     string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ VersionIdMarker"`
	NextKeyMarker       string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ NextKeyMarker,omitempty"`
	NextVersionIdMarker string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ NextVersionIdMarker,omitempty"`
	MaxKeys             int               `xml:"http://s3.amazonaws.com/doc/2006-03-01/ MaxKeys"`
	Delimiter           string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Delimiter,omitempty"`
	IsTruncated         bool              `xml:"http://s3.amazonaws.com/doc/2006-03-01/ IsTruncated"`
	Version             VersionEntry      `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Version"`
	DeleteMarker        DeleteMarkerEntry `xml:"http://s3.amazonaws.com/doc/2006-03-01/ DeleteMarker"`
	CommonPrefixes      []PrefixEntry     `xml:"http://s3.amazonaws.com/doc/2006-03-01/ CommonPrefixes,omitempty"`
}

type LocationConstraint

type LocationConstraint struct {
	LocationConstraint string `xml:"http://s3.amazonaws.com/doc/2006-03-01/ LocationConstraint"`
}

type LoggingSettings

type LoggingSettings struct {
	TargetBucket string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ TargetBucket"`
	TargetPrefix string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ TargetPrefix"`
	TargetGrants AccessControlList `xml:"http://s3.amazonaws.com/doc/2006-03-01/ TargetGrants,omitempty"`
}

type MetadataDirective

type MetadataDirective string

May be one of COPY, REPLACE

type MetadataEntry

type MetadataEntry struct {
	Name  string `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Name"`
	Value string `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Value"`
}

type MfaDeleteStatus

type MfaDeleteStatus string

May be one of Enabled, Disabled

type NotificationConfiguration

type NotificationConfiguration struct {
	TopicConfiguration []TopicConfiguration `xml:"http://s3.amazonaws.com/doc/2006-03-01/ TopicConfiguration,omitempty"`
}

type ObjectIdentifier

type ObjectIdentifier struct {
	ObjectName string `xml:"Key"`
}

/ ObjectIdentifier carries key name for the object to delete.

type Payer

type Payer string

May be one of BucketOwner, Requester

type Permission

type Permission string

May be one of READ, WRITE, READ_ACP, WRITE_ACP, FULL_CONTROL

type PostResponse

type PostResponse struct {
	Location string `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Location"`
	Bucket   string `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	Key      string `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Key"`
	ETag     string `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ETag"`
}

type Prefix

type Prefix struct {
	// contains filtered or unexported fields
}

Prefix holds the prefix xml tag in <Rule> and <Filter>

func (Prefix) MarshalXML

func (p Prefix) MarshalXML(e *xml.Encoder, startElement xml.StartElement) error

MarshalXML encodes Prefix field into an XML form.

type PrefixEntry

type PrefixEntry struct {
	Prefix string `xml:"Prefix"`
}

type PutObject

type PutObject struct {
	Bucket            string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	Key               string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Key"`
	Metadata          []MetadataEntry   `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Metadata,omitempty"`
	ContentLength     int64             `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ContentLength"`
	AccessControlList AccessControlList `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AccessControlList,omitempty"`
	StorageClass      StorageClass      `xml:"http://s3.amazonaws.com/doc/2006-03-01/ StorageClass,omitempty"`
	AWSAccessKeyId    string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp         time.Time         `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature         string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential        string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
}

func (*PutObject) MarshalXML

func (t *PutObject) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*PutObject) UnmarshalXML

func (t *PutObject) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type PutObjectInline

type PutObjectInline struct {
	Bucket            string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	Key               string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Key"`
	Metadata          []MetadataEntry   `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Metadata,omitempty"`
	Data              []byte            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Data"`
	ContentLength     int64             `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ContentLength"`
	AccessControlList AccessControlList `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AccessControlList,omitempty"`
	StorageClass      StorageClass      `xml:"http://s3.amazonaws.com/doc/2006-03-01/ StorageClass,omitempty"`
	AWSAccessKeyId    string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp         time.Time         `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature         string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential        string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
}

func (*PutObjectInline) MarshalXML

func (t *PutObjectInline) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*PutObjectInline) UnmarshalXML

func (t *PutObjectInline) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type PutObjectInlineResponse

type PutObjectInlineResponse struct {
	PutObjectInlineResponse PutObjectResult `xml:"http://s3.amazonaws.com/doc/2006-03-01/ PutObjectInlineResponse"`
}

type PutObjectResponse

type PutObjectResponse struct {
	PutObjectResponse PutObjectResult `xml:"http://s3.amazonaws.com/doc/2006-03-01/ PutObjectResponse"`
}

type PutObjectResult

type PutObjectResult struct {
	ETag         string    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ETag"`
	LastModified time.Time `xml:"http://s3.amazonaws.com/doc/2006-03-01/ LastModified"`
}

func (*PutObjectResult) MarshalXML

func (t *PutObjectResult) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*PutObjectResult) UnmarshalXML

func (t *PutObjectResult) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type RequestPaymentConfiguration

type RequestPaymentConfiguration struct {
	Payer Payer `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Payer"`
}

type Result

type Result struct {
	Status Status `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Status"`
}

type Rule

type Rule struct {
	XMLName    xml.Name   `xml:"Rule"`
	ID         string     `xml:"ID,omitempty"`
	Status     ruleStatus `xml:"Status"`
	Filter     Filter     `xml:"Filter,omitempty"`
	Prefix     Prefix     `xml:"Prefix,omitempty"`
	Expiration Expiration `xml:"Expiration,omitempty"`
	Transition Transition `xml:"Transition,omitempty"`
}

Rule - a rule for lifecycle configuration.

type S3ApiServer

type S3ApiServer struct {
	// contains filtered or unexported fields
}

func NewS3ApiServer

func NewS3ApiServer(router *mux.Router, option *S3ApiServerOption) (s3ApiServer *S3ApiServer, err error)

func (*S3ApiServer) AbortMultipartUploadHandler

func (s3a *S3ApiServer) AbortMultipartUploadHandler(w http.ResponseWriter, r *http.Request)

AbortMultipartUploadHandler - Aborts multipart upload.

func (*S3ApiServer) AdjustedUrl

func (s3a *S3ApiServer) AdjustedUrl(location *filer_pb.Location) string

func (*S3ApiServer) CompleteMultipartUploadHandler

func (s3a *S3ApiServer) CompleteMultipartUploadHandler(w http.ResponseWriter, r *http.Request)

CompleteMultipartUploadHandler - Completes multipart upload.

func (*S3ApiServer) CopyObjectHandler

func (s3a *S3ApiServer) CopyObjectHandler(w http.ResponseWriter, r *http.Request)

func (*S3ApiServer) CopyObjectPartHandler

func (s3a *S3ApiServer) CopyObjectPartHandler(w http.ResponseWriter, r *http.Request)

func (*S3ApiServer) DeleteBucketCorsHandler

func (s3a *S3ApiServer) DeleteBucketCorsHandler(w http.ResponseWriter, r *http.Request)

DeleteBucketCorsHandler Delete bucket CORS https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketCors.html

func (*S3ApiServer) DeleteBucketHandler

func (s3a *S3ApiServer) DeleteBucketHandler(w http.ResponseWriter, r *http.Request)

func (*S3ApiServer) DeleteBucketLifecycleHandler

func (s3a *S3ApiServer) DeleteBucketLifecycleHandler(w http.ResponseWriter, r *http.Request)

DeleteBucketMetricsConfiguration Delete Bucket Lifecycle https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketLifecycle.html

func (*S3ApiServer) DeleteBucketPolicyHandler

func (s3a *S3ApiServer) DeleteBucketPolicyHandler(w http.ResponseWriter, r *http.Request)

DeleteBucketPolicyHandler Delete bucket Policy https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteBucketPolicy.html

func (*S3ApiServer) DeleteMultipleObjectsHandler

func (s3a *S3ApiServer) DeleteMultipleObjectsHandler(w http.ResponseWriter, r *http.Request)

DeleteMultipleObjectsHandler - Delete multiple objects

func (*S3ApiServer) DeleteObjectHandler

func (s3a *S3ApiServer) DeleteObjectHandler(w http.ResponseWriter, r *http.Request)

func (*S3ApiServer) DeleteObjectTaggingHandler

func (s3a *S3ApiServer) DeleteObjectTaggingHandler(w http.ResponseWriter, r *http.Request)

DeleteObjectTaggingHandler Delete object tagging API reference: https://docs.aws.amazon.com/AmazonS3/latest/API/API_DeleteObjectTagging.html

func (*S3ApiServer) GetBucketAclHandler

func (s3a *S3ApiServer) GetBucketAclHandler(w http.ResponseWriter, r *http.Request)

GetBucketAclHandler Get Bucket ACL https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketAcl.html

func (*S3ApiServer) GetBucketCorsHandler

func (s3a *S3ApiServer) GetBucketCorsHandler(w http.ResponseWriter, r *http.Request)

GetBucketCorsHandler Get bucket CORS https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketCors.html

func (*S3ApiServer) GetBucketLifecycleConfigurationHandler

func (s3a *S3ApiServer) GetBucketLifecycleConfigurationHandler(w http.ResponseWriter, r *http.Request)

GetBucketLifecycleConfigurationHandler Get Bucket Lifecycle configuration https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketLifecycleConfiguration.html

func (*S3ApiServer) GetBucketLocationHandler

func (s3a *S3ApiServer) GetBucketLocationHandler(w http.ResponseWriter, r *http.Request)

GetBucketLocationHandler Get bucket location https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketLocation.html

func (*S3ApiServer) GetBucketPolicyHandler

func (s3a *S3ApiServer) GetBucketPolicyHandler(w http.ResponseWriter, r *http.Request)

GetBucketPolicyHandler Get bucket Policy https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketPolicy.html

func (*S3ApiServer) GetBucketRequestPaymentHandler

func (s3a *S3ApiServer) GetBucketRequestPaymentHandler(w http.ResponseWriter, r *http.Request)

GetBucketRequestPaymentHandler Get bucket location https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetBucketRequestPayment.html

func (*S3ApiServer) GetObjectAclHandler

func (s3a *S3ApiServer) GetObjectAclHandler(w http.ResponseWriter, r *http.Request)

GetObjectAclHandler Put object ACL https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectAcl.html

func (*S3ApiServer) GetObjectHandler

func (s3a *S3ApiServer) GetObjectHandler(w http.ResponseWriter, r *http.Request)

func (*S3ApiServer) GetObjectTaggingHandler

func (s3a *S3ApiServer) GetObjectTaggingHandler(w http.ResponseWriter, r *http.Request)

GetObjectTaggingHandler - GET object tagging API reference: https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObjectTagging.html

func (*S3ApiServer) HeadBucketHandler

func (s3a *S3ApiServer) HeadBucketHandler(w http.ResponseWriter, r *http.Request)

func (*S3ApiServer) HeadObjectHandler

func (s3a *S3ApiServer) HeadObjectHandler(w http.ResponseWriter, r *http.Request)

func (*S3ApiServer) ListBucketsHandler

func (s3a *S3ApiServer) ListBucketsHandler(w http.ResponseWriter, r *http.Request)

func (*S3ApiServer) ListMultipartUploadsHandler

func (s3a *S3ApiServer) ListMultipartUploadsHandler(w http.ResponseWriter, r *http.Request)

ListMultipartUploadsHandler - Lists multipart uploads.

func (*S3ApiServer) ListObjectPartsHandler

func (s3a *S3ApiServer) ListObjectPartsHandler(w http.ResponseWriter, r *http.Request)

ListObjectPartsHandler - Lists object parts in a multipart upload.

func (*S3ApiServer) ListObjectsV1Handler

func (s3a *S3ApiServer) ListObjectsV1Handler(w http.ResponseWriter, r *http.Request)

func (*S3ApiServer) ListObjectsV2Handler

func (s3a *S3ApiServer) ListObjectsV2Handler(w http.ResponseWriter, r *http.Request)

func (*S3ApiServer) NewMultipartUploadHandler

func (s3a *S3ApiServer) NewMultipartUploadHandler(w http.ResponseWriter, r *http.Request)

NewMultipartUploadHandler - New multipart upload.

func (*S3ApiServer) PostPolicyBucketHandler

func (s3a *S3ApiServer) PostPolicyBucketHandler(w http.ResponseWriter, r *http.Request)

func (*S3ApiServer) PutBucketAclHandler

func (s3a *S3ApiServer) PutBucketAclHandler(w http.ResponseWriter, r *http.Request)

PutBucketAclHandler Put bucket ACL https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketAcl.html

func (*S3ApiServer) PutBucketCorsHandler

func (s3a *S3ApiServer) PutBucketCorsHandler(w http.ResponseWriter, r *http.Request)

PutBucketCorsHandler Put bucket CORS https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketCors.html

func (*S3ApiServer) PutBucketHandler

func (s3a *S3ApiServer) PutBucketHandler(w http.ResponseWriter, r *http.Request)

func (*S3ApiServer) PutBucketLifecycleConfigurationHandler

func (s3a *S3ApiServer) PutBucketLifecycleConfigurationHandler(w http.ResponseWriter, r *http.Request)

PutBucketLifecycleConfigurationHandler Put Bucket Lifecycle configuration https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketLifecycleConfiguration.html

func (*S3ApiServer) PutBucketPolicyHandler

func (s3a *S3ApiServer) PutBucketPolicyHandler(w http.ResponseWriter, r *http.Request)

PutBucketPolicyHandler Put bucket Policy https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutBucketPolicy.html

func (*S3ApiServer) PutObjectAclHandler

func (s3a *S3ApiServer) PutObjectAclHandler(w http.ResponseWriter, r *http.Request)

PutObjectAclHandler Put object ACL https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutObjectAcl.html

func (*S3ApiServer) PutObjectHandler

func (s3a *S3ApiServer) PutObjectHandler(w http.ResponseWriter, r *http.Request)

func (*S3ApiServer) PutObjectLegalHoldHandler

func (s3a *S3ApiServer) PutObjectLegalHoldHandler(w http.ResponseWriter, r *http.Request)

PutObjectLegalHoldHandler Put object Legal Hold https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutObjectLegalHold.html

func (*S3ApiServer) PutObjectLockConfigurationHandler

func (s3a *S3ApiServer) PutObjectLockConfigurationHandler(w http.ResponseWriter, r *http.Request)

PutObjectLockConfigurationHandler Put object Lock configuration https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutObjectLockConfiguration.html

func (*S3ApiServer) PutObjectPartHandler

func (s3a *S3ApiServer) PutObjectPartHandler(w http.ResponseWriter, r *http.Request)

PutObjectPartHandler - Put an object part in a multipart upload.

func (*S3ApiServer) PutObjectRetentionHandler

func (s3a *S3ApiServer) PutObjectRetentionHandler(w http.ResponseWriter, r *http.Request)

PutObjectRetentionHandler Put object Retention https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutObjectRetention.html

func (*S3ApiServer) PutObjectTaggingHandler

func (s3a *S3ApiServer) PutObjectTaggingHandler(w http.ResponseWriter, r *http.Request)

PutObjectTaggingHandler Put object tagging API reference: https://docs.aws.amazon.com/AmazonS3/latest/API/API_PutObjectTagging.html

func (*S3ApiServer) StatusHandler

func (s3a *S3ApiServer) StatusHandler(w http.ResponseWriter, r *http.Request)

func (*S3ApiServer) WithFilerClient

func (s3a *S3ApiServer) WithFilerClient(streamingMode bool, fn func(filer_pb.SeaweedFilerClient) error) error

type S3ApiServerOption

type S3ApiServerOption struct {
	Filer                     pb.ServerAddress
	Port                      int
	Config                    string
	DomainName                string
	BucketsPath               string
	GrpcDialOption            grpc.DialOption
	AllowEmptyFolder          bool
	AllowDeleteBucketNotEmpty bool
	LocalFilerSocket          *string
}

type SetBucketAccessControlPolicy

type SetBucketAccessControlPolicy struct {
	Bucket            string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	AccessControlList AccessControlList `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AccessControlList,omitempty"`
	AWSAccessKeyId    string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp         time.Time         `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature         string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential        string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
}

func (*SetBucketAccessControlPolicy) MarshalXML

func (t *SetBucketAccessControlPolicy) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*SetBucketAccessControlPolicy) UnmarshalXML

func (t *SetBucketAccessControlPolicy) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type SetBucketAccessControlPolicyResponse

type SetBucketAccessControlPolicyResponse struct {
}

type SetBucketLoggingStatus

type SetBucketLoggingStatus struct {
	Bucket              string              `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	AWSAccessKeyId      string              `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp           time.Time           `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature           string              `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential          string              `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
	BucketLoggingStatus BucketLoggingStatus `xml:"http://s3.amazonaws.com/doc/2006-03-01/ BucketLoggingStatus"`
}

func (*SetBucketLoggingStatus) MarshalXML

func (t *SetBucketLoggingStatus) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*SetBucketLoggingStatus) UnmarshalXML

func (t *SetBucketLoggingStatus) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type SetBucketLoggingStatusResponse

type SetBucketLoggingStatusResponse struct {
}

type SetObjectAccessControlPolicy

type SetObjectAccessControlPolicy struct {
	Bucket            string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Bucket"`
	Key               string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Key"`
	AccessControlList AccessControlList `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AccessControlList"`
	AWSAccessKeyId    string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ AWSAccessKeyId,omitempty"`
	Timestamp         time.Time         `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Timestamp,omitempty"`
	Signature         string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Signature,omitempty"`
	Credential        string            `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Credential,omitempty"`
}

func (*SetObjectAccessControlPolicy) MarshalXML

func (t *SetObjectAccessControlPolicy) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*SetObjectAccessControlPolicy) UnmarshalXML

func (t *SetObjectAccessControlPolicy) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type SetObjectAccessControlPolicyResponse

type SetObjectAccessControlPolicyResponse struct {
}

type Status

type Status struct {
	Code        int    `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Code"`
	Description string `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Description"`
}

type StatusRecorder

type StatusRecorder struct {
	http.ResponseWriter
	Status int
}

func NewStatusResponseWriter

func NewStatusResponseWriter(w http.ResponseWriter) *StatusRecorder

func (*StatusRecorder) Flush

func (r *StatusRecorder) Flush()

func (*StatusRecorder) WriteHeader

func (r *StatusRecorder) WriteHeader(status int)

type StorageClass

type StorageClass string

May be one of STANDARD, REDUCED_REDUNDANCY, GLACIER, UNKNOWN

type Tag

type Tag struct {
	Key   string `xml:"Key"`
	Value string `xml:"Value"`
}

type TagSet

type TagSet struct {
	Tag []Tag `xml:"Tag"`
}

type Tagging

type Tagging struct {
	XMLName xml.Name `xml:"Tagging"`
	TagSet  TagSet   `xml:"TagSet"`
	Xmlns   string   `xml:"xmlns,attr"`
}

func FromTags

func FromTags(tags map[string]string) (t *Tagging)

func (*Tagging) ToTags

func (t *Tagging) ToTags() map[string]string

type TopicConfiguration

type TopicConfiguration struct {
	Topic string   `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Topic"`
	Event []string `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Event"`
}

type Transition

type Transition struct {
	XMLName      xml.Name  `xml:"Transition"`
	Days         int       `xml:"Days,omitempty"`
	Date         time.Time `xml:"Date,omitempty"`
	StorageClass string    `xml:"StorageClass,omitempty"`
	// contains filtered or unexported fields
}

Transition - transition actions for a rule in lifecycle configuration.

func (Transition) MarshalXML

func (t Transition) MarshalXML(enc *xml.Encoder, start xml.StartElement) error

MarshalXML encodes transition field into an XML form.

type TransitionDays

type TransitionDays int

TransitionDays is a type alias to unmarshal Days in Transition

type User

type User struct {
}

type VersionEntry

type VersionEntry struct {
	Key          string        `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Key"`
	VersionId    string        `xml:"http://s3.amazonaws.com/doc/2006-03-01/ VersionId"`
	IsLatest     bool          `xml:"http://s3.amazonaws.com/doc/2006-03-01/ IsLatest"`
	LastModified time.Time     `xml:"http://s3.amazonaws.com/doc/2006-03-01/ LastModified"`
	ETag         string        `xml:"http://s3.amazonaws.com/doc/2006-03-01/ ETag"`
	Size         int64         `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Size"`
	Owner        CanonicalUser `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Owner,omitempty"`
	StorageClass StorageClass  `xml:"http://s3.amazonaws.com/doc/2006-03-01/ StorageClass"`
}

func (*VersionEntry) MarshalXML

func (t *VersionEntry) MarshalXML(e *xml.Encoder, start xml.StartElement) error

func (*VersionEntry) UnmarshalXML

func (t *VersionEntry) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error

type VersioningConfiguration

type VersioningConfiguration struct {
	Status    VersioningStatus `xml:"http://s3.amazonaws.com/doc/2006-03-01/ Status,omitempty"`
	MfaDelete MfaDeleteStatus  `xml:"http://s3.amazonaws.com/doc/2006-03-01/ MfaDelete,omitempty"`
}

type VersioningStatus

type VersioningStatus string

May be one of Enabled, Suspended

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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