Book Image

Learning Google Guice

By : Hussain Pithawala
Book Image

Learning Google Guice

By: Hussain Pithawala

Overview of this book

<p>Google Guice is an open source software framework for the Java platform released by Google under the Apache License. It provides support for dependency injection using annotations to configure Java objects.</p> <p>Learning Google Guice is a concise, hands-on book that covers the various areas of dependency injection using the features provided by the latest version of Google Guice. It focuses on core functionalities as well as the various extensions surrounding Guice that make it useful in other areas like web development, integration with frameworks for web development, and persistence.</p> <p>Learning Google Guice covers Guice extensions which avoid complex API usage. You will start by developing a trivial application and managing dependencies using Guice. As the book gradually progresses, you will continue adding complexity to the application while simultaneously learning how to use Guice features such as the Injector, Provider, Bindings, Scopes, and so on. Finally, you will retrofit the application for the Web, using Guice not only to manage dependencies, but also to solve configuration related problems.</p>
Table of Contents (17 chapters)
Learning Google Guice
Credits
About the Author
Acknowledgments
About the Reviewers
www.PacktPub.com
Preface
Index

Installing Maven


Download a binary release of Maven http://maven.apache.org/download.html; it is available in various formats, and most of the archive tools are able to extract them. Extract it in a convenient location, and follow rest of the procedure for different operating systems.

Mac OSX and Linux

Assuming the expanded location of Maven archive to be /usr/local/apache-maven-3.1.0; execute the following commands in order to install Maven:

  1. Create a soft link to the Maven installation. This would save you from changing the path variables in case you go for a version upgrade.

    ln -s /usr/local/apache-maven-3.1.0 maven
    
  2. Export the variable M2_HOME

    export M2_HOME=/usr/local/maven
    export PATH=${M2_HOME}/bin:${PATH}
    

Tip

Add these variables to your ~/.bash_profile or ~/.bash_login files to let you use Maven even when your current terminal session expires.

Microsoft Windows

Assuming the expanded location of Maven archive to be c:\Program Files\apache-maven-3.1.0; execute the following commands in order to install Maven:

  1. Set M2_HOME variable

    C:\> +set M2_HOME=c:\Program Files\apache-maven-3.1.0+
    
  2. Add this variable to PATH

    C:\> +set PATH=%PATH%;%M2_HOME%\bin+
    

Tip

Add these variables to system variables using Control Panel. This would let you run the Maven even when your current terminal session expires.