reactosdbg/DebugProtocol/Breakpoint.cs
Art Yerkes 6030ecd415 A debugging shell for use with KDBG. Not perfect yet but it can display the
locals and stack trace at the place where reactos is stopped.

svn path=/trunk/tools/reactosdbg/; revision=759
2008-07-31 07:00:10 +00:00

37 lines
1.0 KiB
C#

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace DebugProtocol
{
public class Breakpoint
{
public enum BPType { Software, Hardware, WriteWatch, ReadWatch, AccessWatch };
public readonly BPType BreakpointType;
public readonly long Address;
public readonly int Length;
public Breakpoint(BPType type, long addr, int len)
{
BreakpointType = type;
Address = addr;
Length = len;
}
public override int GetHashCode()
{
return (int)(((int)BreakpointType) ^ Address ^ (Length << 28));
}
public override bool Equals(object other)
{
Breakpoint otherbp = other as Breakpoint;
if (otherbp == null) return false;
return
(otherbp.BreakpointType == BreakpointType) &&
(otherbp.Address == Address) &&
(otherbp.Length == Length);
}
}
}