コード例 #1
0
 /// <summary>
 ///     Constructor for Interactive Console.
 ///     Starts the Memory Cache, Draw Screen, Pipe Server, Task Engine,
 ///     and Log to Interactive Console
 /// </summary>
 /// <param name="memoryCache">The Memory Cache Service to set</param>
 /// <param name="drawScreen">The Draw Screen Service to set</param>
 /// <param name="pipeServer">The Pipe Server Service to set</param>
 /// <param name="taskEngine">The Task Engine Service to set</param>
 /// <param name="loggerService">
 ///     The Interactive Log Service
 ///     to set
 /// </param>
 /// <param name="logToInteractiveConsole"></param>
 public InteractiveConsoleService(IMemoryCache memoryCache,
                                  IDrawScreen drawScreen, IPipeService pipeServer,
                                  ITaskService taskEngine,
                                  ILoggerService loggerService)
 {
     _memoryCache   = memoryCache;
     _drawScreen    = drawScreen;
     _pipeService   = pipeServer;
     _taskService   = taskEngine;
     _loggerService = loggerService;
     _target        = LogManager.Configuration.FindTargetByName <MemoryTarget>("logMemory");
     _memoryCache.Set(SERVICE_MEMORY, true);
 }
コード例 #2
0
 /// <summary>
 ///     Constructor for Interactive CLI
 ///     Logger. Sets the Draw Screen Service and in memory location of the
 ///     log
 /// </summary>
 /// <param name="drawScreen">The Draw Screen Service to set</param>
 public LogToInteractiveConsole(IDrawScreen drawScreen)
 {
     _drawScreen = drawScreen;
     _target     = LogManager.Configuration.FindTargetByName <MemoryTarget>("logMemory");
     PipeServer  = new PipeServer(PIPE_NAME);
 }