org.cruxframework.crux.core.config
Class AbstractPropertiesFactory

java.lang.Object
  extended by org.cruxframework.crux.core.config.AbstractPropertiesFactory
Direct Known Subclasses:
ClusteredCacheConfigurationFactory, ConfigurationFactory, MessagesFactory, NoClusteredCacheConfigurationFactory

public abstract class AbstractPropertiesFactory
extends Object

Abstract Factory for messages based on property files . Receive an Interface and use it's name to look for resource bundles in the classpath. Each interface's method is used as key in that property file.

Author:
Thiago da Rosa de Bustamante, Gesse S. F. Dafe

Constructor Summary
AbstractPropertiesFactory()
           
 
Method Summary
protected
<T> T
getConstantsFromProperties(Class<T> targetInterface)
          Create a message helper class that access a resource bundle using the methods present in the given interface.
protected abstract  ConstantsInvocationHandler getInvocationHandler(Class<?> targetInterface)
           
protected
<T> T
initProxy(Class<T> targetInterface)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractPropertiesFactory

public AbstractPropertiesFactory()
Method Detail

getConstantsFromProperties

protected <T> T getConstantsFromProperties(Class<T> targetInterface)
                                throws MessageException
Create a message helper class that access a resource bundle using the methods present in the given interface.

Parameters:
targetInterface -
Returns:
Throws:
MessageException

initProxy

protected <T> T initProxy(Class<T> targetInterface)

getInvocationHandler

protected abstract ConstantsInvocationHandler getInvocationHandler(Class<?> targetInterface)


Copyright © 2015. All rights reserved.