Andzu

Additional

Language
Java
Version
0.65 (Dec 8, 2017)
Created
Apr 10, 2017
Updated
Dec 8, 2017
Owner
isacan
Contributors
isacan
sergii-frost
2
Activity
Badge
Generate
Download
Source code
APK file

Promotion

Andzu

In-App Android Debugging Tool With Enhanced Logging, Networking Info, Crash reporting And More.

The debugger tool for Android developer. Display logs, network request, while using the app. Easy accessible with its bubble head button 🔘. Easy to integrate in any apps, to handle development or testing apps easier. First version, there is plenty of room for improvement.

Usage

  • Extend your Application class from "AndzuApp"
    public class App extends AndzuApp {
        @Override
        public void onCreate() {
            super.onCreate();
        }
    }
  • On Start Activity onCreate call permission for <= M or init Andzu from App class
    @Override
    public void onCreate() {
        super.onCreate();
        
        if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M && !Settings.canDrawOverlays(this)) {
         //If the draw over permission is not available open the settings screen
         //to grant the permission.
         Intent intent = new Intent(Settings.ACTION_MANAGE_OVERLAY_PERMISSION,
          Uri.parse("package:" + getPackageName()));
         startActivityForResult(intent, 2084);
            } else {
                 App.getInstance().initAndzu();
           }
    }
    
    @Override
        protected void onActivityResult(int requestCode, int resultCode, Intent data) {
     if (requestCode == 2084) {
         //Check if the permission is granted or not.
         if (resultCode == RESULT_OK) {
      App.getInstance().initAndzu();
         } else { //Permission is not available
         }
     } else {
         super.onActivityResult(requestCode, resultCode, data);
     }
        }
  • For Network Request Log addInterceptor "AndzuInterceptor"
    LoggingInterceptor interceptor = new LoggingInterceptor();
    
    OkHttpClient client = new OkHttpClient.Builder()
                    .addInterceptor(interceptor)
                    .build();
  • For App Log user Logger log method.
    Logger.inf("info");
    
    Logger.err("error",Logger.HI_PRI);
    
    Logger.d("debug");
    
    Logger.v("verbose",Logger.LOW_PRI);
    
    Logger.w("warn");
  • You can disable and with enable with these method.
   //For Disable
   App.getInstance().disableAndzu(); 
   
   //For Enable
   App.getInstance().enableAndzu();
  • That's it

Installation

Download the latest JAR or grab via Maven:

<repositories>
    <repository>
        <id>jitpack.io</id>
        <url>https://jitpack.io</url>
    </repository>
  </repositories>
  
  <dependency>
      <groupId>com.github.isacan</groupId>
      <artifactId>Andzu</artifactId>
      <version>0.65</version>
  </dependency>

or Gradle: Add it in your root build.gradle at the end of repositories:

allprojects {
   repositories {
    ...
    maven { url 'https://jitpack.io' }
   }
  }

Add the dependency

dependencies {
          compile 'com.github.isacan:Andzu:0.65'
  }

Contact

Inspiration

https://github.com/remirobert/Dotzu

License

Andzu is released under the MIT License.