Пример #1
0
 public static IAppCommand CreateKey(CreateKeyCommandContext context)
 {
     return new AppCommand<CreateKeyCommandContext>(context, ctx => {
         ctx.Key.CreateNewKey(ctx.Name);
     }, ctx => {
         ctx.Key.DeleteKey(ctx.Name);
     }) { Description = "Create key" };
 }
Пример #2
0
 public static IAppCommand CreateKey(CreateKeyCommandContext context)
 {
     return(new AppCommand <CreateKeyCommandContext>(context, ctx => {
         ctx.Key.CreateNewKey(ctx.Name);
     }, ctx => {
         ctx.Key.DeleteKey(ctx.Name);
     })
     {
         Description = "Create key"
     });
 }