toRuntime method

Runtime toRuntime()

Implementation

Runtime toRuntime() {
  switch (this) {
    case 'nodejs':
      return Runtime.nodejs;
    case 'nodejs4.3':
      return Runtime.nodejs4_3;
    case 'nodejs6.10':
      return Runtime.nodejs6_10;
    case 'nodejs8.10':
      return Runtime.nodejs8_10;
    case 'nodejs10.x':
      return Runtime.nodejs10X;
    case 'nodejs12.x':
      return Runtime.nodejs12X;
    case 'java8':
      return Runtime.java8;
    case 'java8.al2':
      return Runtime.java8Al2;
    case 'java11':
      return Runtime.java11;
    case 'python2.7':
      return Runtime.python2_7;
    case 'python3.6':
      return Runtime.python3_6;
    case 'python3.7':
      return Runtime.python3_7;
    case 'python3.8':
      return Runtime.python3_8;
    case 'dotnetcore1.0':
      return Runtime.dotnetcore1_0;
    case 'dotnetcore2.0':
      return Runtime.dotnetcore2_0;
    case 'dotnetcore2.1':
      return Runtime.dotnetcore2_1;
    case 'dotnetcore3.1':
      return Runtime.dotnetcore3_1;
    case 'nodejs4.3-edge':
      return Runtime.nodejs4_3Edge;
    case 'go1.x':
      return Runtime.go1X;
    case 'ruby2.5':
      return Runtime.ruby2_5;
    case 'ruby2.7':
      return Runtime.ruby2_7;
    case 'provided':
      return Runtime.provided;
    case 'provided.al2':
      return Runtime.providedAl2;
  }
  throw Exception('$this is not known in enum Runtime');
}