static void Main(string[] args) { Context context = new Context(); ModifiedState modified = new ModifiedState(); modified.DoAction(context); }
static void Main(string[] args) { Context context = new Context(); ModifiedState modified = new ModifiedState(); modified.DoAction(context); DeleetedState deleted = new DeleetedState(); deleted.DoAction(context); Console.WriteLine(context.GetState()); Console.ReadLine(); }