com.googlecode.sli4j.core
Class AbstractLoggingModule<L>
java.lang.Object
com.google.inject.TypeLiteral<L>
com.googlecode.sli4j.core.AbstractLoggingModule<L>
- Type Parameters:
L - the Logger type has to be injected.
- All Implemented Interfaces:
- com.google.inject.Module, com.google.inject.spi.TypeListener
public class AbstractLoggingModule<L>
- extends com.google.inject.TypeLiteral<L>
- implements com.google.inject.Module, com.google.inject.spi.TypeListener
Abstract module implementation of Logging module that simplifies Logger
building and injection.
Subclasses have to specify the Logger and the relative
AbstractLoggerInjector types.
- Version:
- $Id: AbstractLoggingModule.java 233 2010-06-05 14:06:59Z simone.tripodi $
- Author:
- Simone Tripodi
|
Constructor Summary |
AbstractLoggingModule(com.google.inject.matcher.Matcher<? super com.google.inject.TypeLiteral<?>> matcher,
Class<LI> loggerInjectorClass)
Creates a new Logger injection module. |
|
Method Summary |
void |
configure(com.google.inject.Binder binder)
|
|
hear(com.google.inject.TypeLiteral<I> type,
com.google.inject.spi.TypeEncounter<I> encounter)
|
| Methods inherited from class com.google.inject.TypeLiteral |
equals, get, get, getExceptionTypes, getFieldType, getParameterTypes, getRawType, getReturnType, getSupertype, getType, hashCode, toString |
AbstractLoggingModule
public AbstractLoggingModule(com.google.inject.matcher.Matcher<? super com.google.inject.TypeLiteral<?>> matcher,
Class<LI> loggerInjectorClass)
- Creates a new Logger injection module.
- Type Parameters:
LI - the concrete AbstractLoggerInjector- Parameters:
matcher - types matcher for whom the Logger injection has to be
performed.logInjectorClass - the AbstractLoggerInjector constructor.
configure
public final void configure(com.google.inject.Binder binder)
-
- Specified by:
configure in interface com.google.inject.Module
hear
public final <I> void hear(com.google.inject.TypeLiteral<I> type,
com.google.inject.spi.TypeEncounter<I> encounter)
-
- Specified by:
hear in interface com.google.inject.spi.TypeListener
Copyright © 2010. All Rights Reserved.