br.com.arsmachina.tapestrycrud.services.impl
Class TapestryCrudModuleServiceImpl

java.lang.Object
  extended by br.com.arsmachina.tapestrycrud.services.impl.TapestryCrudModuleServiceImpl
All Implemented Interfaces:
TapestryCrudModuleService

public class TapestryCrudModuleServiceImpl
extends Object
implements TapestryCrudModuleService

Default ModuleService implementation.

Author:
Thiago H. de Paula Figueiredo

Constructor Summary
TapestryCrudModuleServiceImpl(Set<TapestryCrudModule> modules)
          Single constructor of this class.
 
Method Summary
<T> Class<? extends ActivationContextEncoder<T>>
getActivationContextEncoderClass(Class<T> entityClass)
          Returns the activation context encoder class corresponding to a given entity class.
<T> Class<? extends Encoder<T,?>>
getEncoderClass(Class<T> entityClass)
          Returns the encoder class corresponding to a given entity class.
<T> Class<? extends LabelEncoder<T>>
getLabelEncoderClass(Class<T> entityClass)
          Returns the label encoder class corresponding to a given entity class.
 Set<TapestryCrudModule> getModules()
          Returns the set of all modules.
<T> Class<? extends PrimaryKeyEncoder<?,T>>
getPrimaryKeyEncoderClass(Class<T> entityClass)
          Returns the primary key encoder class corresponding to a given entity class.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TapestryCrudModuleServiceImpl

public TapestryCrudModuleServiceImpl(Set<TapestryCrudModule> modules)
Single constructor of this class.

Parameters:
entityClasses - a Set of TapestryCrudModules. It cannot be null.
Method Detail

getModules

public Set<TapestryCrudModule> getModules()
Description copied from interface: TapestryCrudModuleService
Returns the set of all modules.

Specified by:
getModules in interface TapestryCrudModuleService
Returns:
a Set of TapestryCrudModules.

getActivationContextEncoderClass

public <T> Class<? extends ActivationContextEncoder<T>> getActivationContextEncoderClass(Class<T> entityClass)
Description copied from interface: TapestryCrudModuleService
Returns the activation context encoder class corresponding to a given entity class.

Specified by:
getActivationContextEncoderClass in interface TapestryCrudModuleService
Type Parameters:
T - the entity type.
Parameters:
entityClass - a Class instance. It cannot be null.
Returns:
an Class or null (if no corresponding one is found).

getEncoderClass

public <T> Class<? extends Encoder<T,?>> getEncoderClass(Class<T> entityClass)
Description copied from interface: TapestryCrudModuleService
Returns the encoder class corresponding to a given entity class.

Specified by:
getEncoderClass in interface TapestryCrudModuleService
Type Parameters:
T - the entity type.
Parameters:
entityClass - a Class instance. It cannot be null.
Returns:
an Class or null (if no corresponding one is found).

getLabelEncoderClass

public <T> Class<? extends LabelEncoder<T>> getLabelEncoderClass(Class<T> entityClass)
Description copied from interface: TapestryCrudModuleService
Returns the label encoder class corresponding to a given entity class.

Specified by:
getLabelEncoderClass in interface TapestryCrudModuleService
Type Parameters:
T - the entity type.
Parameters:
entityClass - a Class instance. It cannot be null.
Returns:
a Class or null (if no corresponding one is found).

getPrimaryKeyEncoderClass

public <T> Class<? extends PrimaryKeyEncoder<?,T>> getPrimaryKeyEncoderClass(Class<T> entityClass)
Description copied from interface: TapestryCrudModuleService
Returns the primary key encoder class corresponding to a given entity class.

Specified by:
getPrimaryKeyEncoderClass in interface TapestryCrudModuleService
Type Parameters:
T - the entity type.
Parameters:
entityClass - a Class instance. It cannot be null.
Returns:
a Class or null (if no corresponding one is found).


Copyright © 2008-2009 Thiago H. de Paula Figueiredo. All Rights Reserved.