Exemplo n.º 1
0
 protected UnrealAgent(IUnrealAgentLogger log, string engineRoot, string gameRoot)
 {
     this.engineRoot = engineRoot;
     this.gameRoot   = gameRoot;
     this.agentFile  = Path.Combine(gameRoot, ".monoue-ide");
     this.Log        = log;
 }
Exemplo n.º 2
0
        //ensures exceptions are observed
        static Task <T> LogExceptions <T>(IUnrealAgentLogger log, Task <T> task)
        {
            task.ContinueWith(t =>
            {
                log.Error(t.Exception.Flatten().InnerException, "Error in task");
            }, TaskContinuationOptions.OnlyOnFaulted | TaskContinuationOptions.ExecuteSynchronously);

            return(task);
        }
Exemplo n.º 3
0
 public UnrealAgentConnection(
     IUnrealAgentLogger log,
     TcpClient client,
     Func <string, string[], bool> commandHandler,
     Action <UnrealAgentConnection> disposedHandler)
 {
     this.log             = log;
     this.client          = client;
     this.commandHandler  = commandHandler;
     this.disposedHandler = disposedHandler;
 }
Exemplo n.º 4
0
        protected UnrealAgentClient(IUnrealAgentLogger log, string engineRoot, string gameRoot, string config) : base(log, engineRoot, gameRoot)
        {
            Configuration = config;

            fsw = new FileSystemWatcher(Path.GetDirectoryName(AgentFile), Path.GetFileName(AgentFile));
            //ignore create, the file will be empty until changed
            fsw.Changed            += CheckAgent;
            fsw.Deleted            += CheckAgent;
            fsw.EnableRaisingEvents = true;

            CheckAgent();
        }
Exemplo n.º 5
0
 public VSUnrealAgent(IUnrealAgentLogger log, string engineRoot, string gameRoot, string config) : base(log, engineRoot, gameRoot, config)
 {
 }