Class ItemHolder<Base,Secured extends SecuredItem>

java.lang.Object
org.apache.jena.permissions.impl.ItemHolder<Base,Secured>
Type Parameters:
Base - The base class that is being secured
Secured - The implementation (proxy) of the secured class.

public class ItemHolder<Base,Secured extends SecuredItem> extends Object
A class that holds the original item and the secured version of it. This class is used by the Invoker to return secured versions of the object during calls that return the called class for cascading.
  • Constructor Details

    • ItemHolder

      public ItemHolder(Base baseItem)
      Constructor.
      Parameters:
      baseItem - The base item.
  • Method Details

    • getBaseItem

      public Base getBaseItem()
      Get the base item. This method is used in the proxy to get call to the underlying instance.
      Returns:
      The instance that is being protected.
    • getSecuredItem

      public Secured getSecuredItem()
      Get the secured item. This method is used in the invocation handler to get the instance of the proxy on which a method call was made. Generally used in returning the original object to support cascading.
      Returns:
      the proxy.
    • setSecuredItem

      public final Secured setSecuredItem(SecuredItemInvoker handler)
      Creates the proxy, saves it as the securedItem and returns it.
      Parameters:
      handler - The SecuredItemInvoker to create the proxy with.
      Returns:
      The proxy.