Class FilterFactory


  • public class FilterFactory
    extends java.lang.Object
    Static factory that allows wrapping a JackrabbitEventFilter into an OakEventFilter that contains some oak specific extensions.

    The resulting filter can subsequently be used in ObservationManagerImpl.addEventListener as usual.

    See Also:
    ObservationManagerImpl.addEventListener(javax.jcr.observation.EventListener, JackrabbitEventFilter)
    • Constructor Summary

      Constructors 
      Constructor Description
      FilterFactory()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static OakEventFilter wrap​(JackrabbitEventFilter baseFilter)
      Wrap a JackrabbitEventFilter into its corresponding oak extension, OakEventFilter, on which some Oak specific observation filter extensions can then be used.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • FilterFactory

        public FilterFactory()
    • Method Detail

      • wrap

        public static OakEventFilter wrap​(JackrabbitEventFilter baseFilter)
        Wrap a JackrabbitEventFilter into its corresponding oak extension, OakEventFilter, on which some Oak specific observation filter extensions can then be used.
        Parameters:
        baseFilter - the base filter which contains other properties. Changes to the resulting oak filter "write-through" to the underlying baseFilter (for the features covered by the underlying) and similarly changes to the baseFilter are seen by the resulting oak filter. Note that this "write-through" behavior does no longer apply after a listener was registered, ie changing a filter after registration doesn't alter it for that listener.
        Returns:
        an OakEventFilter upon which Oak specific observation filtering extensions can be activated and then used when adding an EventListener with the ObservationManagerImpl.