net.sf.seaf.factory.impl
Class ProxyingFactory

java.lang.Object
  extended by net.sf.seaf.factory.impl.support.DelegatingFactoryBase
      extended by net.sf.seaf.factory.impl.ProxyingFactory
All Implemented Interfaces:
Factory

public class ProxyingFactory
extends DelegatingFactoryBase
implements Factory

Factory that proxies the returned instances with a Proxy.


Constructor Summary
ProxyingFactory()
          Default empty constructor.
ProxyingFactory(Proxy proxy, Factory instantiatingFactory)
          Full constructor.
 
Method Summary
<Type> Type
getInstanceOf(Class<Type> type)
          Return an initialized instance of the specified type.
 void setProxy(Proxy proxy)
          Set the proxy.
 
Methods inherited from class net.sf.seaf.factory.impl.support.DelegatingFactoryBase
getInstantiatingFactory, setInstantiatingFactory
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ProxyingFactory

public ProxyingFactory()
Default empty constructor. The proxy and instantiating factory must be supplied via its setter methods.


ProxyingFactory

public ProxyingFactory(Proxy proxy,
                       Factory instantiatingFactory)
Full constructor.

Parameters:
proxy - The proxy
instantiatingFactory - The instantiating factory
Method Detail

getInstanceOf

public <Type> Type getInstanceOf(Class<Type> type)
Description copied from interface: Factory
Return an initialized instance of the specified type.

Specified by:
getInstanceOf in interface Factory
Parameters:
type - The type of the requested instance
Returns:
The instance

setProxy

public final void setProxy(Proxy proxy)
Set the proxy.

Parameters:
proxy - The proxy


Copyright © 2008-2012 SEAF. All Rights Reserved.