Class: AWSCDK::Batch::CfnConsumableResourceProps
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::Batch::CfnConsumableResourceProps
- Defined in:
- batch/cfn_consumable_resource_props.rb
Overview
Properties for defining a CfnConsumableResource.
Instance Attribute Summary collapse
-
#consumable_resource_name ⇒ String?
readonly
The name of the consumable resource.
-
#resource_type ⇒ String
readonly
Indicates whether the resource is available to be re-used after a job completes.
-
#tags ⇒ Hash{String => String}?
readonly
The tags that you apply to the consumable resource to help you categorize and organize your resources.
-
#total_quantity ⇒ Numeric
readonly
The total amount of the consumable resource that is available.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(resource_type:, total_quantity:, consumable_resource_name: nil, tags: nil) ⇒ CfnConsumableResourceProps
constructor
A new instance of CfnConsumableResourceProps.
- #to_jsii ⇒ Object
Constructor Details
#initialize(resource_type:, total_quantity:, consumable_resource_name: nil, tags: nil) ⇒ CfnConsumableResourceProps
Returns a new instance of CfnConsumableResourceProps.
13 14 15 16 17 18 19 20 21 22 |
# File 'batch/cfn_consumable_resource_props.rb', line 13 def initialize(resource_type:, total_quantity:, consumable_resource_name: nil, tags: nil) @resource_type = resource_type Jsii::Type.check_type(@resource_type, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "resourceType") @total_quantity = total_quantity Jsii::Type.check_type(@total_quantity, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "totalQuantity") @consumable_resource_name = consumable_resource_name Jsii::Type.check_type(@consumable_resource_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "consumableResourceName") unless @consumable_resource_name.nil? @tags = Jsii::Type.check_type(@tags, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7InByaW1pdGl2ZSI6InN0cmluZyJ9LCJraW5kIjoibWFwIn19")), "tags") unless @tags.nil? end |
Instance Attribute Details
#consumable_resource_name ⇒ String? (readonly)
The name of the consumable resource.
41 42 43 |
# File 'batch/cfn_consumable_resource_props.rb', line 41 def consumable_resource_name @consumable_resource_name end |
#resource_type ⇒ String (readonly)
Indicates whether the resource is available to be re-used after a job completes. Can be one of:.
REPLENISHABLENON_REPLENISHABLE
31 32 33 |
# File 'batch/cfn_consumable_resource_props.rb', line 31 def resource_type @resource_type end |
#tags ⇒ Hash{String => String}? (readonly)
The tags that you apply to the consumable resource to help you categorize and organize your resources.
Each tag consists of a key and an optional value. For more information, see Tagging your AWS Batch resources .
48 49 50 |
# File 'batch/cfn_consumable_resource_props.rb', line 48 def @tags end |
#total_quantity ⇒ Numeric (readonly)
The total amount of the consumable resource that is available.
36 37 38 |
# File 'batch/cfn_consumable_resource_props.rb', line 36 def total_quantity @total_quantity end |
Class Method Details
.jsii_properties ⇒ Object
50 51 52 53 54 55 56 57 |
# File 'batch/cfn_consumable_resource_props.rb', line 50 def self.jsii_properties { :resource_type => "resourceType", :total_quantity => "totalQuantity", :consumable_resource_name => "consumableResourceName", :tags => "tags", } end |
Instance Method Details
#to_jsii ⇒ Object
59 60 61 62 63 64 65 66 67 68 |
# File 'batch/cfn_consumable_resource_props.rb', line 59 def to_jsii result = {} result.merge!({ "resourceType" => @resource_type, "totalQuantity" => @total_quantity, "consumableResourceName" => @consumable_resource_name, "tags" => @tags, }) result.compact end |