Class: AWSCDK::EC2::CfnLaunchTemplate::CreditSpecificationProperty
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::EC2::CfnLaunchTemplate::CreditSpecificationProperty
- Defined in:
- ec2/cfn_launch_template.rb
Overview
Specifies the credit option for CPU usage of a T2, T3, or T3a instance.
CreditSpecification is a property of AWS::EC2::LaunchTemplate LaunchTemplateData .
Instance Attribute Summary collapse
-
#cpu_credits ⇒ String?
readonly
The credit option for CPU usage of a T instance.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(cpu_credits: nil) ⇒ CreditSpecificationProperty
constructor
A new instance of CreditSpecificationProperty.
- #to_jsii ⇒ Object
Constructor Details
#initialize(cpu_credits: nil) ⇒ CreditSpecificationProperty
Returns a new instance of CreditSpecificationProperty.
1099 1100 1101 1102 |
# File 'ec2/cfn_launch_template.rb', line 1099 def initialize(cpu_credits: nil) @cpu_credits = cpu_credits Jsii::Type.check_type(@cpu_credits, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "cpuCredits") unless @cpu_credits.nil? end |
Instance Attribute Details
#cpu_credits ⇒ String? (readonly)
The credit option for CPU usage of a T instance.
Valid values: standard | unlimited
1110 1111 1112 |
# File 'ec2/cfn_launch_template.rb', line 1110 def cpu_credits @cpu_credits end |
Class Method Details
.jsii_properties ⇒ Object
1112 1113 1114 1115 1116 |
# File 'ec2/cfn_launch_template.rb', line 1112 def self.jsii_properties { :cpu_credits => "cpuCredits", } end |
Instance Method Details
#to_jsii ⇒ Object
1118 1119 1120 1121 1122 1123 1124 |
# File 'ec2/cfn_launch_template.rb', line 1118 def to_jsii result = {} result.merge!({ "cpuCredits" => @cpu_credits, }) result.compact end |