Transfer the Android Market cache to the SD card sizeProgram!
A previous tutorialHow to clear System junk in Android G1
Now I have a better way to save memory, that is, to transfer the cache in the market to the SD card, so that
Android database SQLite writes SD card, androidsqlite
If the mobile phone does not have a root user, the database files cannot be viewed and debugging is not convenient.
The best way is to write the database into the SD card.
There are two changes:
1. In your helper class,
/DEMO.DB"; Database name public
static FINAL String table_name = "mytag";//datasheet name, a database can contain more than one datasheet, similar to the Sheet1,sheet2 in Excel
// Mydbhelper's constructor, we are concerned with the name database_name and version versions public
Mydbhelper {
Super database_name, NULL, VERSION);
Because if just a separate file name, the last created database file is stored in the phone's internal memory card (not
When the Android Application creates a database, it is established in the system by default/data/'application package name '/
Sometimes we need to build it in the SD card.
Advantages of SD card:
1. After the system restores the factory settings, reinstall the application. Da
files like your phone's own file system browser.Whether it's an internal SD card or an external SD card, it's a phone's external storage, and the phone's internal storage and external storage share the same device.Internal Storage Path:All apps installed to the phone will generate a package name folder in the Data/dat
Use SD card in Google Android SimulatorFrom the perspective of this document, the android simulator allows us to use a disk image in the FAT32 format as a simulation of the SD card. Today, I tried to record the process and share i
Android-read and write data to the SD card
// Write data to the SD card private void writeSDcard (String str) {try {// determine whether the SD card if (Environment. getExternalStorageS
I. Get permission to read the SD card Second, find the SD card directory/** * Environment.getexternalstoragedirectory () obtained: ", Mnt/sdcard" that found the root directory of the SD card */ private String path= Env
In the LAN, the implementation from the Android client to the mobile phone SD card files uploaded to the PC server side, and saved in the PC hard drive under the specified folder. At the same time, the PC-side hard disk file directory and the file description information stored in the MySQL database.1, the client key code:(1) Get the files on the
() + "/image.jpg"); bitmap newbitmap = imagetools. zoombitmap (bitmap, bitmap. getwidth ()/scale, bitmap. getheight ()/scale); // because the bitmap memory usage is large, memory needs to be recycled here; otherwise, an out of Memory exception bitmap will be reported. recycle (); // display the processed image on the interface and save it to the local iv_image.setimagebitmap (newbitmap); imagetools. savephototosdcard (newbitmap, environment. getexternalstoragedirectory (). getabsolutepath (), S
path.Second, Android use log4j write log to sd card, dynamically modify the output file name1. Use the following code to set the output path, which is called in the Init method aboveprivate static String Getoutputpath (context context, string name) {String RootPath = Getsdcardpath (context); StringBuilder fileName = new StringBuilder (); Phone model Filen
This article is translated from https://www.securecoding.cert.org/confluence/display/java/DRD00-J.+Do+not+store+sensitive+information+on+ External+storage+%28sd+card%29+unless+encrypted+first, there are additional deletions.Android offers several options for saving persistent application data, one of which is external storage (/sdcard,/mnt/sdcard). The external storage contains a miniature or standard-sized SD
The example in this article describes how Android gets to listen for SD card status. Share to everyone for your reference. The specific analysis is as follows:
1. Register Storageeventlistener to monitor the SD card state that is the onstoragestatechanged () method, when th
This article describes the Android implementation to obtain the total capacity of SD card, available size, total memory capacity of the fuselage and the available size of the method. Share to everyone for your reference, specific as follows:
Maybe some students do not know that the system has been provided to obtain the total capacity of
Android CREATE Database call Sqliteopenhelper, generally do not directly operate Sqlitedatabase . is through Sqliteopenhelper to getpublic class Dbopenhelper extends Sqliteopenhelper {private static final int version = 1;//defines the database versionprivate static final String PATH = Environment. getExternalStorageDirectory (). GetPath ();Some don't have an SD card
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.