http://blog.csdn.net/gloryhero/article/details/47259583
e-mail frame diagram:
Email consists of 3 packages: Eamil, Exchagne, Unifiedemail.
These three packets are called each other. The specific relationship is as shown.
Email:
This package is mainly responsible for the user's login interface and account information storage, etc., in which, if there is no account in the phone, the email table will be responsible for the user input accounts information collected, and the collected information by passing to exchange and the server to interact with, Verify the correctness of the user's account information. Also, in this package, local storage is created, and the information that the server synchronizes is inserted into the local database via Emailprovider. Also, when a user logs on to an account successfully, the user's actions on the mailbox also update the database through the provider, synchronizing the information in the database with the server through Exchange.
Exchagne:
This package is primarily responsible for interacting with the server side. It involves verifying the user account, obtaining the mailbox information flow from the server side, and parsing the data stream with the parse class, which is then inserted into the local database by provider after parsing is completed. At the same time, when the user updates the local database, Exchagne will also feed the updated information to the server side via HTTP, thus synchronizing the server-side and client mailbox account information.
Unifiedemail:
This package and the user's direct operation Hook, it is the user and the mailbox to interact with the main place, in this package, the user can realize the view mailbox the folder, the mail information, downloads the attachment, sends the message and so on the information, when the user realizes an action in the package, the information will update in the email database in real time, When the information in the database changes, the changed content is synchronized with the server via Exchagne.
Some of the self-knowledge about Android native email