Ejemplo n.º 1
0
 public void RunCommand(iCommand newCommand, CommandSettings commandSet)
 {
     try
     {
         newCommand.Execute(commandSet);
     }
     catch (Exception ex)
     {
         throw new Exception("RunCommand error: " + ex.Message);
     }
 }
Ejemplo n.º 2
0
        public void AutoRun()
        {
            try
            {
                if (_engineSettings.Commands != null)
                {
                    Assembly assem = System.Reflection.Assembly.GetExecutingAssembly();

                    foreach (CommandSettings commandSet in _engineSettings.Commands)
                    {
                        Type     type           = assem.GetType("DHI.Generic.NetCDF.MIKE.Commands." + commandSet.CommandName);
                        iCommand autoRunCommand = (iCommand)assem.CreateInstance(type.Namespace + "." + type.Name);
                        autoRunCommand.Execute(commandSet);
                    }
                }
            }
            catch (Exception ex)
            {
                throw new Exception("AutoRun error: " + ex.Message);
            }
        }
Ejemplo n.º 3
0
 public void ExecuteCommand()
 {
     command.Execute();
 }