Remove dependency from Java 7

Jiras:

* [AGDROID-274](https://issues.jboss.org/browse/AGDROID-274)
* [AGDROID-179](https://issues.jboss.org/browse/AGDROID-179)