java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
All Implemented Interfaces:
IInspectable, IDatasetRef, IEnvironmentAware, software.amazon.jsii.JsiiSerializable, software.constructs.IConstruct, software.constructs.IDependable

@Generated(value="jsii-pacmak/1.138.0 (build 0ca7ee8)", date="2026-08-10T14:51:00.201Z") @Stability(Stable) public class CfnDataset extends CfnResource implements IInspectable, IDatasetRef
Resource type definition for a Cognito Sync Dataset.

A dataset is a collection of key-value pairs per identity that can store up to 1 MB of data and sync across devices.

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.cognitosync.*;
 CfnDataset cfnDataset = CfnDataset.Builder.create(this, "MyCfnDataset")
         .datasetName("datasetName")
         .identityId("identityId")
         .identityPoolId("identityPoolId")
         .build();
 

See Also:
  • Field Details

    • CFN_RESOURCE_TYPE_NAME

      @Stability(Stable) public static final String CFN_RESOURCE_TYPE_NAME
      The CloudFormation resource type name for this resource class.
  • Constructor Details

    • CfnDataset

      protected CfnDataset(software.amazon.jsii.JsiiObjectRef objRef)
    • CfnDataset

      protected CfnDataset(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
    • CfnDataset

      @Stability(Stable) public CfnDataset(@NotNull software.constructs.Construct scope, @NotNull String id, @Nullable CfnDatasetProps props)
      Create a new AWS::CognitoSync::Dataset.

      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.
    • CfnDataset

      @Stability(Stable) public CfnDataset(@NotNull software.constructs.Construct scope, @NotNull String id)
      Create a new AWS::CognitoSync::Dataset.

      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.
  • Method Details

    • arnForDataset

      @Stability(Stable) @NotNull public static String arnForDataset(@NotNull IDatasetRef resource)
      Parameters:
      resource - This parameter is required.
    • isCfnDataset

      @Stability(Stable) @NotNull public static Boolean isCfnDataset(@NotNull Object x)
      Checks whether the given object is a CfnDataset.

      Parameters:
      x - This parameter is required.
    • inspect

      @Stability(Stable) public void inspect(@NotNull TreeInspector inspector)
      Examines the CloudFormation resource and discloses attributes.

      Specified by:
      inspect in interface IInspectable
      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:
      renderProperties in class CfnResource
      Parameters:
      props - This parameter is required.
    • getAttrArn

      @Stability(Stable) @NotNull public String getAttrArn()
      The Amazon Resource Name (ARN) of the dataset.
    • getAttrCreationDate

      @Stability(Stable) @NotNull public String getAttrCreationDate()
      Date on which the dataset was created.
    • getAttrDataStorage

      @Stability(Stable) @NotNull public Number getAttrDataStorage()
      Total size in bytes of the records in this dataset.
    • getAttrLastModifiedBy

      @Stability(Stable) @NotNull public String getAttrLastModifiedBy()
      The device that made the last change to this dataset.
    • getAttrLastModifiedDate

      @Stability(Stable) @NotNull public String getAttrLastModifiedDate()
      Date when the dataset was last modified.
    • getAttrNumRecords

      @Stability(Stable) @NotNull public Number getAttrNumRecords()
      Number of records in this dataset.
    • getCfnProperties

      @Stability(Stable) @NotNull protected Map<String,Object> getCfnProperties()
      Overrides:
      getCfnProperties in class CfnResource
    • getCfnPropertyNames

      @Stability(Stable) @NotNull protected Map<String,String> getCfnPropertyNames()
      Overrides:
      getCfnPropertyNames in class CfnResource
    • getDatasetRef

      @Stability(Stable) @NotNull public DatasetReference getDatasetRef()
      A reference to a Dataset resource.
      Specified by:
      getDatasetRef in interface IDatasetRef
    • getDatasetName

      @Stability(Stable) @Nullable public String getDatasetName()
      A string of up to 128 characters.
    • setDatasetName

      @Stability(Stable) public void setDatasetName(@Nullable String value)
      A string of up to 128 characters.
    • getIdentityId

      @Stability(Stable) @Nullable public String getIdentityId()
      A name-spaced GUID (for example, us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon Cognito.
    • setIdentityId

      @Stability(Stable) public void setIdentityId(@Nullable String value)
      A name-spaced GUID (for example, us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon Cognito.
    • getIdentityPoolId

      @Stability(Stable) @Nullable public String getIdentityPoolId()
      A name-spaced GUID (for example, us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon Cognito.
    • setIdentityPoolId

      @Stability(Stable) public void setIdentityPoolId(@Nullable String value)
      A name-spaced GUID (for example, us-east-1:23EC4050-6AEA-7089-A2DD-08002EXAMPLE) created by Amazon Cognito.