toInstanceType method
Implementation
InstanceType toInstanceType() {
switch (this) {
case 'ml.t2.medium':
return InstanceType.mlT2Medium;
case 'ml.t2.large':
return InstanceType.mlT2Large;
case 'ml.t2.xlarge':
return InstanceType.mlT2Xlarge;
case 'ml.t2.2xlarge':
return InstanceType.mlT2_2xlarge;
case 'ml.t3.medium':
return InstanceType.mlT3Medium;
case 'ml.t3.large':
return InstanceType.mlT3Large;
case 'ml.t3.xlarge':
return InstanceType.mlT3Xlarge;
case 'ml.t3.2xlarge':
return InstanceType.mlT3_2xlarge;
case 'ml.m4.xlarge':
return InstanceType.mlM4Xlarge;
case 'ml.m4.2xlarge':
return InstanceType.mlM4_2xlarge;
case 'ml.m4.4xlarge':
return InstanceType.mlM4_4xlarge;
case 'ml.m4.10xlarge':
return InstanceType.mlM4_10xlarge;
case 'ml.m4.16xlarge':
return InstanceType.mlM4_16xlarge;
case 'ml.m5.xlarge':
return InstanceType.mlM5Xlarge;
case 'ml.m5.2xlarge':
return InstanceType.mlM5_2xlarge;
case 'ml.m5.4xlarge':
return InstanceType.mlM5_4xlarge;
case 'ml.m5.12xlarge':
return InstanceType.mlM5_12xlarge;
case 'ml.m5.24xlarge':
return InstanceType.mlM5_24xlarge;
case 'ml.c4.xlarge':
return InstanceType.mlC4Xlarge;
case 'ml.c4.2xlarge':
return InstanceType.mlC4_2xlarge;
case 'ml.c4.4xlarge':
return InstanceType.mlC4_4xlarge;
case 'ml.c4.8xlarge':
return InstanceType.mlC4_8xlarge;
case 'ml.c5.xlarge':
return InstanceType.mlC5Xlarge;
case 'ml.c5.2xlarge':
return InstanceType.mlC5_2xlarge;
case 'ml.c5.4xlarge':
return InstanceType.mlC5_4xlarge;
case 'ml.c5.9xlarge':
return InstanceType.mlC5_9xlarge;
case 'ml.c5.18xlarge':
return InstanceType.mlC5_18xlarge;
case 'ml.c5d.xlarge':
return InstanceType.mlC5dXlarge;
case 'ml.c5d.2xlarge':
return InstanceType.mlC5d_2xlarge;
case 'ml.c5d.4xlarge':
return InstanceType.mlC5d_4xlarge;
case 'ml.c5d.9xlarge':
return InstanceType.mlC5d_9xlarge;
case 'ml.c5d.18xlarge':
return InstanceType.mlC5d_18xlarge;
case 'ml.p2.xlarge':
return InstanceType.mlP2Xlarge;
case 'ml.p2.8xlarge':
return InstanceType.mlP2_8xlarge;
case 'ml.p2.16xlarge':
return InstanceType.mlP2_16xlarge;
case 'ml.p3.2xlarge':
return InstanceType.mlP3_2xlarge;
case 'ml.p3.8xlarge':
return InstanceType.mlP3_8xlarge;
case 'ml.p3.16xlarge':
return InstanceType.mlP3_16xlarge;
}
throw Exception('$this is not known in enum InstanceType');
}