InstanceTypeSpecification.fromJson constructor
InstanceTypeSpecification.fromJson(
- Map<String, dynamic> json
)
Implementation
factory InstanceTypeSpecification.fromJson(Map<String, dynamic> json) {
return InstanceTypeSpecification(
bidPrice: json['BidPrice'] as String?,
bidPriceAsPercentageOfOnDemandPrice:
json['BidPriceAsPercentageOfOnDemandPrice'] as double?,
configurations: (json['Configurations'] as List?)
?.whereNotNull()
.map((e) => Configuration.fromJson(e as Map<String, dynamic>))
.toList(),
ebsBlockDevices: (json['EbsBlockDevices'] as List?)
?.whereNotNull()
.map((e) => EbsBlockDevice.fromJson(e as Map<String, dynamic>))
.toList(),
ebsOptimized: json['EbsOptimized'] as bool?,
instanceType: json['InstanceType'] as String?,
weightedCapacity: json['WeightedCapacity'] as int?,
);
}