org.rhq.jndi.context
Class URLPreferringContextDecoratorSetContext

java.lang.Object
  extended by org.rhq.jndi.context.URLPreferringContextDecoratorSetContext
All Implemented Interfaces:
DecoratorSetContext<Context,ContextDecorator>

public class URLPreferringContextDecoratorSetContext
extends Object
implements DecoratorSetContext<Context,ContextDecorator>

Author:
Lukas Krejci

Constructor Summary
URLPreferringContextDecoratorSetContext(Set<Class<? extends Context>> supportedInterfaces)
           
 
Method Summary
 Set<Class<? extends ContextDecorator>> getDecoratorClasses()
           
 Set<Class<? extends Context>> getSupportedInterfaces()
           
 void init(ContextDecorator decorator, Context object)
          Initializes the decorator to decorate given object.
 ContextDecorator instantiate(Class<? extends ContextDecorator> decoratorClass)
          Instantiates a new decorator of given class.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

URLPreferringContextDecoratorSetContext

public URLPreferringContextDecoratorSetContext(Set<Class<? extends Context>> supportedInterfaces)
Method Detail

getSupportedInterfaces

public Set<Class<? extends Context>> getSupportedInterfaces()
Specified by:
getSupportedInterfaces in interface DecoratorSetContext<Context,ContextDecorator>
Returns:
the set of interfaces that the decorators are able support. Usually this should be just a union of all interfaces the decorators implement but can be trimmed down.

getDecoratorClasses

public Set<Class<? extends ContextDecorator>> getDecoratorClasses()
Specified by:
getDecoratorClasses in interface DecoratorSetContext<Context,ContextDecorator>
Returns:
the set of all decorator classes in this set

instantiate

public ContextDecorator instantiate(Class<? extends ContextDecorator> decoratorClass)
                             throws Exception
Description copied from interface: DecoratorSetContext
Instantiates a new decorator of given class.

Specified by:
instantiate in interface DecoratorSetContext<Context,ContextDecorator>
Returns:
Throws:
Exception

init

public void init(ContextDecorator decorator,
                 Context object)
          throws Exception
Description copied from interface: DecoratorSetContext
Initializes the decorator to decorate given object.

Specified by:
init in interface DecoratorSetContext<Context,ContextDecorator>
Throws:
Exception - on error


Copyright © 2008-2012 Red Hat, Inc.. All Rights Reserved.