KUNAI Static Analyzer
Kunai is a library for doing static binary analysis of Dalvik.
Loading...
Searching...
No Matches
Classes | Public Member Functions | List of all members
KUNAI::DEX::ClassDef Class Reference

Definition of class with all the ids and offsets for all the other data. More...

#include <classes.hpp>

Classes

struct  classdefstruct_t
 Definition of offsets and IDs. More...
 

Public Member Functions

 ClassDef ()=default
 Constructor of ClassDef.
 
 ~ClassDef ()=default
 Destructor of ClassDef.
 
void parse_class_def (stream::KunaiStream *stream, Strings *strings, Types *types, Fields *fields, Methods *methods)
 Parse the current ClassDef for that we will parse the classdef_t structure, and then all the other fields.
 
const classdefstruct_tget_class_def_struct () const
 Get a constant reference to the classdefstruct_t of the class, this structure contains information about the class.
 
classdefstruct_tget_class_def_struct ()
 Get a reference to the classdefstruct_t of the class, this structure contains information about the class.
 
DVMClassget_class_idx ()
 Get a pointer to the DVMClass of the current class.
 
TYPES::access_flags get_access_flags () const
 Get the access flags of the current class.
 
DVMClassget_superclass ()
 Get a pointer to the DVMClass of the super class of the current one.
 
const std::string & get_source_file () const
 Get a constant reference to the string with the source file.
 
const std::vector< DVMClass * > & get_interfaces () const
 Get a constant reference to the vector with the interfaces implemented.
 
std::vector< DVMClass * > & get_interfaces ()
 Get a reference to the vector with the interfaces implemented.
 
const ClassDataItemget_class_data_item () const
 Get a constant reference to the class data item.
 
ClassDataItemget_class_data_item ()
 Get a reference to the class data item.
 

Detailed Description

Definition of class with all the ids and offsets for all the other data.

Member Function Documentation

◆ get_access_flags()

TYPES::access_flags KUNAI::DEX::ClassDef::get_access_flags ( ) const
inline

Get the access flags of the current class.

Returns

◆ get_class_data_item() [1/2]

ClassDataItem & KUNAI::DEX::ClassDef::get_class_data_item ( )
inline

Get a reference to the class data item.

Returns
reference to the class data item

◆ get_class_data_item() [2/2]

const ClassDataItem & KUNAI::DEX::ClassDef::get_class_data_item ( ) const
inline

Get a constant reference to the class data item.

Returns
constant reference to the class data item

◆ get_class_def_struct() [1/2]

classdefstruct_t & KUNAI::DEX::ClassDef::get_class_def_struct ( )
inline

Get a reference to the classdefstruct_t of the class, this structure contains information about the class.

Returns
reference to classdefstruct_t structure

◆ get_class_def_struct() [2/2]

const classdefstruct_t & KUNAI::DEX::ClassDef::get_class_def_struct ( ) const
inline

Get a constant reference to the classdefstruct_t of the class, this structure contains information about the class.

Returns
constant reference to classdefstruct_t structure

◆ get_class_idx()

DVMClass * KUNAI::DEX::ClassDef::get_class_idx ( )
inline

Get a pointer to the DVMClass of the current class.

Returns
pointer to DVMClass of current class

◆ get_interfaces() [1/2]

std::vector< DVMClass * > & KUNAI::DEX::ClassDef::get_interfaces ( )
inline

Get a reference to the vector with the interfaces implemented.

Returns
reference to interfaces

◆ get_interfaces() [2/2]

const std::vector< DVMClass * > & KUNAI::DEX::ClassDef::get_interfaces ( ) const
inline

Get a constant reference to the vector with the interfaces implemented.

Returns
constant reference to interfaces

◆ get_source_file()

const std::string & KUNAI::DEX::ClassDef::get_source_file ( ) const
inline

Get a constant reference to the string with the source file.

Returns
constant reference to source file string

◆ get_superclass()

DVMClass * KUNAI::DEX::ClassDef::get_superclass ( )
inline

Get a pointer to the DVMClass of the super class of the current one.

Returns
pointer to DVMClass of the super class

◆ parse_class_def()

void KUNAI::DEX::ClassDef::parse_class_def ( stream::KunaiStream stream,
Strings strings,
Types types,
Fields fields,
Methods methods 
)

Parse the current ClassDef for that we will parse the classdef_t structure, and then all the other fields.

Parameters
streamstream with DEX file currently parsed
stringsstrings of the DEX file
typestypes of the DEX file
fieldsfields of the DEX file
methodsmethods of the DEX file

The documentation for this class was generated from the following file: