summaryrefslogtreecommitdiff
path: root/runtime/dex_file.h
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/dex_file.h')
-rw-r--r--runtime/dex_file.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/runtime/dex_file.h b/runtime/dex_file.h
index 14bde09ee4..28aeb1e490 100644
--- a/runtime/dex_file.h
+++ b/runtime/dex_file.h
@@ -590,6 +590,9 @@ class DexFile {
const DexFile::StringId& name,
const DexFile::TypeId& type) const;
+ uint32_t FindCodeItemOffset(const DexFile::ClassDef& class_def,
+ uint32_t dex_method_idx) const;
+
// Returns the declaring class descriptor string of a field id.
const char* GetFieldDeclaringClassDescriptor(const FieldId& field_id) const {
const DexFile::TypeId& type_id = GetTypeId(field_id.class_idx_);
@@ -1060,6 +1063,16 @@ class DexFile {
std::string* error_msg,
VerifyResult* verify_result = nullptr);
+
+ // Opens a .dex file at the given address, optionally backed by a MemMap
+ static std::unique_ptr<const DexFile> OpenMemory(const uint8_t* dex_file,
+ size_t size,
+ const std::string& location,
+ uint32_t location_checksum,
+ std::unique_ptr<MemMap> mem_map,
+ const OatDexFile* oat_dex_file,
+ std::string* error_msg);
+
DexFile(const uint8_t* base,
size_t size,
const std::string& location,