He told us so!

Top 5 Android Libraries — December 2016

COBE Team
COBE
4 min readDec 1, 2016

--

Winter is coming! After a long year of anticipation, we finally get to say this. Even though this weather is perfect for wrapping ourselves in a blanket and rewatching Game of Thrones (shoutout to fellow fans!) next to a fireplace, we must remember that we are developers and have no time for such pleasantries (at least we want our managers to believe that). As is tradition, we are hoping to save you some time by bringing top five Android libraries of this month. Check it out, it might save you more time for watching Ned Stark undergoing his not so pleasant experiences. :)

Patch notes: fixed indexing issues

0. Timecon

It was about time (pun intended) that we bring up a library for showing time. This particular library does that and more, giving us ability to customise the look and feel of widget, as well as its behavior. As a bonus, library was written in Kotlin (for all of you Kotlin lovers out there, you know who you are).

1. PhotoView

This one you probably already saw if you ever had (or wanted) to implement a photo view with a pinch and double tap to zoom in/out, scroll, put it in a view pager and more. Well, Chris Banes, thank you for saving our time! Bonus: sample app is available on Play store so you can give it a test run before implementing.

2. NavigationTabBar

We know, BottomNavigationView is the new black but you should give this lib a try. Guys from DevLight agency were already featured in our September top 5 and they deserved to be mentioned again. Customisation options of this library are crazy and the whole look of it gives you the means to design gorgeous app navigation. Below you can find just one of many demo screens available on libraries github page.

Shamelessly stolen from libs github page

3. android-complexify

In this day and age, you can’t be (digitally) safe enough. But, even though we read about the security all the time, ‘123456’ and ‘password’ are still holding the first place among the most used password. Since we know better and we want our users to be safe(r), such things shouldn’t be accepted. To help us carry out this mission, android-complexify does a bunch of safety checks on users entered password string. Who could ask for more?

setBanMode(ComplexifyBanMode banMode) 
// use strict (don't allow substrings of banned passwords) or loose (only ban exact matches) comparisons for banned passwords.
// (default: ComplexifyBanMode.STRICT)
setExecuteMode(ComplexifyExecuteMode executeMode)
// defines whether execution is synchronous or asynchronous.
// (default: ComplexifyExecuteMode.SYNC)
setStrengthScaleFactor(int strengthScaleFactor)
// scale the required password strength (higher numbers require a more complex password)
// (default: 1)
setMinimumChars(int minimumChars)
// the minimum acceptable password length (default: 8)
setBanList(String[] banList)
// array of banned passwords (default: Generated from 500 worst passwords and 370 Banned Twitter lists found <a href="http://www.skullsecurity.org/wiki/index.php/Passwords">here</a>)

Plus, it’s super simple to implement and work with.

EditText editText = (EditText) findViewById(R.id.editText); // your editText where you want to check password complexity as user writesComplexify complexify = new Complexify(editText, new ComplexifyListener() {
@Override
public void onSuccess(boolean isValid, double complexity) {
// isValid is true if password is valid, false otherwise
// complexity is number form range [0.0, 100.0] where greater number represents greater complexity
}
});

4. SocialLoginManager

Now that we’ve solved password input problems, we can think of alternative ways to let users log in our app. This fairly young helper library that sits on top of RxJava will help you implement social login in your app (which you should do if there is a login/register in your app). Implementation is easy and usage even easier.

private void loginByFacebook() {
SocialLoginManager.getInstance(this)
.facebook()
.login()
.subscribe(socialUser -> {
Log.d(TAG, "userId: " + socialUser.userId);
// ...
},
error -> {
Log.d(TAG, "error: " + error.getMessage());
});
}
private void loginByGoogle() {
SocialLoginManager.getInstance(this)
.google(getString(R.string.default_web_client_id))
.login()
.subscribe(socialUser -> {
Log.d(TAG, "userId: " + socialUser.userId);
// ...
},
error -> {
Log.d(TAG, "error: " + error.getMessage());
});
}

--

--

Editor for

Team of design&development professionals from digital agency COBE. Check our work at www.cobeisfresh.com.