Class: AWSCDK::DataBrew::CfnProjectProps

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
data_brew/cfn_project_props.rb

Overview

Properties for defining a CfnProject.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(dataset_name:, name:, recipe_name:, role_arn:, sample: nil, tags: nil) ⇒ CfnProjectProps

Returns a new instance of CfnProjectProps.

Parameters:

  • dataset_name (String)

    The dataset that the project is to act upon.

  • name (String)

    The unique name of a project.

  • recipe_name (String)

    The name of a recipe that will be developed during a project session.

  • role_arn (String)

    The Amazon Resource Name (ARN) of the role that will be assumed for this project.

  • sample (AWSCDK::IResolvable, AWSCDK::DataBrew::CfnProject::SampleProperty, nil) (defaults to: nil)

    The sample size and sampling type to apply to the data.

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

    Metadata tags that have been applied to the project.



15
16
17
18
19
20
21
22
23
24
25
26
27
28
# File 'data_brew/cfn_project_props.rb', line 15

def initialize(dataset_name:, name:, recipe_name:, role_arn:, sample: nil, tags: nil)
  @dataset_name = dataset_name
  Jsii::Type.check_type(@dataset_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "datasetName")
  @name = name
  Jsii::Type.check_type(@name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "name")
  @recipe_name = recipe_name
  Jsii::Type.check_type(@recipe_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "recipeName")
  @role_arn = role_arn
  Jsii::Type.check_type(@role_arn, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "roleArn")
  @sample = sample.is_a?(Hash) ? ::AWSCDK::DataBrew::CfnProject::SampleProperty.new(**sample.transform_keys(&:to_sym)) : sample
  Jsii::Type.check_type(@sample, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19kYXRhYnJldy5DZm5Qcm9qZWN0LlNhbXBsZVByb3BlcnR5In1dfX0=")), "sample") unless @sample.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

#dataset_nameString (readonly)

The dataset that the project is to act upon.



34
35
36
# File 'data_brew/cfn_project_props.rb', line 34

def dataset_name
  @dataset_name
end

#nameString (readonly)

The unique name of a project.



39
40
41
# File 'data_brew/cfn_project_props.rb', line 39

def name
  @name
end

#recipe_nameString (readonly)

The name of a recipe that will be developed during a project session.



44
45
46
# File 'data_brew/cfn_project_props.rb', line 44

def recipe_name
  @recipe_name
end

#role_arnString (readonly)

The Amazon Resource Name (ARN) of the role that will be assumed for this project.



49
50
51
# File 'data_brew/cfn_project_props.rb', line 49

def role_arn
  @role_arn
end

#sampleAWSCDK::IResolvable, ... (readonly)

The sample size and sampling type to apply to the data.

If this parameter isn't specified, then the sample consists of the first 500 rows from the dataset.



56
57
58
# File 'data_brew/cfn_project_props.rb', line 56

def sample
  @sample
end

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

Metadata tags that have been applied to the project.



61
62
63
# File 'data_brew/cfn_project_props.rb', line 61

def tags
  @tags
end

Class Method Details

.jsii_propertiesObject



63
64
65
66
67
68
69
70
71
72
# File 'data_brew/cfn_project_props.rb', line 63

def self.jsii_properties
  {
    :dataset_name => "datasetName",
    :name => "name",
    :recipe_name => "recipeName",
    :role_arn => "roleArn",
    :sample => "sample",
    :tags => "tags",
  }
end

Instance Method Details

#to_jsiiObject



74
75
76
77
78
79
80
81
82
83
84
85
# File 'data_brew/cfn_project_props.rb', line 74

def to_jsii
  result = {}
  result.merge!({
    "datasetName" => @dataset_name,
    "name" => @name,
    "recipeName" => @recipe_name,
    "roleArn" => @role_arn,
    "sample" => @sample,
    "tags" => @tags,
  })
  result.compact
end