本文整理汇总了C#中Debugger类的典型用法代码示例。如果您正苦于以下问题:C# Debugger类的具体用法?C# Debugger怎么用?C# Debugger使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
Debugger类属于命名空间,在下文中一共展示了Debugger类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: LogError
protected void LogError(object message, Debugger.LogTypes logType = Debugger.LogTypes.Default, bool save = true)
{
if (log)
{
Debugger.LogError(message, gameObject, logType, save);
}
}
示例2: RegistersPanel
public RegistersPanel(Debugger debugger, RegisterClass registerClass)
{
InitializeComponent();
this.debugger = debugger;
this.registerClass = registerClass;
switch (registerClass) {
case RegisterClass.GuestGeneralPurpose:
this.Text = "GPR";
break;
case RegisterClass.GuestFloatingPoint:
this.Text = "FPR";
break;
case RegisterClass.GuestVector:
this.Text = "VR";
break;
case RegisterClass.HostGeneralPurpose:
this.Text = "x64";
break;
case RegisterClass.HostAvx:
this.Text = "AVX";
break;
default:
System.Diagnostics.Debug.Fail("Unhandled case: " + registerClass);
break;
}
}
示例3: DebugInspector
public DebugInspector( Debugger debugger )
{
Debug.Assert( debugger != null );
if( debugger == null )
throw new ArgumentNullException( "debugger" );
_debugger = debugger;
}
示例4: Debugger
public Debugger(ProcessStartInfo info, bool breakInMain)
{
Contract.Requires(info != null, "info is null");
ActiveObjects.Add(this);
m_thread = new DebuggerThread(this, breakInMain);
Boss boss = ObjectModel.Create("Application");
m_transcript = boss.Get<ITranscript>();
StepBy = StepSize.Line;
var options = new LaunchOptions();
// options.AgentArgs = "loglevel=1,logfile='/Users/jessejones/Source/Continuum/sdb.log'";
// We do this lame assignment to a static so that OnLaunched can be made a static
// method. Mono 2.6.7 doesn't GC asynchronously invoked delegates in a timely fashion
// (tho it does appear to collect them if more than ten stack up).
ms_debugger = this;
Unused.Value = VirtualMachineManager.BeginLaunch(info, Debugger.OnLaunched, options);
Broadcaster.Register("added breakpoint", this);
Broadcaster.Register("removing breakpoint", this);
Broadcaster.Register("toggled exceptions", this);
ms_running = true;
}
示例5: Awake
void Awake()
{
LevelIndex = Application.loadedLevel;
instance = this;
if (controlsManager == null) {
GameObject newCM = new GameObject("Control_Manager");
controlsManager = newCM.AddComponent<ControlsManager>();
newCM.transform.SetParent(this.transform);
}
// GET THE SCORE MANAGER //
if (scoreManager == null) {
GameObject newScM = new GameObject("Score_Manager");
scoreManager = newScM.AddComponent<ScoreManager>();
newScM.transform.SetParent(this.transform);
}
// LETS SETUP A SCENE //
if (sceneManager == null) {
GameObject newSM = new GameObject("Scene_Manager");
sceneManager = newSM.AddComponent<SceneManager>();
newSM.transform.SetParent(this.transform);
}
// link the debugger //
GameObject dbg = GameObject.Find ("Debugger");
debugger = dbg.GetComponent<Debugger> ();
}
示例6: ThreadManager
internal ThreadManager(Debugger debugger)
{
this.debugger = debugger;
thread_hash = Hashtable.Synchronized (new Hashtable ());
engine_hash = Hashtable.Synchronized (new Hashtable ());
processes = ArrayList.Synchronized (new ArrayList ());
pending_events = Hashtable.Synchronized (new Hashtable ());
last_pending_sigstop = DateTime.Now;
pending_sigstops = new Dictionary<int,DateTime> ();
address_domain = AddressDomain.Global;
wait_event = new ST.AutoResetEvent (false);
engine_event = new ST.ManualResetEvent (true);
ready_event = new ST.ManualResetEvent (false);
event_queue = new DebuggerEventQueue ("event_queue");
event_queue.DebugFlags = DebugFlags.Wait;
mono_debugger_server_global_init ();
wait_thread = new ST.Thread (new ST.ThreadStart (start_wait_thread));
wait_thread.IsBackground = true;
wait_thread.Start ();
inferior_thread = new ST.Thread (new ST.ThreadStart (start_inferior));
inferior_thread.IsBackground = true;
inferior_thread.Start ();
ready_event.WaitOne ();
}
示例7: Load
public override Program Load(Address addrLoad)
{
// First load the file as a PE Executable. This gives us a (writeable) image and
// the packed entry point.
var pe = CreatePeImageLoader();
var program = pe.Load(pe.PreferredBaseAddress);
var rr = pe.Relocate(pe.PreferredBaseAddress);
this.Image = program.Image;
this.ImageMap = program.ImageMap;
this.Architecture = (IntelArchitecture)program.Architecture;
var win32 = new Win32Emulator(program.Image, program.Platform, program.ImportReferences);
var state = (X86State)program.Architecture.CreateProcessorState();
var emu = new X86Emulator((IntelArchitecture) program.Architecture, program.Image, win32);
this.debugger = new Debugger(emu);
this.scriptInterpreter = new OllyLang();
this.scriptInterpreter.Host = new Host(this);
this.scriptInterpreter.Debugger = this.debugger;
emu.InstructionPointer = rr.EntryPoints[0].Address;
emu.WriteRegister(Registers.esp, (uint)Image.BaseAddress.ToLinear() + 0x1000 - 4u);
emu.BeforeStart += emu_BeforeStart;
emu.ExceptionRaised += emu_ExceptionRaised;
// Load the script.
LoadScript(Argument, scriptInterpreter.script);
emu.Start();
foreach (var ic in win32.InterceptedCalls)
{
program.InterceptedCalls.Add(Address.Ptr32(ic.Key), ic.Value);
}
return program;
}
示例8: Eval
public Eval(Debugger debugger, IAppDomain appDomain, DBG.DnEval eval) {
if (appDomain == null)
throw new InvalidOperationException("The thread has no owner AppDomain and can't be used to evaluate funcs");
this.debugger = debugger;
this.appDomain = appDomain;
this.eval = eval;
this.eval.SetNoTotalTimeout();
}
示例9: ThreadsPanel
public ThreadsPanel(Debugger debugger)
{
InitializeComponent();
this.debugger = debugger;
debugger.ThreadList.Changed += UpdateThreadList;
UpdateThreadList(debugger.ThreadList);
}
示例10: ILBreakpoint
public ILBreakpoint(Debugger debugger, ModuleId module, uint token, uint offset, Func<IILBreakpoint, bool> cond) {
this.debugger = debugger;
Module = module;
Token = token;
Offset = offset;
this.cond = cond ?? condAlwaysTrue;
isEnabled = true;
}
示例11: ModulesPanel
public ModulesPanel(Debugger debugger)
{
InitializeComponent();
this.debugger = debugger;
debugger.ModuleList.Changed += UpdateModulesList;
UpdateModulesList(debugger.ModuleList);
}
示例12: BreakpointsPanel
public BreakpointsPanel(Debugger debugger)
{
InitializeComponent();
this.debugger = debugger;
debugger.BreakpointList.Changed += UpdateBreakpointsList;
UpdateBreakpointsList(debugger.BreakpointList);
}
示例13: MainWindow
/// <summary>
/// Constructor
/// </summary>
public MainWindow()
{
List<SolidColorBrush> colorsList = ((Array)FindResource("Colors")).Cast<SolidColorBrush>().ToList();
List<BitmapImage> iconList = ((Array)FindResource("Icons")).Cast<BitmapImage>().ToList();
InitializeComponent();
confi = new Configuration(iconList,colorsList);
Debugger d = new Debugger(Debugger.ENVIORMENT.DEVELOPMENT);
//Debugger d = new Debugger(Debugger.ENVIORMENT.PRODUCTION);
}
示例14: GraphicalWatchControl
/// <summary>
/// Initializes a new instance of the <see cref="GraphicalWatchControl"/> class.
/// </summary>
public GraphicalWatchControl()
{
this.InitializeComponent();
m_dte = (DTE2)ServiceProvider.GlobalProvider.GetService(typeof(DTE));
m_debugger = m_dte.Debugger;
m_debuggerEvents = m_dte.Events.DebuggerEvents;
m_debuggerEvents.OnEnterBreakMode += DebuggerEvents_OnEnterBreakMode;
}
示例15: Create
public static ObjectValue Create(Debugger.Value value, int index, Dictionary<string, MemberInfo> memberFromName)
{
ObjectValue result = new ObjectValue(index, memberFromName);
// remember PermanentReference for expanding IEnumerable
Value permanentReference = value.GetPermanentReference();
result.PermanentReference = permanentReference;
return result;
}