{"ScriptPreparationCode":"var class1 = { GetImportantValue: () =\u003E 1 };\r\nvar class2 = { GetImportantValue: () =\u003E 2 };\r\nvar class3 = { GetImportantValue: () =\u003E 3 };\r\nvar class4 = { GetImportantValue: () =\u003E 4 };\r\nvar class5 = { GetImportantValue: () =\u003E 5 };\r\n\r\ngetImportantValueSwitch = (myClassEnum) =\u003E {\r\n switch (myClassEnum.type) {\r\n case \u0027MyClass1\u0027: return 1;\r\n case \u0027MyClass2\u0027: return 2;\r\n case \u0027MyClass3\u0027: return 3;\r\n case \u0027MyClass4\u0027: return 4;\r\n case \u0027MyClass5\u0027: return 5;\r\n }\r\n}\r\n\r\ngetImportantValuePolymorphism = (myClass) =\u003E myClass.GetImportantValue();\r\n","TestCases":[{"Name":"Polymorphism","Code":" getImportantValuePolymorphism(class1);\r\n getImportantValuePolymorphism(class2);\r\n getImportantValuePolymorphism(class3);\r\n getImportantValuePolymorphism(class4);\r\n getImportantValuePolymorphism(class5);","IsDeferred":false},{"Name":"Switch","Code":" getImportantValueSwitch({type: \u0027MyClass1\u0027});\r\n getImportantValueSwitch({type: \u0027MyClass2\u0027});\r\n getImportantValueSwitch({type: \u0027MyClass3\u0027});\r\n getImportantValueSwitch({type: \u0027MyClass4\u0027});\r\n getImportantValueSwitch({type: \u0027MyClass5\u0027});","IsDeferred":false}]}