예제 #1
0
 public ConsoleOutput Run(ConsoleInput input)
 {
     _logRepository.Insert(new Log { InputCode = input.Code, IpAddress = GetClientIp(Request) });
     //TODO: use Roslyn to compile and run
     var co = new Models.ConsoleOutput();
     co.Code = input.Code;
     co.Output = CompileHelper.CompileAndRun(input.Code, input.Language);
     co.Id = input.Id;
     return co;
 }
예제 #2
0
        public ConsoleOutput Run(ConsoleInput input)
        {
            _logRepository.Insert(new Log {
                InputCode = input.Code, IpAddress = GetClientIp(Request)
            });
            //TODO: use Roslyn to compile and run
            var co = new Models.ConsoleOutput();

            co.Code   = input.Code;
            co.Output = CompileHelper.CompileAndRun(input.Code, input.Language);
            co.Id     = input.Id;
            return(co);
        }