Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Free Learning
Arrow right icon
Android Application Development with Maven
Android Application Development with Maven

Android Application Development with Maven: Learn how to use and configure Maven to support all phases of the development of an Android application

Arrow left icon
Profile Icon Papapetrou Profile Icon LALOU
Arrow right icon
€18.99 per month
Full star icon Full star icon Full star icon Full star icon Empty star icon 4 (1 Ratings)
Paperback Mar 2015 192 pages 1st Edition
eBook
€8.99 €19.99
Paperback
€24.99
Subscription
Free Trial
Renews at €18.99p/m
Arrow left icon
Profile Icon Papapetrou Profile Icon LALOU
Arrow right icon
€18.99 per month
Full star icon Full star icon Full star icon Full star icon Empty star icon 4 (1 Ratings)
Paperback Mar 2015 192 pages 1st Edition
eBook
€8.99 €19.99
Paperback
€24.99
Subscription
Free Trial
Renews at €18.99p/m
eBook
€8.99 €19.99
Paperback
€24.99
Subscription
Free Trial
Renews at €18.99p/m

What do you get with a Packt Subscription?

Free for first 7 days. $19.99 p/m after that. Cancel any time!
Product feature icon Unlimited ad-free access to the largest independent learning library in tech. Access this title and thousands more!
Product feature icon 50+ new titles added per month, including many first-to-market concepts and exclusive early access to books as they are being written.
Product feature icon Innovative learning tools, including AI book assistants, code context explainers, and text-to-speech.
Product feature icon Thousands of reference materials covering every tech concept you need to stay up to date.
Subscribe now
View plans & pricing
Table of content icon View table of contents Preview book icon Preview Book

Android Application Development with Maven

Chapter 1. Beginning with the Basics

In this chapter, we will see how to download, install, and set up a development environment, including the essential elements: Java Development Kit (JDK), Apache Maven, Android SDK, and an Integrated Development Environment (IDE). There will be pictures and illustrations provided to help you progress as quickly as possible.

Throughout this work, we will assume that you have a basic knowledge of Java, system, Maven, and IDEs and are familiar with terms such as: compiler, environment variables, repository, plugin, goal, build, and so on.

Installing Java

Prior to anything else, download and install a JDK7 and optionally a Java Runtime Environment (JRE). Both of them are downloadable from the Oracle website: http://www.oracle.com/technetwork/java/javase/downloads/jdk7-downloads-1880260.html. As a reminder, the JDK is a collection of tools needed to develop, compile, and monitor a Java application in the development state, whereas a JRE is needed to run a Java-compiled class or an archive. Keep in mind also that at the time this book was written, Android was not officially supporting JDK8 and that Oracle had already announced the end of public releases of JDK7. We hope that now that you read these lines, Android is compatible with the latest JDK. If not, then you should pick and install the latest available update of JDK7.

Set the environment variable JAVA_HOME to the right location, such as /var/opt/java or C:\win32app\jdk_1.7.X folder.

Then, add $JAVA_HOME/bin or %JAVA_HOME%\bin parameter to your PATH variable.

Check this by running the command java -version in a terminal. Here is an example of the expected output:

C:\>java -version
java version "1.7.0_45"
Java(TM) SE Runtime Environment (build 1.7.0_45-b18)
Java HotSpot(TM) Client VM (build 24.45-b08, mixed mode)

Download and Install Apache Maven

Download Maven 3.2.1 or greater from the Apache Maven website: http://maven.apache.org/download.cgi. Install this by uncompressing it in a folder of your choice. Set the environment variable M2_HOME to the right location, such as /usr/lib/maven/ or C:\win32app\apache-maven-3.2.1 folder.

Then, add $M2_HOME/bin or %M2_HOME%\bin parameter to your PATH variable. Check mvn setup is executable by running the command mvn -version . Here is an example of the expected output:

C:\win32app\Console-2.00.b148>mvn -version
Apache Maven 3.2.1 (ea8b2b07643dbb1b84b6d16e1f08391b666bc1e9; 2014-02-14T18:37:52+01:00)
Maven home: C:\win32app\apache-maven-3.2.1
Java version: 1.7.0_45, vendor: Oracle CorporationJava home:
C:\win32app\jdk1.7.0_45\jre
Default locale: en_US, platform encoding: Cp1252
OS name: "windows 7", version: "6.1", arch: "x86", family: "windows"

Android SDK

Two ways exist to install the SDK: the former is faster but it hides several operations you should be aware of as an Android developer. The latter takes more time but it introduces you to the tools and concepts coming with the SDK. Besides, this allows you to customize your installation, such as the folders. If you are a beginner, we encourage you to follow the first approach. You can always tune Android SDK at a later time when you feel more confident and you are familiar with the available settings.

Android development tools

You can download and install the official Android Studio from the Android website: https://developer.android.com/sdk/index.html. Android Studio is a suite that includes an integrated development environment (Android IDE), based on IntelliJ IDEA, with Android SDK tools, as well as other stuff like an embedded emulator system image and platform tools.

For Windows users, after downloading the installer (.exe file), run it and just follow the instructions provided by the installer. You can keep the default values suggested if you are a beginner or if you are not sure how each setting affects the installation. When you're done, you can run Android Studio by clicking on the icon created by the installer.

For Linux users, unzip the file you downloaded to your favorite application directory. Then, navigate to the android-studio/bin/ directory in a terminal and execute studio.sh command. Regardless of your operating system, always double-check before the installation that you have enough disk space. It varies from OS to OS.

Android SDK standalone

Alternately, if you already have an installed IDE or text editor, you can install the SDK manually. The following operations are long and tedious; however, any real Android developer should experience them at least once.

Download Android SDK from Android website: https://developer.android.com/sdk/index.html#Other. Again for Windows users, it is highly recommended to download the executable installer and follow the steps provided. Linux users can uncompress the downloaded zipped file to the folder of their choice, let's say /home/dev/android-sdk folder. In both cases, let's call the location where android SDK installed: ANDROID_HOME variable.

By default, the SDK has the following top-level directory tree:

Android SDK standalone

Let's explore and review the content of the starter SDK:

  • %ANDROID_HOME%\tools\: This folder gathers general utilities needed to develop, test, and debug an application.
  • %ANDROID_HOME%\platform-tools\: This folder contains other utilities, such as adb and fastboot, needed by developers to design, code, and debug an application on an actual device.
  • %ANDROID_HOME%\add-ons\: This folder is initially empty. It will be filled in later on, in order to provide support to call and use Google APIs, for instance the API allowing applications to communicate and display data from Google Maps.
  • %ANDROID_HOME%\AVD Manager.exe: This parameter allows us to manage the Android Virtual Devices (AVD), which are mere emulators. On first launch, no AVD is available. The following screenshot shows the Android Virtual Device Manager:
    Android SDK standalone

The AVD you will create later will be stored in your personal folder under the .android/avd path.

To launch the SDK manager, if you are a Windows user, run %ANDROID_HOME%\SDK Manager.exe command. If you are working on Linux, open a terminal and navigate to the tools/directory in the Android SDK and then execute:

android sdk.

In a first step like that shown in the following screenshot, install the packages suggested by the SDK Manager: SDK Tools, SDK Platform tools, the current API, and so on:

Android SDK standalone

At the time of writing, the last version of Android is 5.0.1 Lollipop. The API level is different from the grand public version: Lollipop corresponds to API 21, as well as Android KitKat 4.4.2 did to API 19, Android 4.0 / IceCreamSandwich did to API 17, or Android 2.3.X / Gingerbread to API 10, and so on.

Accept the license agreements as shown in the next screenshot, and let SDK Manager download. This may take a while for the default set of packages , and will take longer if you add other packages to the install list.

Android SDK standalone

Once this is done, the directory tree will change a lot. The different folders are filled in with the elements selected in the preceding screenshot, such as Google APIs, drivers, documentation, sources, build tools, and so on.

Creation of a new project

Now, we create a new, basic project. Often, you may prefer to do this within your IDE; anyway, creating a project with Maven and its artifacts and then importing the new project into the IDE are more elegant practice: this will ensure the project matches Android standards and is not IDE-dependent. Moreover, by default, creating an Android project in an IDE and then adding Maven support to this require some tricks and hacks.

The first step needs a bit of work: determining the platform.version properties of your Android install. Go to one among the installed platforms folder. If you have downloaded only the latest SDK version, then it should be in the ANDROID_HOME/platforms/android-21 folder. Open the file source.properties. Search for Platform.Version and Pkg.Revision properties. In the following sample file, the respective values are 4.4.2 and 3:

AndroidVersion.ApiLevel=21
Layoutlib.Api=12
Layoutlib.Revision=2
Pkg.Desc=Android SDK Platform 5.0.1
Pkg.License=(…)
Pkg.LicenseRef=android-sdk-license
Pkg.Revision=2
Pkg.SourceUrl=https\://dl-ssl.google.com/android/repository/repository-10.xml
Platform.MinToolsRev=22
Platform.Version=5.0.1

This allows us to conclude that the Platform.Version value is 5.0.1_r2. This is actually the combination of the properties: Platform.Version and Pkg.Revision. Note this value well as we will need to use it in a few places.

For the following Maven commands, you are assumed to have set the ANDROID_HOME environment variable; otherwise, you will need to suffix all the commands with the property -Dandroid.sdk.path=/path/to/Android/SDK/install. Now, we need to install the android.jar file as any regular Maven artifact in our local repository:

mvn install:install-file  \
-Dfile=%ANDROID_HOME%\platforms\android-21\android.jar \
-DgroupId=com.google.android \
-DartifactId=android \
-Dversion=5.0.1_r2  \
-Dpackaging=jar \
-DgeneratePom=true

Unfortunately, you will have to perform this operation for each Android platform version your application will support. Yet, for Android artifacts prior to 4.1.1.4 (included), the corresponding archives are accessible via Maven Central Repository.

Note

In a later chapter, we will see how to automate the installation of Android artifacts in local repository.

Open a terminal, run the command as follows:

mvn archetype:generate \
  -DarchetypeArtifactId=android-quickstart \
  -DarchetypeGroupId=de.akquinet.android.archetypes \
  -DarchetypeVersion=1.1.0 \
  -DgroupId=com.packt.androidMaven \
  -DartifactId=chapter \
  -Dversion=1.0-SNAPSHOT \
  -Dplatform=21 \
  --batch-mode \
  --quiet

Then, a new folder chapter1 is created. Go to this folder. You should find the tree of a classic Android project:

├───assets
├───res
│   ├───drawable-hdpi
│   ├───drawable-mdpi
│   ├───drawable-xhdpi
│   ├───drawable-xxhdpi
│   ├───layout
│   ├───menu
│   ├───values
│   ├───values-sw600dp
│   ├───values-sw720dp-land
│   ├───values-v11
│   └───values-v14
└───src
    └───main
        └───java
            └───com
                └───packt
                    └───androidMaven

At the root of the project is the Project Object Model (POM), serialized as a pom.xml file. Beware that the pom.xml file is a representation of the actual POM, but discrepancies do exist between the actual POM and the pom.xml file.

Open the POM file in write mode with any regular text editor. Check the <platform.version> tag. This contains the same value as retrieved earlier (in our case: 5.0.1_r2); if it does not, then set it.

You can run a successful mvn setup clean installation. A folder target containing a chapter1.apk archive should be created. Theoretically, this APK file (short for, Android PacKage) can run on a compatible Android device, such as a smart phone, a tablet, or even a smart watch.

Tip

Debug Certificate expired

If you get a build failure with an error similar to the following:

[ERROR] Failed to execute goal com.jayway.maven.plugins.android.generation2:android-maven-plugin:3.8.2:apk (default-apk) on project helloWorld: Debug Certificate expired on 02/02/13 00:10 -> [Help 1]

Then, do not worry. Delete the debug.keystore file that is located in ~/.android/or %USERPROFILE%\.android folder. This may fix most of the cases; if it does not, do not panic. Had your Android SDK been installed in parallel with a former version, another .\android\debug.keystore file may remain there. Delete it and relaunch the build.

Integration with IDE

Unless weird exceptions arise, Maven features are fully integrated within the three major IDEs of the market: Eclipse, IntelliJ IDEA, and NetBeans. So, on this side, nothing special needs to be done. However, integrating Android SDK to the IDEs may need some additional operations.

Eclipse

In this section, we will go through the steps you need to follow in order to set up Maven and Android SDK to be used with Eclipse IDE. Some months ago, Eclipse was Google's first choice for creating the Android Studio but recently IntelliJ won the battle. Users that want to use Eclipse Luna for Android development need to follow some steps that we will describe in the following section.

Set up and integration of Maven and Android SDK

First of all, we need to manually install the Google plugin. Go to Help | Install new software. In the dialog that appears, enter the update site URL into the work with text box:

https://dl.google.com/eclipse/plugin/4.4

Add a name to remember the URL subscription and click OK. Then, wait for the list of modules to be retrieved. At the end, you should see something like the following screenshot:

Set up and integration of Maven and Android SDK

Check the boxes for the Developer Tools and the Google Plugin for Eclipse and then click on Next and finally accept the license agreement.

Then, set up the Android SDK: Window | Preferences | Android |. Browse to set the SDK Location field value | OK:

Set up and integration of Maven and Android SDK

Besides, Eclipse embeds a built-in version of Maven (3.2.1 with Eclipse 4.4 Luna). Yet, you can use a specific version of Maven: go to Window | Preferences | Maven | Installations | Add and browse to the right location | OK, as shown in the following screenshot:

Set up and integration of Maven and Android SDK

Creation of a project in Eclipse

Open New (Alt+Shift+N) | Project | Maven |Maven Project. Click Next on the first window that is displayed and you see the following screenshot:

Creation of a project in Eclipse

If you try to filter the catalog with the keyword "android", the list will probably show nothing; so, we need to add the archetype we want to use for the project creation. Click on the Add Archetype button and fill in the archetype details as shown in the next screenshot and click on the OK button:

Creation of a project in Eclipse

Now, the archetype should be available and selected in the dialog box we are looking at. Click again on Next and enter the same data we have specified to maven when we created the project using command line—see the following screenshot. Don't forget to change the platform property value to 21 as this is the SDK version we have installed so far. The default, which is 16, will cause the maven goals to fail because the corresponding SDK is not yet installed in our environment:

Creation of a project in Eclipse

Now, you can open a terminal window and run the following command:

mvn clean install

You can also run the same goal using Eclipse and that's all. We have achieved the same result using our favorite IDE with just a few steps and we are now ready to start developing, testing, and running our first android application with Maven.

IntelliJ IDEA / Android Studio

IntelliJ IDEA is an IDE designed for Java development.

Set up and integration of Maven and Android SDK

Android Studio is promoted by Google as IDE for Android projects. Actually, Android Studio can be seen as a fork of main IntelliJ IDEA tool. Therefore, installation and configuration for both of them looks very similar or identical.

For pure Android projects, IntelliJ IDEA Community is sufficient: it includes core features such as Maven, Git, and Android support. Anyway, if you intend to develop enterprise projects linked with other Java/JEE frameworks and multitier architecture, you should consider installing the Ultimate version. Besides, beware that, at least so far, Android Studio is proposed as the suggested IDE from Google to develop Android applications.

Download IntelliJ IDEA from the page http://www.jetbrains.com/idea/download/ and/or Android Studio from this one: https://developer.android.com/sdk/index.html

On first launch, IntelliJ IDEA and Android Studio will ask you whether you already have an install. If you do, then hint at the location of the settings as shown in the following screenshot:

Set up and integration of Maven and Android SDK

Of course, settings of an IntelliJ IDEA install can be used for Android Studio and vice versa. The next steps of setup differ for IntelliJ IDEA and Android Studio.

Specific to Android Studio

Go to the settings (Ctrl+Alt+S) and then Plugins. Verify that the Maven plugins are installed.

Unlike, do uncheck Gradle plugin as shown in the following screenshot:

Specific to Android Studio

One might wonder why we need to disable Gradle to support Maven for Android development? Actually, by default, Android Studio considers Android/Maven projects as Eclipse-Android projects that are to be imported as regular Eclipse projects and then migrated to Gradle. This is the reason why we need to disable Gradle. Yet, this disables Android support, too. Don't worry, we will restore it later.

Besides, Android Studio should retrieve the Maven install location (based on the environment variable M2_HOME). If it does not, or if you need to use a custom location or version, you can navigate to Maven submenu inside the the settings (Ctrl+Alt+S) and override locations for Maven install, settings, and repository as shown in the following screenshot:

Specific to Android Studio

Specific to IntelliJ IDEA

On installing IntelliJ IDEA with the configuration wizard, take care to add Android and Maven plugins as shown in the following screenshot:

Specific to IntelliJ IDEA

Post this, we also choose which plugins we want to enable or disable, as shown in the following screenshot:

Specific to IntelliJ IDEA

Import of project

Importing the project with Android Studio requires a bit more work than with pure IntelliJ IDEA.

Specific to Android Studio

We will follow the following steps to import an existing Android Maven project to Android Studio and use this as our IDE to further development as follows:

  1. Go to File |Import Project as shown in the following screenshot:
    Specific to Android Studio
  2. Browse to the POM and select it. Click on OK. Accept default options:
    Specific to Android Studio
  3. Confirm default options until Finish button. Android Studio displays the imported project, which is considered for the moment as a mere Java project, without any Android-specifics.
  4. Go to the settings (Ctrl+Alt+S) | Plugins, restore the disabled plugins: Android Designer, Android Support, Google Cloud Tools for Android Studio, and Gradle.
  5. Restart Android Studio. The IDE informs you that the Android framework is detected. Click on Configure as shown in the following screenshot:
    Specific to Android Studio
  6. Check AndroidManifest.xml option and then click on OK:
    Specific to Android Studio
  7. Open the project structure (Ctrl+Alt+Shift+S) | SDKs. Click on the + sign (shortcut: Alt+Insert) | Add a new SDK | Select Android SDK | Browse to ANDROID_HOME variable | OK | Confirm both Java SDK and Build target | OK:
    Specific to Android Studio

You can run Maven to build the project from Android Studio. You are now ready to develop!

Specific to Android Studio

Specific to IntelliJ IDEA

Actually, IntelliJ IDEA is not as strongly linked to Gradle as Android Studio. This is why, for IntelliJ IDEA, the import follows the same template but is faster: simply import the POM and add the Android SDK.

NetBeans

NetBeans is the third commonly used IDE in Java development community. Originally maintained and promoted by Sun, now a division of Oracle, NetBeans still has features that fits the needs of Android development.

Download NetBeans from https://netbeans.org/downloads/. Install it.

Set up and integration of Maven and Android SDK

Let's start the setup by following these steps:

  1. Go to Tools | Plugins. In the fourth tab ,that is, Installed, check whether Maven plugin is installed. If needed, install or update it as shown in the following screenshot:
    Set up and integration of Maven and Android SDK
  2. Like Eclipse, a default version of Maven is embedded; yet, you can override it: Tools | Options | Java | Maven | Executions | Maven Home.

    Android plugin for NetBeans is NBAndroid. It is not available through default update centers. Besides, the features of free version are poor and limited. Anyway, a 1-month evaluation plan is offered.

  3. Go to Settings tab. Add and enter the name and URL, respectively, NBAndroid and http://nbandroid.org/updates/updates.xml, as shown in the following screenshot:
    Set up and integration of Maven and Android SDK
  4. Go to Available Plugins, check Android and NBAndroid Extensions (NBAndroid Gradle Support is not needed, unless you think of using both Maven and Gradle), and then Install. Accept the license, dismiss the warning about nonsigned modules, and restart NetBeans.
  5. Go to Tools | Options | Miscellaneous | Android | set Android SDK location as shown in the following screenshot:
    Set up and integration of Maven and Android SDK

Import a project

Go to File | Open Project (Ctrl+Shift+O), browse until the folder containing the POM. You are ready to develop with Android.

Tip

Downloading the example code

You can download the example code files for all Packt books you have purchased from your account at http://www.packtpub.com. If you purchased this book elsewhere, you can visit http://www.packtpub.com/support and register to have the files e-mailed directly to you.

Summary

Thus, in this opening chapter, we learned or revised how to install Maven and the Android SDK, and integrate them with an IDE. By now, you should be able to:

  • Set up the JDK
  • Set up Maven
  • Set up Android SDK
  • Set up a development environment
  • Importing any Android project into major IDEs based on Maven

The next chapter will teach you the basic steps to develop a simple Android application using maven and so will use most of the things we discussed. If you don't feel confident in your current knowledge, then feel free to read this chapter again.

Left arrow icon Right arrow icon

Description

Android Application Development with Maven is intended for Android developers or devops engineers who want to use Maven to effectively develop quality Android applications. It would be helpful, but not necessary, if you have some previous experience with Maven.

What you will learn

  • Integrate Maven with your favorite Android IDE
  • Install and configure Maven with your local development environment
  • Create the proper Maven structure for both standalone Android applications or applications that are part of a bigger project
  • Run unit tests using popular frameworks such as Robolectric and collect coverage information using Maven plugins
  • Configure a variety of different tools such as Robotium, Spoon, and Selendroid to run integration tests
  • Handle dependencies and different versions of the same application
  • Manage and automate the release process of your application inside/outside Google Play
  • Discover new tools such as Eclipse, IntelliJ IDEA/Android Studio, and NetBeans, which perfectly integrate with Maven and boost your productivity

Product Details

Country selected
Publication date, Length, Edition, Language, ISBN-13
Publication date : Mar 19, 2015
Length: 192 pages
Edition : 1st
Language : English
ISBN-13 : 9781783986101
Category :
Languages :
Tools :

What do you get with a Packt Subscription?

Free for first 7 days. $19.99 p/m after that. Cancel any time!
Product feature icon Unlimited ad-free access to the largest independent learning library in tech. Access this title and thousands more!
Product feature icon 50+ new titles added per month, including many first-to-market concepts and exclusive early access to books as they are being written.
Product feature icon Innovative learning tools, including AI book assistants, code context explainers, and text-to-speech.
Product feature icon Thousands of reference materials covering every tech concept you need to stay up to date.
Subscribe now
View plans & pricing

Product Details

Publication date : Mar 19, 2015
Length: 192 pages
Edition : 1st
Language : English
ISBN-13 : 9781783986101
Category :
Languages :
Tools :

Packt Subscriptions

See our plans and pricing
Modal Close icon
€18.99 billed monthly
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Simple pricing, no contract
€189.99 billed annually
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Choose a DRM-free eBook or Video every month to keep
Feature tick icon PLUS own as many other DRM-free eBooks or Videos as you like for just €5 each
Feature tick icon Exclusive print discounts
€264.99 billed in 18 months
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Choose a DRM-free eBook or Video every month to keep
Feature tick icon PLUS own as many other DRM-free eBooks or Videos as you like for just €5 each
Feature tick icon Exclusive print discounts

Frequently bought together


Stars icon
Total 61.98
Mastering Apache Maven 3
€36.99
Android Application Development with Maven
€24.99
Total 61.98 Stars icon
Banner background image

Table of Contents

8 Chapters
1. Beginning with the Basics Chevron down icon Chevron up icon
2. Starting the Development Phase Chevron down icon Chevron up icon
3. Unit Testing Chevron down icon Chevron up icon
4. Integration Testing Chevron down icon Chevron up icon
5. Android Flavors Chevron down icon Chevron up icon
6. Release Life Cycle and Continuous Integration Chevron down icon Chevron up icon
7. Other Tools and Plugins Chevron down icon Chevron up icon
Index Chevron down icon Chevron up icon

Customer reviews

Rating distribution
Full star icon Full star icon Full star icon Full star icon Empty star icon 4
(1 Ratings)
5 star 0%
4 star 100%
3 star 0%
2 star 0%
1 star 0%
Luca Morettoni Jun 26, 2015
Full star icon Full star icon Full star icon Full star icon Empty star icon 4
Java and Maven are strongly coupled, if you have worked for medium (or big) Java projects you will have used Maven!Maven has an huge number of plugins that help you on all process of application release, from testing to final packaging, the only price you need to pay is the configuration file that need to be written in XML (yes, I don't like XML).Recently Google moved the Android app building system to Gradle, that is a great tool: it can use the Maven repositories and the migration is not complicated, but the problem is that you need to migrate and learn a new system!This book is a perfect reference if you need to develope an Android application and you want (or you need) use Maven! Is full of real examples, and the authors drives you to create a pom file for a real application, giving you hints about useful plugins and configuration! Personally I didn't like so much the chapter about the IDE integration, looks like it was written much quickly compared to the other sections of the book.If you need to read (or learn) about Maven and Android project this book is for you!
Amazon Verified review Amazon
Get free access to Packt library with over 7500+ books and video courses for 7 days!
Start Free Trial

FAQs

What is included in a Packt subscription? Chevron down icon Chevron up icon

A subscription provides you with full access to view all Packt and licnesed content online, this includes exclusive access to Early Access titles. Depending on the tier chosen you can also earn credits and discounts to use for owning content

How can I cancel my subscription? Chevron down icon Chevron up icon

To cancel your subscription with us simply go to the account page - found in the top right of the page or at https://subscription.packtpub.com/my-account/subscription - From here you will see the ‘cancel subscription’ button in the grey box with your subscription information in.

What are credits? Chevron down icon Chevron up icon

Credits can be earned from reading 40 section of any title within the payment cycle - a month starting from the day of subscription payment. You also earn a Credit every month if you subscribe to our annual or 18 month plans. Credits can be used to buy books DRM free, the same way that you would pay for a book. Your credits can be found in the subscription homepage - subscription.packtpub.com - clicking on ‘the my’ library dropdown and selecting ‘credits’.

What happens if an Early Access Course is cancelled? Chevron down icon Chevron up icon

Projects are rarely cancelled, but sometimes it's unavoidable. If an Early Access course is cancelled or excessively delayed, you can exchange your purchase for another course. For further details, please contact us here.

Where can I send feedback about an Early Access title? Chevron down icon Chevron up icon

If you have any feedback about the product you're reading, or Early Access in general, then please fill out a contact form here and we'll make sure the feedback gets to the right team. 

Can I download the code files for Early Access titles? Chevron down icon Chevron up icon

We try to ensure that all books in Early Access have code available to use, download, and fork on GitHub. This helps us be more agile in the development of the book, and helps keep the often changing code base of new versions and new technologies as up to date as possible. Unfortunately, however, there will be rare cases when it is not possible for us to have downloadable code samples available until publication.

When we publish the book, the code files will also be available to download from the Packt website.

How accurate is the publication date? Chevron down icon Chevron up icon

The publication date is as accurate as we can be at any point in the project. Unfortunately, delays can happen. Often those delays are out of our control, such as changes to the technology code base or delays in the tech release. We do our best to give you an accurate estimate of the publication date at any given time, and as more chapters are delivered, the more accurate the delivery date will become.

How will I know when new chapters are ready? Chevron down icon Chevron up icon

We'll let you know every time there has been an update to a course that you've bought in Early Access. You'll get an email to let you know there has been a new chapter, or a change to a previous chapter. The new chapters are automatically added to your account, so you can also check back there any time you're ready and download or read them online.

I am a Packt subscriber, do I get Early Access? Chevron down icon Chevron up icon

Yes, all Early Access content is fully available through your subscription. You will need to have a paid for or active trial subscription in order to access all titles.

How is Early Access delivered? Chevron down icon Chevron up icon

Early Access is currently only available as a PDF or through our online reader. As we make changes or add new chapters, the files in your Packt account will be updated so you can download them again or view them online immediately.

How do I buy Early Access content? Chevron down icon Chevron up icon

Early Access is a way of us getting our content to you quicker, but the method of buying the Early Access course is still the same. Just find the course you want to buy, go through the check-out steps, and you’ll get a confirmation email from us with information and a link to the relevant Early Access courses.

What is Early Access? Chevron down icon Chevron up icon

Keeping up to date with the latest technology is difficult; new versions, new frameworks, new techniques. This feature gives you a head-start to our content, as it's being created. With Early Access you'll receive each chapter as it's written, and get regular updates throughout the product's development, as well as the final course as soon as it's ready.We created Early Access as a means of giving you the information you need, as soon as it's available. As we go through the process of developing a course, 99% of it can be ready but we can't publish until that last 1% falls in to place. Early Access helps to unlock the potential of our content early, to help you start your learning when you need it most. You not only get access to every chapter as it's delivered, edited, and updated, but you'll also get the finalized, DRM-free product to download in any format you want when it's published. As a member of Packt, you'll also be eligible for our exclusive offers, including a free course every day, and discounts on new and popular titles.