Class ReplicationRuleFilter
- java.lang.Object
-
- software.amazon.awssdk.services.s3.model.ReplicationRuleFilter
-
- All Implemented Interfaces:
Serializable
,SdkPojo
,ToCopyableBuilder<ReplicationRuleFilter.Builder,ReplicationRuleFilter>
@Generated("software.amazon.awssdk:codegen") public final class ReplicationRuleFilter extends Object implements SdkPojo, Serializable, ToCopyableBuilder<ReplicationRuleFilter.Builder,ReplicationRuleFilter>
A filter that identifies the subset of objects to which the replication rule applies. A
Filter
must specify exactly onePrefix
,Tag
, or anAnd
child element.- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interface
ReplicationRuleFilter.Builder
static class
ReplicationRuleFilter.Type
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description ReplicationRuleAndOperator
and()
A container for specifying rule filters.static ReplicationRuleFilter.Builder
builder()
boolean
equals(Object obj)
boolean
equalsBySdkFields(Object obj)
static ReplicationRuleFilter
fromAnd(Consumer<ReplicationRuleAndOperator.Builder> and)
Create an instance of this class withand()
initialized to the given value.static ReplicationRuleFilter
fromAnd(ReplicationRuleAndOperator and)
Create an instance of this class withand()
initialized to the given value.static ReplicationRuleFilter
fromPrefix(String prefix)
Create an instance of this class withprefix()
initialized to the given value.static ReplicationRuleFilter
fromTag(Consumer<Tag.Builder> tag)
Create an instance of this class withtag()
initialized to the given value.static ReplicationRuleFilter
fromTag(Tag tag)
Create an instance of this class withtag()
initialized to the given value.<T> Optional<T>
getValueForField(String fieldName, Class<T> clazz)
int
hashCode()
String
prefix()
An object key name prefix that identifies the subset of objects to which the rule applies.List<SdkField<?>>
sdkFields()
static Class<? extends ReplicationRuleFilter.Builder>
serializableBuilderClass()
Tag
tag()
A container for specifying a tag key and value.ReplicationRuleFilter.Builder
toBuilder()
String
toString()
Returns a string representation of this object.ReplicationRuleFilter.Type
type()
Retrieve an enum value representing which member of this object is populated.-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface software.amazon.awssdk.utils.builder.ToCopyableBuilder
copy
-
-
-
-
Method Detail
-
prefix
public final String prefix()
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.
- Returns:
- 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.
-
tag
public final Tag tag()
A container for specifying a tag key and value.
The rule applies only to objects that have the tag in their tag set.
- Returns:
- A container for specifying a tag key and value.
The rule applies only to objects that have the tag in their tag set.
-
and
public final ReplicationRuleAndOperator and()
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 aTag
filter, wrap these filters in anAnd
tag. -
If you specify a filter based on multiple tags, wrap the
Tag
elements in anAnd
tag.
- Returns:
- 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 aTag
filter, wrap these filters in anAnd
tag. -
If you specify a filter based on multiple tags, wrap the
Tag
elements in anAnd
tag.
-
-
-
toBuilder
public ReplicationRuleFilter.Builder toBuilder()
- Specified by:
toBuilder
in interfaceToCopyableBuilder<ReplicationRuleFilter.Builder,ReplicationRuleFilter>
-
builder
public static ReplicationRuleFilter.Builder builder()
-
serializableBuilderClass
public static Class<? extends ReplicationRuleFilter.Builder> serializableBuilderClass()
-
equalsBySdkFields
public final boolean equalsBySdkFields(Object obj)
- Specified by:
equalsBySdkFields
in interfaceSdkPojo
-
toString
public final String toString()
Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be redacted from this string using a placeholder value.
-
fromPrefix
public static ReplicationRuleFilter fromPrefix(String prefix)
Create an instance of this class withprefix()
initialized to the given value.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.
- Parameters:
prefix
- 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.
-
fromTag
public static ReplicationRuleFilter fromTag(Tag tag)
Create an instance of this class withtag()
initialized to the given value.A container for specifying a tag key and value.
The rule applies only to objects that have the tag in their tag set.
- Parameters:
tag
- A container for specifying a tag key and value.The rule applies only to objects that have the tag in their tag set.
-
fromTag
public static ReplicationRuleFilter fromTag(Consumer<Tag.Builder> tag)
Create an instance of this class withtag()
initialized to the given value.A container for specifying a tag key and value.
The rule applies only to objects that have the tag in their tag set.
- Parameters:
tag
- A container for specifying a tag key and value.The rule applies only to objects that have the tag in their tag set.
-
fromAnd
public static ReplicationRuleFilter fromAnd(ReplicationRuleAndOperator and)
Create an instance of this class withand()
initialized to the given value.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 aTag
filter, wrap these filters in anAnd
tag. -
If you specify a filter based on multiple tags, wrap the
Tag
elements in anAnd
tag.
- Parameters:
and
- 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 aTag
filter, wrap these filters in anAnd
tag. -
If you specify a filter based on multiple tags, wrap the
Tag
elements in anAnd
tag.
-
-
-
fromAnd
public static ReplicationRuleFilter fromAnd(Consumer<ReplicationRuleAndOperator.Builder> and)
Create an instance of this class withand()
initialized to the given value.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 aTag
filter, wrap these filters in anAnd
tag. -
If you specify a filter based on multiple tags, wrap the
Tag
elements in anAnd
tag.
- Parameters:
and
- 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 aTag
filter, wrap these filters in anAnd
tag. -
If you specify a filter based on multiple tags, wrap the
Tag
elements in anAnd
tag.
-
-
-
type
public ReplicationRuleFilter.Type type()
Retrieve an enum value representing which member of this object is populated. When this class is returned in a service response, this will beReplicationRuleFilter.Type.UNKNOWN_TO_SDK_VERSION
if the service returned a member that is only known to a newer SDK version. When this class is created directly in your code, this will beReplicationRuleFilter.Type.UNKNOWN_TO_SDK_VERSION
if zero members are set, andnull
if more than one member is set.
-
-