Category Archives: Android

Read SMS directly from Sqlite database in Android

Today I wanted to extract the SMS content out of the android SMS application SQLite database using ADB. NOTE: The whole procedure was tested on a rooted phone running Cyanogenmod Android. It may not work on unrooted phones So I … Continue reading

Posted in Android, Databases, Linux, SQLite | Tagged , , , , , , , , , , , , | 28 Comments

Java String Util Class

Unfortunately, Java does not include a proper String manipulation class in its Java SE SDK. I really do not understand why… However, we see so many implementations and libraries including the distinguished Apache Commons Lang and android.text package. If your … Continue reading

Posted in Android, Java | Tagged , , , , , , | Leave a comment

Java Calculate Orthodox Easter Date

Today I wondered if there is an algorithm to calculate the date of Orthodox Easter. After some searching in the web I found the algorithm and converted it to Java code.

Posted in Android, Java | Tagged , , , | Leave a comment

Extend SQLiteOpenHelper as a singleton class in Android

Update: 2012-07-27 Today I wanted to keep my DatabaseHelper class unique and public in all my activities. Till now I kept creating and destroying a DatabaseHelper object for each Activity I was bringing in foreground. Thanks to Konstantinos Vaggelakos post … Continue reading

Posted in Android, Databases | Tagged , , , , | 5 Comments

Launch Logcat programmatically in Android

Today I wanted to write logcat output to a file while my application is running. To do so I executed the following code: To execute logcat process we are obliged to add uses permission in AndroidManifest.xml file. WARNING!! 1. This … Continue reading

Posted in Android, Java | Tagged , , , | Leave a comment

Android pre-populated Database

Today I am going to show you how to create an android application which comes with a pre-populated database. The database file has to be stored in assets directory. Every file that is stored in Assets directory is compressed. Prior … Continue reading

Posted in Android, Databases | Tagged , , , , | Leave a comment

Bluetooth adapter device name and MAC address in Android

Today I am going to show you how to get the bluetooth adapter deviceĀ  name (if exists) and MAC address programmatically in Android. Note that this code will not work in emulator as it does not support bluetooth. To avoid … Continue reading

Posted in Android, Java | Tagged , , , , , , , | 1 Comment