# Interface: com.pnfsoftware.jeb.core.units.code.asm.INativeDebuggerUnit

Definition of native code debuggers.

## Method: getBreakpoint
- parameter: `memoryAddress`, type: `long`
- return type: `com.pnfsoftware.jeb.core.units.code.debug.IDebuggerBreakpoint`

Description: Get the breakpoints set at the explicit memory address.
parameter: memoryAddress: memory address
return: the breakpoint or null on error or if not implemented

## Method: getMemory
- return type: `com.pnfsoftware.jeb.core.units.code.debug.IDebuggerVirtualMemory`

Description: Retrieve an VM object representing the memory of the target. Operations on that object are safe and will attempt to modify the state of the debuggee if it needs to.
return: debugger virtual memory, or null if unavailable

## Method: getProcessor
- return type: `com.pnfsoftware.jeb.core.units.code.asm.processor.IProcessor<? extends com.pnfsoftware.jeb.core.units.code.IInstruction>`

Description: Retrieve the processor associated with this debugger.
return: processor, or null if not applicable

## Method: readMemory
- parameter: `memoryAddress`, type: `long`
- parameter: `size`, type: `int`
- parameter: `dst`, type: `byte[]`
- parameter: `dstOffset`, type: `int`
- return type: `int`

Description: Read from memory. Optional method, supported only if the debugger allows direct memory access. If the memory cannot be read at the time of the call, the method should fail instead of attempting to modify the state of the debuggee to allow the read operation.
parameter: memoryAddress: source memory address
parameter: size: number of bytes to read
parameter: dst: destination buffer
parameter: dstOffset: destination buffer offset
return: number of bytes read, \-1 on error

## Method: setBreakpoint
- parameter: `memoryAddress`, type: `long`
- return type: `com.pnfsoftware.jeb.core.units.code.debug.IDebuggerBreakpoint`

Description: Same as [setBreakpoint\(memoryAddress, 0, 0\)](#setBreakpoint(long, int, int)).
parameter: memoryAddress: requested breakpoint address
return: the breakpoint or null on error or if not implemented

## Method: setBreakpoint
- parameter: `memoryAddress`, type: `long`
- parameter: `flags`, type: `int`
- parameter: `processorMode`, type: `int`
- return type: `com.pnfsoftware.jeb.core.units.code.debug.IDebuggerBreakpoint`

Description: Set a breakpoint at the explicit memory address. This method is valid only for targets supporting numerical addressing, such as physical processors.
parameter: memoryAddress: requested breakpoint address
parameter: flags: , refer to [IDebuggerBreakpoint](IDebuggerBreakpoint)
parameter: processorMode: optional [processor](IProcessor) mode \(see            `IProcessor.MODE_xxx` constant\)
return: the breakpoint or null on error or if not implemented

## Method: writeMemory
- parameter: `memoryAddress`, type: `long`
- parameter: `size`, type: `int`
- parameter: `src`, type: `byte[]`
- parameter: `srcOffset`, type: `int`
- return type: `int`

Description: Write to memory. Optional method, supported only if the debugger allows direct memory access. If the memory cannot be written at the time of the call, the method may attempt to modify the state of the debuggee to allow the write operation.
parameter: memoryAddress: destination memory address
parameter: size: number of bytes to write
parameter: src: source buffer
parameter: srcOffset: source buffer offset
return: number of bytes written, \-1 on error

