Class CfnStorageLensGroup
java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
software.amazon.awscdk.CfnElement
software.amazon.awscdk.CfnRefElement
software.amazon.awscdk.CfnResource
software.amazon.awscdk.services.s3.CfnStorageLensGroup
- All Implemented Interfaces:
IEnvironmentAware,IInspectable,ITaggableV2,IStorageLensGroupRef,software.amazon.jsii.JsiiSerializable,software.constructs.IConstruct,software.constructs.IDependable
@Generated(value="jsii-pacmak/1.118.0 (build 02eec31)",
date="2025-11-04T09:27:49.434Z")
@Stability(Stable)
public class CfnStorageLensGroup
extends CfnResource
implements IInspectable, IStorageLensGroupRef, ITaggableV2
The
AWS::S3::StorageLensGroup resource creates an S3 Storage Lens group.
A Storage Lens group is a custom grouping of objects that include filters for prefixes, suffixes, object tags, object size, or object age. You can create an S3 Storage Lens group that includes a single filter or multiple filter conditions. To specify multiple filter conditions, you use AND or OR logical operators. For more information about S3 Storage Lens groups, see Working with S3 Storage Lens groups .
Example:
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.s3.*;
CfnStorageLensGroup cfnStorageLensGroup = CfnStorageLensGroup.Builder.create(this, "MyCfnStorageLensGroup")
.filter(FilterProperty.builder()
.and(AndProperty.builder()
.matchAnyPrefix(List.of("matchAnyPrefix"))
.matchAnySuffix(List.of("matchAnySuffix"))
.matchAnyTag(List.of(CfnTag.builder()
.key("key")
.value("value")
.build()))
.matchObjectAge(MatchObjectAgeProperty.builder()
.daysGreaterThan(123)
.daysLessThan(123)
.build())
.matchObjectSize(MatchObjectSizeProperty.builder()
.bytesGreaterThan(123)
.bytesLessThan(123)
.build())
.build())
.matchAnyPrefix(List.of("matchAnyPrefix"))
.matchAnySuffix(List.of("matchAnySuffix"))
.matchAnyTag(List.of(CfnTag.builder()
.key("key")
.value("value")
.build()))
.matchObjectAge(MatchObjectAgeProperty.builder()
.daysGreaterThan(123)
.daysLessThan(123)
.build())
.matchObjectSize(MatchObjectSizeProperty.builder()
.bytesGreaterThan(123)
.bytesLessThan(123)
.build())
.or(OrProperty.builder()
.matchAnyPrefix(List.of("matchAnyPrefix"))
.matchAnySuffix(List.of("matchAnySuffix"))
.matchAnyTag(List.of(CfnTag.builder()
.key("key")
.value("value")
.build()))
.matchObjectAge(MatchObjectAgeProperty.builder()
.daysGreaterThan(123)
.daysLessThan(123)
.build())
.matchObjectSize(MatchObjectSizeProperty.builder()
.bytesGreaterThan(123)
.bytesLessThan(123)
.build())
.build())
.build())
.name("name")
// the properties below are optional
.tags(List.of(CfnTag.builder()
.key("key")
.value("value")
.build()))
.build();
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic interfaceThis resource is a logical operator that allows multiple filter conditions to be joined for more complex comparisons of Storage Lens group data.static final classA fluent builder forCfnStorageLensGroup.static interfaceThis resource sets the criteria for the Storage Lens group data that is displayed.static interfaceThis resource containsDaysGreaterThanandDaysLessThanto define the object age range (minimum and maximum number of days).static interfaceThis resource filters objects that match the specified object size range.static interfaceThis resource contains theOrlogical operator, which allows multiple filter conditions to be joined for more complex comparisons of Storage Lens group data.Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationModeNested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$DefaultNested classes/interfaces inherited from interface software.amazon.awscdk.IInspectable
IInspectable.Jsii$Default, IInspectable.Jsii$ProxyNested classes/interfaces inherited from interface software.amazon.awscdk.services.s3.IStorageLensGroupRef
IStorageLensGroupRef.Jsii$Default, IStorageLensGroupRef.Jsii$ProxyNested classes/interfaces inherited from interface software.amazon.awscdk.ITaggableV2
ITaggableV2.Jsii$Default, ITaggableV2.Jsii$Proxy -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringThe CloudFormation resource type name for this resource class. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedCfnStorageLensGroup(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protectedCfnStorageLensGroup(software.amazon.jsii.JsiiObjectRef objRef) CfnStorageLensGroup(software.constructs.Construct scope, String id, CfnStorageLensGroupProps props) -
Method Summary
Modifier and TypeMethodDescriptionThe ARN for the Amazon S3 Storage Lens Group.Tag Manager which manages the tags for this resource.This property contains the criteria for the Storage Lens group data that is displayed.getName()This property contains the Storage Lens group name.A reference to a StorageLensGroup resource.getTags()This property contains the AWS resource tags that you're adding to your Storage Lens group.voidinspect(TreeInspector inspector) Examines the CloudFormation resource and discloses attributes.renderProperties(Map<String, Object> props) voidsetFilter(IResolvable value) This property contains the criteria for the Storage Lens group data that is displayed.voidThis property contains the criteria for the Storage Lens group data that is displayed.voidThis property contains the Storage Lens group name.voidThis property contains the AWS resource tags that you're adding to your Storage Lens group.Methods inherited from class software.amazon.awscdk.CfnResource
addDeletionOverride, addDependency, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getAtt, getCfnOptions, getCfnResourceType, getEnv, getMetadata, getUpdatedProperites, getUpdatedProperties, isCfnResource, obtainDependencies, obtainResourceDependencies, removeDependency, replaceDependency, shouldSynthesize, toString, validatePropertiesMethods inherited from class software.amazon.awscdk.CfnRefElement
getRefMethods inherited from class software.amazon.awscdk.CfnElement
getCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalIdMethods inherited from class software.constructs.Construct
getNode, isConstructMethods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface software.constructs.IConstruct
getNodeMethods inherited from interface software.amazon.awscdk.IEnvironmentAware
getEnvMethods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Field Details
-
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
-
-
Constructor Details
-
CfnStorageLensGroup
protected CfnStorageLensGroup(software.amazon.jsii.JsiiObjectRef objRef) -
CfnStorageLensGroup
protected CfnStorageLensGroup(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
CfnStorageLensGroup
@Stability(Stable) public CfnStorageLensGroup(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull CfnStorageLensGroupProps props) - Parameters:
scope- Scope in which this resource is defined. This parameter is required.id- Construct identifier for this resource (unique in its scope). This parameter is required.props- Resource properties. This parameter is required.
-
-
Method Details
-
inspect
Examines the CloudFormation resource and discloses attributes.- Specified by:
inspectin interfaceIInspectable- Parameters:
inspector- tree inspector to collect and process attributes. This parameter is required.
-
renderProperties
@Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String, Object> props) - Overrides:
renderPropertiesin classCfnResource- Parameters:
props- This parameter is required.
-
getAttrStorageLensGroupArn
The ARN for the Amazon S3 Storage Lens Group. -
getCdkTagManager
Tag Manager which manages the tags for this resource.- Specified by:
getCdkTagManagerin interfaceITaggableV2
-
getCfnProperties
- Overrides:
getCfnPropertiesin classCfnResource
-
getStorageLensGroupRef
A reference to a StorageLensGroup resource.- Specified by:
getStorageLensGroupRefin interfaceIStorageLensGroupRef
-
getFilter
This property contains the criteria for the Storage Lens group data that is displayed.Returns union: either
IResolvableorCfnStorageLensGroup.FilterProperty -
setFilter
This property contains the criteria for the Storage Lens group data that is displayed. -
setFilter
This property contains the criteria for the Storage Lens group data that is displayed. -
getName
This property contains the Storage Lens group name. -
setName
This property contains the Storage Lens group name. -
getTags
This property contains the AWS resource tags that you're adding to your Storage Lens group. -
setTags
This property contains the AWS resource tags that you're adding to your Storage Lens group.
-