Google Guice
Encyclopedia
Google Guice is an open source
software framework
for the Java platform released by Google
under an Apache license
. It provides support for dependency injection
using annotations
to configure Java objects. Dependency injection is a design pattern
whose core principle is to separate behavior from dependency resolution.
Guice allows implementation classes to be programmatically bound to an interface, then injected into constructors, methods or fields using an
Being the first generic framework for dependency injection using Java annotations in 2008, Guice won the 18th Jolt Award
for best Library, Framework, or Component .
Open source
The term open source describes practices in production and development that promote access to the end product's source materials. Some consider open source a philosophy, others consider it a pragmatic methodology...
software framework
Software framework
In computer programming, a software framework is an abstraction in which software providing generic functionality can be selectively changed by user code, thus providing application specific software...
for the Java platform released by Google
Google
Google Inc. is an American multinational public corporation invested in Internet search, cloud computing, and advertising technologies. Google hosts and develops a number of Internet-based services and products, and generates profit primarily from advertising through its AdWords program...
under an Apache license
Apache License
The Apache License is a copyfree free software license authored by the Apache Software Foundation . The Apache License requires preservation of the copyright notice and disclaimer....
. It provides support for dependency injection
Dependency injection
Dependency injection is a design pattern in object-oriented computer programming whose purpose is to improve testability of, and simplify deployment of components in very large software systems....
using annotations
Java annotation
An annotation, in the Java computer programming language, is a special form of syntactic metadata that can be added to Java source code. Classes, methods, variables, parameters and packages may be annotated...
to configure Java objects. Dependency injection is a design pattern
Design pattern
A design pattern in architecture and computer science is a formal way of documenting a solution to a design problem in a particular field of expertise. The idea was introduced by the architect Christopher Alexander in the field of architecture and has been adapted for various other disciplines,...
whose core principle is to separate behavior from dependency resolution.
Guice allows implementation classes to be programmatically bound to an interface, then injected into constructors, methods or fields using an
@Inject
annotation. When more than one implementation of the same interface is needed, the user can create custom annotations that identify an implementation, then use that annotation when injecting it.Being the first generic framework for dependency injection using Java annotations in 2008, Guice won the 18th Jolt Award
Jolt Awards
The Jolt Awards are awards in the software industry.Since 1990, the Dr. Dobb's Jolt Product Excellence Awards have been presented annually to showcase products that have "jolted" the industry with their significance and made the task of creating software faster, easier, and more efficient.Jolt Cola...
for best Library, Framework, or Component .