Class: AWSCDK::CleanRoomsML::CfnTrainingDatasetProps

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
clean_rooms_ml/cfn_training_dataset_props.rb

Overview

Properties for defining a CfnTrainingDataset.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name:, role_arn:, training_data:, description: nil, tags: nil) ⇒ CfnTrainingDatasetProps

Returns a new instance of CfnTrainingDatasetProps.

Parameters:

  • name (String)

    The name of the training dataset.

  • role_arn (String)

    The ARN of the IAM role that Clean Rooms ML can assume to read the data referred to in the dataSource field of each dataset.

  • training_data (AWSCDK::IResolvable, Array<AWSCDK::IResolvable, AWSCDK::CleanRoomsML::CfnTrainingDataset::DatasetProperty>)

    An array of information that lists the Dataset objects, which specifies the dataset type and details on its location and schema.

  • description (String, nil) (defaults to: nil)

    The description of the training dataset.

  • tags (Array<AWSCDK::CfnTag>, nil) (defaults to: nil)

    The optional metadata that you apply to the resource to help you categorize and organize them.



14
15
16
17
18
19
20
21
22
23
24
25
# File 'clean_rooms_ml/cfn_training_dataset_props.rb', line 14

def initialize(name:, role_arn:, training_data:, description: nil, tags: nil)
  @name = name
  Jsii::Type.check_type(@name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "name")
  @role_arn = role_arn
  Jsii::Type.check_type(@role_arn, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "roleArn")
  @training_data = training_data
  Jsii::Type.check_type(@training_data, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImNvbGxlY3Rpb24iOnsiZWxlbWVudHR5cGUiOnsidW5pb24iOnsidHlwZXMiOlt7ImZxbiI6ImF3cy1jZGstbGliLklSZXNvbHZhYmxlIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfY2xlYW5yb29tc21sLkNmblRyYWluaW5nRGF0YXNldC5EYXRhc2V0UHJvcGVydHkifV19fSwia2luZCI6ImFycmF5In19XX19")), "trainingData")
  @description = description
  Jsii::Type.check_type(@description, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "description") unless @description.nil?
  @tags = tags.is_a?(Array) ? tags.map { |jsii_v0| jsii_v0.is_a?(Hash) ? ::AWSCDK::CfnTag.new(**jsii_v0.transform_keys(&:to_sym)) : jsii_v0 } : tags
  Jsii::Type.check_type(@tags, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7ImZxbiI6ImF3cy1jZGstbGliLkNmblRhZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "tags") unless @tags.nil?
end

Instance Attribute Details

#descriptionString? (readonly)

The description of the training dataset.



50
51
52
# File 'clean_rooms_ml/cfn_training_dataset_props.rb', line 50

def description
  @description
end

#nameString (readonly)

The name of the training dataset.



31
32
33
# File 'clean_rooms_ml/cfn_training_dataset_props.rb', line 31

def name
  @name
end

#role_arnString (readonly)

The ARN of the IAM role that Clean Rooms ML can assume to read the data referred to in the dataSource field of each dataset.

Passing a role across accounts is not allowed. If you pass a role that isn't in your account, you get an AccessDeniedException error.



38
39
40
# File 'clean_rooms_ml/cfn_training_dataset_props.rb', line 38

def role_arn
  @role_arn
end

#tagsArray<AWSCDK::CfnTag>? (readonly)

The optional metadata that you apply to the resource to help you categorize and organize them.

Each tag consists of a key and an optional value, both of which you define.

The following basic restrictions apply to tags:

  • Maximum number of tags per resource - 50.
  • For each resource, each tag key must be unique, and each tag key can have only one value.
  • Maximum key length - 128 Unicode characters in UTF-8.
  • Maximum value length - 256 Unicode characters in UTF-8.
  • If your tagging schema is used across multiple services and resources, remember that other services may have restrictions on allowed characters. Generally allowed characters are: letters, numbers, and spaces representable in UTF-8, and the following characters: + - = . _ : /


65
66
67
# File 'clean_rooms_ml/cfn_training_dataset_props.rb', line 65

def tags
  @tags
end

#training_dataAWSCDK::IResolvable, Array<AWSCDK::IResolvable, AWSCDK::CleanRoomsML::CfnTrainingDataset::DatasetProperty> (readonly)

An array of information that lists the Dataset objects, which specifies the dataset type and details on its location and schema.

You must provide a role that has read access to these tables.



45
46
47
# File 'clean_rooms_ml/cfn_training_dataset_props.rb', line 45

def training_data
  @training_data
end

Class Method Details

.jsii_propertiesObject



67
68
69
70
71
72
73
74
75
# File 'clean_rooms_ml/cfn_training_dataset_props.rb', line 67

def self.jsii_properties
  {
    :name => "name",
    :role_arn => "roleArn",
    :training_data => "trainingData",
    :description => "description",
    :tags => "tags",
  }
end

Instance Method Details

#to_jsiiObject



77
78
79
80
81
82
83
84
85
86
87
# File 'clean_rooms_ml/cfn_training_dataset_props.rb', line 77

def to_jsii
  result = {}
  result.merge!({
    "name" => @name,
    "roleArn" => @role_arn,
    "trainingData" => @training_data,
    "description" => @description,
    "tags" => @tags,
  })
  result.compact
end