Struct: s3.Redirect
Overview
Specifies how requests are redirected. In the event of an error, you can specify a different error code to return.
Implemented Interfaces
s3crypto.Cipher, s3manager.ReadSeekerWriteTo, s3manager.WriterReadFrom
Structure Field Summary collapse
-
HostName *string
The host name to use in the redirect request.
-
HttpRedirectCode *string
The HTTP redirect code to use on the response.
-
Protocol *string
Protocol to use when redirecting requests.
-
ReplaceKeyPrefixWith *string
The object key prefix to use in the redirect request.
-
ReplaceKeyWith *string
The specific object key to use in the redirect request.
- _ struct{}
Service Operations collapse
-
GoString() string
operation
GoString returns the string representation.
-
SetHostName(string) *Redirect
operation
SetHostName sets the HostName field's value.
-
SetHttpRedirectCode(string) *Redirect
operation
SetHttpRedirectCode sets the HttpRedirectCode field's value.
-
SetProtocol(string) *Redirect
operation
SetProtocol sets the Protocol field's value.
-
SetReplaceKeyPrefixWith(string) *Redirect
operation
SetReplaceKeyPrefixWith sets the ReplaceKeyPrefixWith field's value.
-
SetReplaceKeyWith(string) *Redirect
operation
SetReplaceKeyWith sets the ReplaceKeyWith field's value.
-
String() string
operation
String returns the string representation.
Structure Field Details
HostName *string
`type:"string"`
The host name to use in the redirect request.
HttpRedirectCode *string
`type:"string"`
The HTTP redirect code to use on the response. Not required if one of the siblings is present.
Protocol *string
`type:"string" enum:"Protocol"`
Protocol to use when redirecting requests. The default is the protocol that is used in the original request.
ReplaceKeyPrefixWith *string
`type:"string"`
The object key prefix to use in the redirect request. For example, to redirect requests for all pages with prefix docs/ (objects in the docs/ folder) to documents/, you can set a condition block with KeyPrefixEquals set to docs/ and in the Redirect set ReplaceKeyPrefixWith to /documents. Not required if one of the siblings is present. Can be present only if ReplaceKeyWith is not provided.
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).
ReplaceKeyWith *string
`type:"string"`
The specific object key to use in the redirect request. For example, redirect request to error.html. Not required if one of the siblings is present. Can be present only if ReplaceKeyPrefixWith is not provided.
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).
_ struct{}
`type:"structure"`
Method Details
func (s Redirect) 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”.
21272 21273 21274 |
// File 'service/s3/api.go', line 21272
|
func (s *Redirect) SetHostName(v string) *Redirect
SetHostName sets the HostName field's value.
21277 21278 21279 21280 |
// File 'service/s3/api.go', line 21277
|
func (s *Redirect) SetHttpRedirectCode(v string) *Redirect
SetHttpRedirectCode sets the HttpRedirectCode field's value.
21283 21284 21285 21286 |
// File 'service/s3/api.go', line 21283
|
func (s *Redirect) SetProtocol(v string) *Redirect
SetProtocol sets the Protocol field's value.
21289 21290 21291 21292 |
// File 'service/s3/api.go', line 21289
|
func (s *Redirect) SetReplaceKeyPrefixWith(v string) *Redirect
SetReplaceKeyPrefixWith sets the ReplaceKeyPrefixWith field's value.
21295 21296 21297 21298 |
// File 'service/s3/api.go', line 21295
|
func (s *Redirect) SetReplaceKeyWith(v string) *Redirect
SetReplaceKeyWith sets the ReplaceKeyWith field's value.
21301 21302 21303 21304 |
// File 'service/s3/api.go', line 21301
|
func (s Redirect) 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”.
21263 21264 21265 |
// File 'service/s3/api.go', line 21263
|