Class NoOpGlobalDecorator

java.lang.Object
org.forgerock.openig.decoration.global.NoOpGlobalDecorator
All Implemented Interfaces:
Decorator

public class NoOpGlobalDecorator extends Object implements Decorator
A Decorator which does nothing but act as if it had decorated the object.
  • Constructor Details

    • NoOpGlobalDecorator

      public NoOpGlobalDecorator()
  • Method Details

    • accepts

      public boolean accepts(Class<?> type)
      Description copied from interface: Decorator
      Returns true if this decorator is compatible with the provided component type. Note that a return value of true does not necessarily indicate that decoration will be performed since it may also depend on other factors
      Specified by:
      accepts in interface Decorator
      Parameters:
      type - type under test
      Returns:
      true if the decorator can decorate instance of the given type, false otherwise.
    • decorate

      public DecorationHandle decorate(Object delegate, JsonValue decoratorConfig, Context context) throws HeapException
      Description copied from interface: Decorator
      Decorates the provided delegate instance with the provided decoratorConfig configuration. The implementation should take care of not changing the base type of the delegate.
      Specified by:
      decorate in interface Decorator
      Parameters:
      delegate - instance to be decorated
      decoratorConfig - the decorator configuration to apply
      context - contextual information of the decorated instance
      Returns:
      a handle of the decoration that was setup, never null.
      Throws:
      HeapException - when decoration fails