Theoretically, you can also import JAR files. However, the difficulty is to find out the dependencies of this dependency, the dependencies of the dependencies of the dependency and so on until all dependencies are resolved.
In Eclipse, you can use Eclipse Buildship to resolve Gradle dependencies.
With
repositories {
maven {
url 'https://maven.google.com'
}
}
the dependency com.google.firebase:firebase-messaging:11.6.2
is resolved to following JAR/AAR files:
https://maven.google.com/com/google/firebase/firebase-messaging/11.6.2/firebase-messaging-11.6.2.aar
https://maven.google.com/com/google/firebase/firebase-iid/11.6.2/firebase-iid-11.6.2.aar
https://maven.google.com/com/google/android/gms/play-services-basement/11.6.2/play-services-basement-11.6.2.aar
https://maven.google.com/com/google/firebase/firebase-common/11.6.2/firebase-common-11.6.2.aar
https://maven.google.com/com/google/firebase/firebase-messaging-license/11.6.2/firebase-messaging-license-11.6.2.aar
https://maven.google.com/com/google/android/gms/play-services-tasks/11.6.2/play-services-tasks-11.6.2.aar
https://maven.google.com/com/google/firebase/firebase-iid-license/11.6.2/firebase-iid-license-11.6.2.aar
https://maven.google.com/com/android/support/support-v4/25.2.0/support-v4-25.2.0.aar
https://maven.google.com/com/google/android/gms/play-services-basement-license/11.6.2/play-services-basement-license-11.6.2.aar
https://maven.google.com/com/google/firebase/firebase-common-license/11.6.2/firebase-common-license-11.6.2.aar
https://maven.google.com/com/google/android/gms/play-services-tasks-license/11.6.2/play-services-tasks-license-11.6.2.aar
https://maven.google.com/com/android/support/support-compat/25.2.0/support-compat-25.2.0.aar
https://maven.google.com/com/android/support/support-media-compat/25.2.0/support-media-compat-25.2.0.aar
https://maven.google.com/com/android/support/support-core-utils/25.2.0/support-core-utils-25.2.0.aar
https://maven.google.com/com/android/support/support-core-ui/25.2.0/support-core-ui-25.2.0.aar
https://maven.google.com/com/android/support/support-fragment/25.2.0/support-fragment-25.2.0.aar
https://maven.google.com/com/android/support/support-annotations/25.2.0/support-annotations-25.2.0.jar
https://maven.google.com/com/android/support/support-compat/25.2.0/support-compat-25.2.0-sources.jar
https://maven.google.com/com/android/support/support-media-compat/25.2.0/support-media-compat-25.2.0-sources.jar
https://maven.google.com/com/android/support/support-core-utils/25.2.0/support-core-utils-25.2.0-sources.jar
https://maven.google.com/com/android/support/support-core-ui/25.2.0/support-core-ui-25.2.0-sources.jar
https://maven.google.com/com/android/support/support-fragment/25.2.0/support-fragment-25.2.0-sources.jar
https://maven.google.com/com/android/support/support-annotations/25.2.0/support-annotations-25.2.0-sources.jar
See also: How to integrate .aar file to Eclipse