Skip to content
v2.278.0

FilterProperty Struct ​

The container for the filter of the lifecycle rule.

Example ​

ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_s3outposts as s3outposts } from 'aws-cdk-lib';
const filterProperty: s3outposts.CfnBucket.FilterProperty = {
  andOperator: {
    tags: [{
      key: 'key',
      value: 'value',
    }],

    // the properties below are optional
    prefix: 'prefix',
  },
  prefix: 'prefix',
  tag: {
    key: 'key',
    value: 'value',
  },
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_s3outposts as s3outposts

filter_property = s3outposts.CfnBucket.FilterProperty(
    and_operator=s3outposts.CfnBucket.FilterAndOperatorProperty(
        tags=[s3outposts.CfnBucket.FilterTagProperty(
            key="key",
            value="value"
        )],

        # the properties below are optional
        prefix="prefix"
    ),
    prefix="prefix",
    tag=s3outposts.CfnBucket.FilterTagProperty(
        key="key",
        value="value"
    )
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.s3outposts.*;

FilterProperty filterProperty = FilterProperty.builder()
        .andOperator(FilterAndOperatorProperty.builder()
                .tags(List.of(FilterTagProperty.builder()
                        .key("key")
                        .value("value")
                        .build()))

                // the properties below are optional
                .prefix("prefix")
                .build())
        .prefix("prefix")
        .tag(FilterTagProperty.builder()
                .key("key")
                .value("value")
                .build())
        .build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.S3Outposts;

var filterProperty = new FilterProperty {
    AndOperator = new FilterAndOperatorProperty {
        Tags = new [] { new FilterTagProperty {
            Key = "key",
            Value = "value"
        } },

        // the properties below are optional
        Prefix = "prefix"
    },
    Prefix = "prefix",
    Tag = new FilterTagProperty {
        Key = "key",
        Value = "value"
    }
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"

filterProperty := &FilterProperty{
	AndOperator: &FilterAndOperatorProperty{
		Tags: []FilterTagProperty{
			&FilterTagProperty{
				Key: jsii.String("key"),
				Value: jsii.String("value"),
			},
		},

		// the properties below are optional
		Prefix: jsii.String("prefix"),
	},
	Prefix: jsii.String("prefix"),
	Tag: &FilterTagProperty{
		Key: jsii.String("key"),
		Value: jsii.String("value"),
	},
}

Properties ​

andOperatoroptionalIResolvable | CfnBucket.FilterAndOperatorPropertyand_operatoroptionaltyping.Union[IResolvable, FilterAndOperatorProperty]andOperatoroptionalIResolvableAndOperatoroptionalIResolvableAndOperatoroptionalinterface{} #
prefixoptionalstringprefixoptionalstrprefixoptionalStringPrefixoptionalstringPrefixoptional*string #
Prefix identifies one or more objects to which the rule applies.
tagoptionalIResolvable | CfnBucket.FilterTagPropertytagoptionaltyping.Union[IResolvable, FilterTagProperty]tagoptionalIResolvableTagoptionalIResolvableTagoptionalinterface{} #
Tag used to identify a subset of objects for an Amazon S3Outposts bucket.