More: Author   ReportBugs   

So, there is some libraries that aim to ease using views because we have to findViewById every view! This library simply make it the easiest way it could be.

How does it make that happens?

Every view that needs to bind to your .java files should have an id. So lets assume that your view (lets take it a TextView) id is:


Then if your activity or fragment extends BinderActivity or BinderFragment, you just need to declare:

private TextView myTextView;

That's it. The view is binded automatically! So simple.

I want to bind a view that its variable name is different with its id?

You can easily use @AssignView annotation like this:

private TextView anotherName;

I have a view and a variable with exact same names that I don't want them to bind?

You can use BindStatus annotation which has an enum for its status like this:

private View myView;

This way myView will not be bind.

How to add this library to your project?

In your project gradle file, add jitpack maven, so it should be like this:

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

Then in your app gradle file, add this dependancy, so it should be like this:

dependencies {
    compile 'com.github.shadowalker77:EaseItProject:0.0.11'

After that, the only thing that you have to do is to extend BinderActivity or BinderFragment instead of default AppCompatActivity or Fragment.

This library also provides an easy way to use Fragment within Activities.

Support Me
About Me
Google+: Trinea trinea
GitHub: Trinea