add command pattern