1010[ ![ Open Source Love] ( https://badges.frapsoft.com/os/v1/open-source.svg?v=102 )] ( https://opensource.org/licenses/Apache-2.0 )
1111[ ![ License] ( https://img.shields.io/badge/license-Apache%202.0-blue.svg )] ( https://github.com/amitshekhariitbhu/Android-Debug-Database/blob/master/LICENSE )
1212
13- ## Android Debug Database is a powerful library for debugging databases and shared preferences in Android applications.
13+ ## Android Debug Database is a powerful library for debugging databases and shared preferences in Android applications
1414
15- ### Android Debug Database allows you to view databases and shared preferences directly in your browser in a very simple way.
15+ ### Android Debug Database allows you to view databases and shared preferences directly in your browser in a very simple way
1616
1717### What can Android Debug Database do?
18+
1819* See all the databases.
1920* See all the data in the shared preferences used in your application.
2021* Run any sql query on the given database to update and delete your data.
3031
3132### All these features work without rooting your device -> No need of rooted device
3233
33- ### Check out another awesome library for fast and simple networking in Android.
34+ ### Check out another awesome library for fast and simple networking in Android
35+
3436* [ Fast Android Networking Library] ( https://github.com/amitshekhariitbhu/Fast-Android-Networking )
3537
3638### Using Android Debug Database Library in your application
39+
3740Add this to your app's build.gradle
41+
3842``` groovy
39- debugImplementation 'com.amitshekhar.android:debug-db:1.0.4'
43+ debugImplementation 'com.amitshekhar.android:debug-db:1.0.5'
44+ ```
45+
46+ Using the Android Debug Database with encrypted database
47+
48+ ``` groovy
49+ debugImplementation 'com.amitshekhar.android:debug-db-encrypt:1.0.5'
4050```
4151
4252Use ` debugImplementation ` so that it will only compile in your debug build and not in your release build.
@@ -50,10 +60,11 @@ That’s all, just start the application, you will see in the logcat an entry li
5060Now open the provided link in your browser.
5161
5262Important:
53- - Your Android phone and laptop should be connected to the same Network (Wifi or LAN).
54- - If you are using it over usb, run ` adb forward tcp:8080 tcp:8080 `
5563
56- Note : If you want use different port other than 8080.
64+ * Your Android phone and laptop should be connected to the same Network (Wifi or LAN).
65+ * If you are using it over usb, run ` adb forward tcp:8080 tcp:8080 `
66+
67+ Note : If you want use different port other than 8080.
5768 In the app build.gradle file under buildTypes do the following change
5869
5970``` groovy
@@ -62,23 +73,25 @@ debug {
6273}
6374```
6475
65-
66-
67-
6876You will see something like this :
6977
7078### Seeing values
79+
7180<img src=https://raw.githubusercontent.com/amitshekhariitbhu/Android-Debug-Database/master/assets/debugdb.png >
7281
7382### Editing values
83+
7484<img src=https://raw.githubusercontent.com/amitshekhariitbhu/Android-Debug-Database/master/assets/debugdb_edit.png >
7585
7686### Working with emulator
77- - Android Default Emulator: Run the command in the terminal - ` adb forward tcp:8080 tcp:8080 ` and open http://localhost:8080
78- - Genymotion Emulator: Enable bridge from configure virtual device (option available in genymotion)
87+
88+ * Android Default Emulator: Run the command in the terminal - ` adb forward tcp:8080 tcp:8080 ` and open http://localhost:8080
89+ * Genymotion Emulator: Enable bridge from configure virtual device (option available in genymotion)
7990
8091### Getting address with toast, in case you missed the address log in logcat
92+
8193As this library is auto-initialize, if you want to get the address log, add the following method and call (we have to do like this to avoid build error in release build as this library will not be included in the release build) using reflection.
94+
8295``` java
8396public static void showDebugDBAddressLogToast(Context context) {
8497 if (BuildConfig . DEBUG ) {
@@ -95,7 +108,9 @@ public static void showDebugDBAddressLogToast(Context context) {
95108```
96109
97110### Adding custom database files
111+
98112As this library is auto-initialize, if you want to debug custom database files, add the following method and call
113+
99114``` java
100115public static void setCustomDatabaseFiles(Context context) {
101116 if (BuildConfig . DEBUG ) {
@@ -117,7 +132,9 @@ public static void setCustomDatabaseFiles(Context context) {
117132```
118133
119134### Adding InMemory Room databases
135+
120136As this library is auto-initialize, if you want to debug inMemory Room databases, add the following method and call
137+
121138``` java
122139public static void setInMemoryRoomDatabases(SupportSQLiteDatabase . .. database) {
123140 if (BuildConfig . DEBUG ) {
@@ -137,23 +154,27 @@ public static void setInMemoryRoomDatabases(SupportSQLiteDatabase... database) {
137154```
138155
139156### Find this project useful ? :heart :
157+
140158* Support it by clicking the :star : button on the upper right of this page. :v :
141159
142160### TODO
161+
143162* Simplify emulator issue [ Issue Link] ( https://github.com/amitshekhariitbhu/Android-Debug-Database/issues/6 )
144163* And of course many more features and bug fixes.
145164
146165### [ Check out Mindorks awesome open source projects here] ( https://mindorks.com/open-source-projects )
147166
148167### Contact - Let's become friends
149- - [ Twitter] ( https://twitter.com/amitiitbhu )
150- - [ Github] ( https://github.com/amitshekhariitbhu )
151- - [ Medium] ( https://medium.com/@amitshekhar )
152- - [ Facebook] ( https://www.facebook.com/amit.shekhar.iitbhu )
168+
169+ * [ Twitter] ( https://twitter.com/amitiitbhu )
170+ * [ GitHub] ( https://github.com/amitshekhariitbhu )
171+ * [ Medium] ( https://medium.com/@amitshekhar )
172+ * [ Facebook] ( https://www.facebook.com/amit.shekhar.iitbhu )
153173
154174### License
175+
155176```
156- Copyright (C) 2016 Amit Shekhar
177+ Copyright (C) 2019 Amit Shekhar
157178 Copyright (C) 2011 Android Open Source Project
158179
159180 Licensed under the Apache License, Version 2.0 (the "License");
@@ -170,5 +191,6 @@ public static void setInMemoryRoomDatabases(SupportSQLiteDatabase... database) {
170191```
171192
172193### Contributing to Android Debug Database
194+
173195All pull requests are welcome, make sure to follow the [ contribution guidelines] ( CONTRIBUTING.md )
174196when you submit pull request.
0 commit comments