Struct capstone::Capstone [] [src]

pub struct Capstone { /* fields omitted */ }

An instance of the capstone disassembler

Methods

impl Capstone
[src]

[src]

Create a new instance of the decompiler using the builder pattern interface. This is the recommended interface to Capstone.

use capstone::prelude::*;
let cs = Capstone::new().x86().mode(arch::x86::ArchMode::Mode32).build();

[src]

Create a new instance of the decompiler using the "raw" interface. The user must ensure that only sensical Arch/Mode combinations are used.

use capstone::{Arch, Capstone, NO_EXTRA_MODE, Mode};
let cs = Capstone::new_raw(Arch::X86, Mode::Mode64, NO_EXTRA_MODE, None);
assert!(cs.is_ok());

[src]

Disassemble all instructions in buffer

[src]

Disassemble count instructions in code

[src]

Set extra modes in addition to normal mode

[src]

Set the assembly syntax (has no effect on some platforms)

[src]

Sets the engine's disassembly mode. Be careful, various combinations of modes aren't supported See the capstone-sys documentation for more information.

[src]

Controls whether to capstone will generate extra details about disassembled instructions.

Pass true to enable detail or false to disable detail.

[src]

Converts a register id reg_id to a String containing the register name.

[src]

Converts an instruction id insn_id to a String containing the instruction name.

Note: This function ignores the current syntax and uses the default syntax.

[src]

Converts a group id group_id to a String containing the group name.

[src]

Returns Detail structure for a given instruction

Requires:

  1. Instruction was created with detail enabled
  2. Skipdata is disabled
  3. Capstone was not compiled in diet mode

[src]

Returns whether the instruction insn belongs to the group with id group_id.

[src]

Returns groups ids to which an instruction belongs.

[src]

Checks if an instruction implicitly reads a register with id reg_id.

[src]

Returns list of ids of registers that are implicitly read by instruction insn.

[src]

Checks if an instruction implicitly writes to a register with id reg_id.

[src]

Returns a list of ids of registers that are implicitly written to by the instruction insn.

[src]

Returns a tuple (major, minor) indicating the version of the capstone C library.

[src]

Returns whether the capstone library supports a given architecture.

[src]

Returns whether the capstone library was compiled in diet mode.

Trait Implementations

impl Debug for Capstone
[src]

[src]

Formats the value using the given formatter. Read more

impl Drop for Capstone
[src]

[src]

Executes the destructor for this type. Read more

Auto Trait Implementations

impl Send for Capstone

impl Sync for Capstone