Struct: s3.ReplicationRuleFilter

import "../ibm-cos-sdk-go/service/s3"

Overview

A filter that identifies the subset of objects to which the replication rule applies. A Filter must specify exactly one Prefix, Tag, or an And child element.

Implemented Interfaces

s3crypto.Cipher, s3manager.ReadSeekerWriteTo, request.Validator, s3manager.WriterReadFrom

Structure Field Summary collapse

Service Operations collapse

Structure Field Details

And *ReplicationRuleAndOperator `type:"structure"`

A container for specifying rule filters. The filters determine the subset of objects to which the rule applies. This element is required only if you specify more than one filter. For example:

  • If you specify both a Prefix and a Tag filter, wrap these filters in an And tag.

  • If you specify a filter based on multiple tags, wrap the Tag elements in an And tag.

Prefix *string `type:"string"`

An object key name prefix that identifies the subset of objects to which the rule applies.

Replacement must be made for object keys containing special characters (such as carriage returns) when using XML requests. For more information, see XML related object key constraints (docs.aws.amazon.com/AmazonS3/latest/userguide/object-keys.html#object-key-xml-related-constraints).

Tag *Tag `type:"structure"`

A container for specifying a tag key and value.

The rule applies only to objects that have the tag in their tag set.

_ struct{} `type:"structure"`

Method Details

func (s ReplicationRuleFilter) GoString() string

GoString returns the string representation.

API parameter values that are decorated as “sensitive” in the API will not be included in the string output. The member name will be present, but the value will be replaced with “sensitive”.



21716
21717
21718
// File 'service/s3/api.go', line 21716

func (s ReplicationRuleFilter) GoString() string { return s.String() }

func (s *ReplicationRuleFilter) SetAnd(v *ReplicationRuleAndOperator) *ReplicationRuleFilter

SetAnd sets the And field's value.



21741
21742
21743
21744
// File 'service/s3/api.go', line 21741

func (s *ReplicationRuleFilter) SetPrefix(v string) *ReplicationRuleFilter

SetPrefix sets the Prefix field's value.



21747
21748
21749
21750
// File 'service/s3/api.go', line 21747

func (s *ReplicationRuleFilter) SetPrefix(v string) *ReplicationRuleFilter { s.Prefix = &v return s }

func (s *ReplicationRuleFilter) SetTag(v *Tag) *ReplicationRuleFilter

SetTag sets the Tag field's value.



21753
21754
21755
21756
// File 'service/s3/api.go', line 21753

func (s *ReplicationRuleFilter) SetTag(v *Tag) *ReplicationRuleFilter { s.Tag = v return s }

func (s ReplicationRuleFilter) String() string

String returns the string representation.

API parameter values that are decorated as “sensitive” in the API will not be included in the string output. The member name will be present, but the value will be replaced with “sensitive”.



21707
21708
21709
// File 'service/s3/api.go', line 21707

func (s ReplicationRuleFilter) String() string { return awsutil.Prettify(s) }

func (s *ReplicationRuleFilter) Validate() error

Validate inspects the fields of the type to determine if they are valid.



21721
21722
21723
21724
21725
21726
21727
21728
21729
21730
21731
21732
21733
21734
21735
21736
21737
21738
// File 'service/s3/api.go', line 21721

func (s *ReplicationRuleFilter) Validate() error { invalidParams := request.ErrInvalidParams{Context: "ReplicationRuleFilter"} if s.And != nil { if err := s.And.Validate(); err != nil { invalidParams.AddNested("And", err.(request.ErrInvalidParams)) } } if s.Tag != nil { if err := s.Tag.Validate(); err != nil { invalidParams.AddNested("Tag", err.(request.ErrInvalidParams)) } } if invalidParams.Len() > 0 { return invalidParams } return nil }