msos.CommandExecutionContext.WriteInfoLine C# (CSharp) Method

WriteInfoLine() public method

public WriteInfoLine ( string format ) : void
format string
return void
        public void WriteInfoLine(string format, params object[] args)
        {
            Printer.WriteInfo(format + Environment.NewLine, args);
        }

Usage Example

示例#1
0
        private void PerformAutomaticAnalysis()
        {
            var threadToSwitchTo = _context.Runtime.ThreadWithActiveExceptionOrFirstThread();

            if (threadToSwitchTo.CurrentException != null)
            {
                _context.WriteInfoLine("The current thread has an exception; use !pe to view it.");
            }
            new SwitchThread()
            {
                ManagedThreadId = threadToSwitchTo.ManagedThreadId
            }.Execute(_context);

            if (_context.Runtime.OutOfMemoryExceptionOccurred)
            {
                _context.WriteInfoLine("There was an out-of-memory condition in this target:");
                var oomInfo = _context.Runtime.OutOfMemoryInformation;
                _context.WriteInfoLine("\tAn OOM occurred after GC {0} when trying to allocate {1}",
                                       oomInfo.GCNumber, oomInfo.AllocationSize.ToMemoryUnits());
                _context.WriteInfoLine("\t" + oomInfo.Reason);
            }
        }
All Usage Examples Of msos.CommandExecutionContext::WriteInfoLine