Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
try
{
Console.WriteLine("Enter entity type:");
var entytyType = (EntityType)Enum.Parse(typeof(EntityType), Console.ReadLine(), true);
Console.WriteLine("Enter new value:");
var modificationValue = Convert.ToInt32(Console.ReadLine());
var entityFactory = new EntityFactory();
var entity = entityFactory.GetEntityBasedOnType(entytyType);
var result = entity.GetNewValue(modificationValue);
Console.WriteLine(result);
Console.ReadLine();
}
catch (Exception e)
{
Console.WriteLine(e.Message);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment