public ExceptionThrownStopReason(CorDebug.CorAppDomain appDomain, CorDebug.CorThread thread, CorDebug.CorFrame frame, int offset, CorDebugExceptionCallbackType eventType, int flags) { m_appDomain = appDomain; m_thread = thread; m_frame = frame; m_offset = offset; m_eventtype = eventType; m_flags = flags; }
private MDbgValue[] InternalGetFields() { var al = new ArrayList(); //dereference && (unbox); CorDebug.CorValue value = Dereference(CorValue); if (value == null) { throw new MDbgValueException("null value"); } Unbox(ref value); CorDebug.CorObjectValue ov = value.CastToObjectValue(); CorDebug.CorType cType = ov.ExactType; CorDebug.CorFrame cFrame = null; if (Process.Threads.HaveActive) { // we need a current frame to display thread local static values if (Process.Threads.Active.HaveCurrentFrame) { cFrame = Process.Threads.Active.CurrentFrame.CorFrame; } } MDbgModule classModule; // initialization CorDebug.CorClass corClass = ov.Class; classModule = Process.Modules.Lookup(corClass.Module); // iteration through class hierarchy do { Type classType; //int parentToken; classType = classModule.Importer.GetType(corClass.Token); //classModule.Importer.GetTypeNameFromDef(classToken,out parentToken); foreach (MetadataFieldInfo fi in classType.GetFields()) { CorValue fieldValue = null; try { if (fi.IsLiteral) { fieldValue = null; // for now we just hide the constant fields. continue; } else if (fi.IsStatic) { fieldValue = cType.GetStaticFieldValue(fi.MetadataToken, cFrame); } else // we are asuming normal field value // GetFieldValueForTYpe Supersedes GetFieldValue // Will replace when all issues are resolved. //fieldValue = ov.GetFieldValueForType(cType, (uint)fi.Token); { fieldValue = ov.GetFieldValue(corClass, fi.MetadataToken); } } catch (COMException) { // we won't report any problems. } al.Add(new MDbgValue(Process, fi.Name, fieldValue)); } cType = cType.Base; if (cType == null) { break; } corClass = cType.Class; classModule = Process.Modules.Lookup(corClass.Module); } while (true); return((MDbgValue[])al.ToArray(typeof(MDbgValue))); }
public ExceptionThrownStopReason(CorDebug.CorAppDomain appDomain, CorDebug.CorThread thread, CorDebug.CorFrame frame, int offset, CorDebugExceptionCallbackType eventType, int flags, bool exceptionEnhancedOn) { m_appDomain = appDomain; m_thread = thread; m_frame = frame; m_offset = offset; m_eventtype = eventType; m_flags = flags; m_exceptionEnhancedOn = exceptionEnhancedOn; }
public UnhandledExceptionThrownStopReason(CorDebug.CorAppDomain appDomain, CorDebug.CorThread thread, CorDebug.CorFrame frame, int offset, CorDebugExceptionCallbackType eventType, int flags) : base(appDomain, thread, frame, offset, eventType, flags) { }