static void Main(string[] args) { var exampleToRun = ExamplesEnumeration.GetFromFile; switch (exampleToRun) { case ExamplesEnumeration.ShowJsonSerialization: SimpleJsonSerizalization.ShowJsonSerialization(); break; case ExamplesEnumeration.SerializerOptions: SimpleJsonSerizalization.ShowSerializerOptions(); break; case ExamplesEnumeration.CustomAttributes: SimpleJsonSerizalization.ShowSerializedAttributes(); break; case ExamplesEnumeration.Deserialize: JsonDesirealization.ShowDeserialization(); break; case ExamplesEnumeration.SaveToFile: SaveToFile.SaveJsonToFile(); break; case ExamplesEnumeration.GetFromFile: SaveToFile.GetFromFile(); break; } Console.Read(); }
static void Main(string[] args) { var exampleToRun = ExamplesEnumeration.ShowMethodsAttributes; switch (exampleToRun) { case ExamplesEnumeration.ShowMethodsAttributes: ExamplesRunner <Car> .ShowMethodsAttributes(new Car()); break; case ExamplesEnumeration.ShowAllAttributes: ExamplesRunner <Car> .ShowAllAttributes(new Car()); break; case ExamplesEnumeration.ShowJsonSerialization: SimpleJsonSerizalization.ShowJsonSerialization(); break; case ExamplesEnumeration.ShowJsonDesirealization: JsonDesirealization.ShowJsonDesirealization(); break; } Console.Read(); }