Beispiel #1
0
        private async Task <int> Execute(object verb)
        {
            VerbBase verbBase = (VerbBase)verb;

            verbBase.CommandManager = commandManager;
            verbBase.UserInterface  = userInterface;
            verbBase.LifetimeScope  = lifetimeScope;
            if (verbBase is DynamicVerb dynamicVerb)
            {
                dynamicVerb.Definition = dynamicVerbFactory.GetCommandDefintionForVerb(dynamicVerb.GetType());
            }
            return(await verbBase.Execute().ConfigureAwait(false));
        }