@Generated(value="jsii-pacmak/1.67.0 (build 2c027f5)", date="2022-09-19T20:26:39.394Z") @Stability(value=Stable) public class CfnDataset extends CfnResource implements IInspectable
Creates an Amazon Forecast dataset. The information about the dataset that you provide helps Forecast understand how to consume the data for model training. This includes the following:
DataFrequency - How frequently your historical time-series data is collected.Domain and DatasetType - Each dataset has an associated dataset domain and a type within the domain. Amazon Forecast provides a list of predefined domains and types within each domain. For each unique dataset domain and type within the domain, Amazon Forecast requires your data to include a minimum set of predefined fields.Schema - A schema specifies the fields in the dataset, including the field name and data type.After creating a dataset, you import your training data into it and add the dataset to a dataset group. You use the dataset group to create a predictor. For more information, see Importing datasets .
To get a list of all your datasets, use the ListDatasets operation.
For example Forecast datasets, see the Amazon Forecast Sample GitHub repository .
The
Statusof a dataset must beACTIVEbefore you can import training data. Use the DescribeDataset operation to get the status.
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.forecast.*;
Object encryptionConfig;
Object schema;
Object tags;
CfnDataset cfnDataset = CfnDataset.Builder.create(this, "MyCfnDataset")
.datasetName("datasetName")
.datasetType("datasetType")
.domain("domain")
.schema(schema)
// the properties below are optional
.dataFrequency("dataFrequency")
.encryptionConfig(encryptionConfig)
.tags(List.of(tags))
.build();
| Modifier and Type | Class and Description |
|---|---|
static class |
CfnDataset.Builder
A fluent builder for
CfnDataset. |
software.amazon.jsii.JsiiObject.InitializationModeIInspectable.Jsii$Default, IInspectable.Jsii$Proxy| Modifier and Type | Field and Description |
|---|---|
static String |
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
|
| Modifier | Constructor and Description |
|---|---|
|
CfnDataset(software.constructs.Construct scope,
String id,
CfnDatasetProps props)
Create a new `AWS::Forecast::Dataset`.
|
protected |
CfnDataset(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) |
protected |
CfnDataset(software.amazon.jsii.JsiiObjectRef objRef) |
| Modifier and Type | Method and Description |
|---|---|
String |
getAttrArn()
The Amazon Resource Name (ARN) of the dataset.
|
protected Map<String,Object> |
getCfnProperties() |
String |
getDataFrequency()
The frequency of data collection.
|
String |
getDatasetName()
The name of the dataset.
|
String |
getDatasetType()
The dataset type.
|
String |
getDomain()
The domain associated with the dataset.
|
Object |
getEncryptionConfig()
A Key Management Service (KMS) key and the Identity and Access Management (IAM) role that Amazon Forecast can assume to access the key.
|
Object |
getSchema()
The schema for the dataset.
|
List<Object> |
getTags()
An array of key-value pairs to apply to this resource.
|
void |
inspect(TreeInspector inspector)
Examines the CloudFormation resource and discloses attributes.
|
protected Map<String,Object> |
renderProperties(Map<String,Object> props) |
void |
setDataFrequency(String value)
The frequency of data collection.
|
void |
setDatasetName(String value)
The name of the dataset.
|
void |
setDatasetType(String value)
The dataset type.
|
void |
setDomain(String value)
The domain associated with the dataset.
|
void |
setEncryptionConfig(Object value)
A Key Management Service (KMS) key and the Identity and Access Management (IAM) role that Amazon Forecast can assume to access the key.
|
void |
setSchema(Object value)
The schema for the dataset.
|
void |
setTags(List<Object> value)
An array of key-value pairs to apply to this resource.
|
addDeletionOverride, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getCfnOptions, getCfnResourceType, getMetadata, getUpdatedProperites, getUpdatedProperties, isCfnResource, shouldSynthesize, toString, validatePropertiesgetRefgetCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalIdjsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet@Stability(value=Stable) public static final String CFN_RESOURCE_TYPE_NAME
protected CfnDataset(software.amazon.jsii.JsiiObjectRef objRef)
protected CfnDataset(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
@Stability(value=Stable)
public CfnDataset(@NotNull
software.constructs.Construct scope,
@NotNull
String id,
@NotNull
CfnDatasetProps props)
scope - - scope in which this resource is defined. This parameter is required.id - - scoped id of the resource. This parameter is required.props - - resource properties. This parameter is required.@Stability(value=Stable)
public void inspect(@NotNull
TreeInspector inspector)
inspect in interface IInspectableinspector - - tree inspector to collect and process attributes. This parameter is required.@Stability(value=Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String,Object> props)
renderProperties in class CfnResourceprops - This parameter is required.@Stability(value=Stable) @NotNull public String getAttrArn()
@Stability(value=Stable) @NotNull protected Map<String,Object> getCfnProperties()
getCfnProperties in class CfnResource@Stability(value=Stable) @NotNull public String getDatasetName()
@Stability(value=Stable)
public void setDatasetName(@NotNull
String value)
@Stability(value=Stable) @NotNull public String getDatasetType()
@Stability(value=Stable)
public void setDatasetType(@NotNull
String value)
@Stability(value=Stable) @NotNull public String getDomain()
@Stability(value=Stable)
public void setDomain(@NotNull
String value)
@Stability(value=Stable) @NotNull public Object getEncryptionConfig()
@Stability(value=Stable)
public void setEncryptionConfig(@NotNull
Object value)
@Stability(value=Stable) @NotNull public Object getSchema()
The schema attributes and their order must match the fields in your data. The dataset Domain and DatasetType that you choose determine the minimum required fields in your training data. For information about the required fields for a specific dataset domain and type, see Dataset Domains and Dataset Types .
@Stability(value=Stable)
public void setSchema(@NotNull
Object value)
The schema attributes and their order must match the fields in your data. The dataset Domain and DatasetType that you choose determine the minimum required fields in your training data. For information about the required fields for a specific dataset domain and type, see Dataset Domains and Dataset Types .
@Stability(value=Stable) @Nullable public String getDataFrequency()
Valid intervals are Y (Year), M (Month), W (Week), D (Day), H (Hour), 30min (30 minutes), 15min (15 minutes), 10min (10 minutes), 5min (5 minutes), and 1min (1 minute). For example, "D" indicates every day and "15min" indicates every 15 minutes.
@Stability(value=Stable)
public void setDataFrequency(@Nullable
String value)
Valid intervals are Y (Year), M (Month), W (Week), D (Day), H (Hour), 30min (30 minutes), 15min (15 minutes), 10min (10 minutes), 5min (5 minutes), and 1min (1 minute). For example, "D" indicates every day and "15min" indicates every 15 minutes.
@Stability(value=Stable) @Nullable public List<Object> getTags()
For more information, see Tag .
Copyright © 2022. All rights reserved.