Code Monkey home page Code Monkey logo

annotationbox's Introduction

annotationbox

license Circle CI

This is a annotation converter for android library

中文文档在 这里

Getting Start

Add annotationbox-plugin as a dependency in your main build.gradle in the root of your project:

buildscript {
    dependencies {
        classpath 'com.air:annotationbox-plugin:0.5'
    }
}

apply the plugin and assign origin annotation and target annotation to your app/build.gradle

such as below:

apply plugin: 'com.air.annotationbox'

annotationbox {
    ruleMaps = [
            "com.air.annotationbox.custom.annotations.AGET":"retrofit2.http.GET",
            "com.air.annotationbox.custom.annotations.AHeaders":"retrofit2.http.Headers",
    ]
}

Then, when you build app, you will find every annotations as ruleMaps key will convert to ruleMaps value。

This will help you encapsulate annotation.

When the third party library update version and change the annotation package name, This will help you ignore this effect.

Known Issues

There are some issues:

  1. Only support annotation in interface. So, like butterknife annotation is not support

License

AnnotationBox is under the BSD license. See the LICENSE file for details.

annotationbox's People

Contributors

yunair avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.