"Original" Tinker Dex file format Dump tool tinker-dex-dump

Source: Internet
Author: User

Preface

Tinker is the launch of the hot Update Open source project, compared with other hot update scenarios with small patches, support classes, so, the replacement of resource files and other advantages. In the scheme of class substitution, the Dexdiff algorithm is developed independently, which makes the patch package become smaller. The resulting product of the DEXDIFF algorithm, while also using. dex as the format suffix, is two different formats than the Dex file in the actual virtual machine.

about Tinker-dex-dump

Tinker-dex-dump is a tool for Dexdiff-generated. dex format files to view their internal data. The main purpose is to help you have a more intuitive understanding of the Dex format generated by Dexdiff. If you use this tool to make it easier to understand tinker related principles, then the purpose of the tool is achieved, but also a personal tribute to Tinker. The tool has been uploaded to the Github,github address of Https://github.com/LaurenceYang/tinker-dex-dump

How to use Tinker-dex-dump

1. First download the Tinker-dex-dump.jar file

2. Execute by command line mode

command Format
 java -jar tinker-dex-dump.jar --dex *.dex [--header] [--section section-name]

--dex required option, followed by the Dex path to dump

--header options to display header area information

--section optional, Display section area information, followed by the sections name to be displayed

--section parameter list, the meaning of the parameter with its name
  • stringdata
  • TypeId
  • protoid
  • FieldID
  • methodid
  • ClassDef
  • typelist
  • Annotationsetreflist
  • annotationset
  • classdata
  • code
  • Debuginfo
  • annotation
  • staticvalue
  • annotationsdirectory
Example One: displaying header information
java -jar tinker-dex-dump.jar --dex classes.dex --header

Example two: displaying StringData area information
java -jar tinker-dex-dump.jar --dex classes.dex --section StringData

example Three: displaying Help information
java -jar tinker-dex-dump.jar --help

Tinker dex Format Reference

The Tinker Dex format consists of two main parts: the head and the list of operations for each section area, such as:

More about the Tinker Dex format can refer to the Dexpatchgenerator file of the Tinker project

For more Tinker source parsing articles, please refer to:

    • Android Hot update open source project Tinker source Parsing series one: Dex Hot update
    • Android Hot update open source project Tinker source Parsing Series II: Resource Hot update
    • Android Hot update open source project Tinker Source parsing system Three: so hot update
    • Android Hot update open source project Tinker Integration Practice Summary

Reprint please indicate the source of this article: http://www.cnblogs.com/yyangblog/p/6282118.html
More content Welcome to star author's github:https://github.com/laurenceyang/
If you find any questions or suggestions in this article, please feel free to contact me at any time.

"Original" Tinker Dex file format Dump tool tinker-dex-dump

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.