Exemplo n.º 1
0
        public UIBuildFeedbackSink(IOutputCategory messageView, IStatusBarService statusBarService)
        {
            Debug.Assert(messageView != null);
            Debug.Assert(statusBarService != null);

            this.messageView      = messageView;
            this.statusBarService = statusBarService;
        }
        public UIBuildFeedbackSink(IOutputCategory messageView, IStatusBarService statusBarService)
        {
            Debug.Assert(messageView != null);
            Debug.Assert(statusBarService != null);

            this.messageView = messageView;
            this.statusBarService = statusBarService;
        }
        public void OutputCategory_MessageViewCategoryAlreadyCreated_ReturnsOutputCategoryFromMessageViewCategory()
        {
            CreateCompilerMessageView();
            var             messageCategoryView = new FakeMessageCategoryView();
            IOutputCategory expectedCategory    = MockRepository.GenerateStub <IOutputCategory>();

            messageCategoryView.OutputCategory             = expectedCategory;
            fakeCompilerMessageView.GetExistingReturnValue = messageCategoryView;
            CreateView(fakeCompilerMessageView);

            IOutputCategory outputCategory = view.OutputCategory;

            Assert.AreEqual(expectedCategory, outputCategory);
        }
Exemplo n.º 4
0
        public async Task <int> RunInOutputPadAsync(IOutputCategory outputCategory, string program, params string[] arguments)
        {
            RedirectStandardOutputAndErrorToSingleStream = true;
            Start(program, arguments);
            StringBuilder printedCommandLine = new StringBuilder();

            if (WorkingDirectory != null)
            {
                printedCommandLine.Append(WorkingDirectory);
                printedCommandLine.Append("> ");
            }
            printedCommandLine.Append(CommandLine);
            outputCategory.AppendLine(printedCommandLine.ToString());

            using (TextReader reader = OpenStandardOutputReader()) {
                await reader.CopyToAsync(new MessageViewCategoryTextWriter(outputCategory));
            }
            await WaitForExitAsync();

            outputCategory.AppendLine(StringParser.Parse("${res:XML.MainMenu.ToolMenu.ExternalTools.ExitedWithCode} " + this.ExitCode));
            return(this.ExitCode);
        }
		public NAntMessageViewCategoryTextWriter(IOutputCategory target)
		{
			this.target = target;
			this.output = new StringBuilder();
		}
Exemplo n.º 6
0
		void IOutputPad.RemoveCategory(IOutputCategory category)
		{
			throw new NotImplementedException();
		}
Exemplo n.º 7
0
 void IOutputPad.RemoveCategory(IOutputCategory category)
 {
     throw new NotImplementedException();
 }
		public Task<int> RunInOutputPadAsync(IOutputCategory outputCategory, string program, params string[] arguments)
		{
			throw new NotImplementedException();
		}
Exemplo n.º 9
0
 public NAntMessageViewCategoryTextWriter(IOutputCategory target)
 {
     this.target = target;
     this.output = new StringBuilder();
 }
Exemplo n.º 10
0
 public MessageViewCategoryTextWriter(IOutputCategory target)
 {
     this.target = target;
 }
Exemplo n.º 11
0
		public async Task<int> RunInOutputPadAsync(IOutputCategory outputCategory, string program, params string[] arguments)
		{
			RedirectStandardOutputAndErrorToSingleStream = true;
			Start(program, arguments);
			StringBuilder printedCommandLine = new StringBuilder();
			if (WorkingDirectory != null) {
				printedCommandLine.Append(WorkingDirectory);
				printedCommandLine.Append("> ");
			}
			printedCommandLine.Append(CommandLine);
			outputCategory.AppendLine(printedCommandLine.ToString());
			
			using (TextReader reader = OpenStandardOutputReader()) {
				await reader.CopyToAsync(new MessageViewCategoryTextWriter(outputCategory));
			}
			await WaitForExitAsync();
			outputCategory.AppendLine(StringParser.Parse("${res:XML.MainMenu.ToolMenu.ExternalTools.ExitedWithCode} " + this.ExitCode));
			return this.ExitCode;
		}
		public MessageViewCategoryTextWriter(IOutputCategory target)
		{
			this.target = target;
		}
 public Task <int> RunInOutputPadAsync(IOutputCategory outputCategory, string program, params string[] arguments)
 {
     throw new NotImplementedException();
 }
Exemplo n.º 14
0
 public virtual void WriteToOutputPad(IOutputCategory category)
 {
     category.AppendLine(this.Message);
 }
 public virtual void WriteToOutputPad(IOutputCategory category)
 {
     category.AppendLine(this.Message);
 }