Class AggregatingDescriptors

java.lang.Object
org.apache.jackrabbit.oak.spi.descriptors.AggregatingDescriptors
All Implemented Interfaces:
Descriptors

public class AggregatingDescriptors extends Object implements Descriptors
An AggregatingDescriptors is an implementation of Descriptors that allows to aggregate multiple Descriptors (which are provided dynamically via a whiteboard tracker).
  • Constructor Summary

    Constructors
    Constructor
    Description
    Create an AggregatingDescriptors which uses descriptors.getServices() at method invocation time
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns a string array holding all descriptor keys available for this implementation, both the standard descriptors defined by the string constants in this interface and any implementation-specific descriptors.
    @Nullable Value
    getValue(@NotNull String key)
    The value of a single-value descriptor is found by passing the key for that descriptor to this method.
    @Nullable Value[]
    getValues(@NotNull String key)
    The value array of a multi-value descriptor is found by passing the key for that descriptor to this method.
    boolean
    Returns true if key is a valid single-value descriptor; otherwise returns false
    boolean
    Returns true if key is a standard descriptor defined by the string constants in this interface and false if it is either a valid implementation-specific key or not a valid key.

    Methods inherited from class java.lang.Object

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

    • AggregatingDescriptors

      public AggregatingDescriptors(Tracker<Descriptors> tracker)
      Create an AggregatingDescriptors which uses descriptors.getServices() at method invocation time
  • Method Details

    • getKeys

      public String[] getKeys()
      Description copied from interface: Descriptors
      Returns a string array holding all descriptor keys available for this implementation, both the standard descriptors defined by the string constants in this interface and any implementation-specific descriptors. Used in conjunction with Descriptors.getValue(String key) and Descriptors.getValues(String key) to query information about this repository implementation.
      Specified by:
      getKeys in interface Descriptors
      Returns:
      a string array holding all descriptor keys.
    • isStandardDescriptor

      public boolean isStandardDescriptor(@NotNull @NotNull String key)
      Description copied from interface: Descriptors
      Returns true if key is a standard descriptor defined by the string constants in this interface and false if it is either a valid implementation-specific key or not a valid key.
      Specified by:
      isStandardDescriptor in interface Descriptors
      Parameters:
      key - a descriptor key.
      Returns:
      whether key is a standard descriptor.
    • isSingleValueDescriptor

      public boolean isSingleValueDescriptor(@NotNull @NotNull String key)
      Description copied from interface: Descriptors
      Returns true if key is a valid single-value descriptor; otherwise returns false
      Specified by:
      isSingleValueDescriptor in interface Descriptors
      Parameters:
      key - a descriptor key.
      Returns:
      whether the specified descriptor is multi-valued.
    • getValue

      @Nullable public @Nullable Value getValue(@NotNull @NotNull String key)
      Description copied from interface: Descriptors
      The value of a single-value descriptor is found by passing the key for that descriptor to this method. If key is the key of a multi-value descriptor or not a valid key this method returns null.
      Specified by:
      getValue in interface Descriptors
      Parameters:
      key - a descriptor key.
      Returns:
      The value of the indicated descriptor
    • getValues

      @Nullable public @Nullable Value[] getValues(@NotNull @NotNull String key)
      Description copied from interface: Descriptors
      The value array of a multi-value descriptor is found by passing the key for that descriptor to this method. If key is the key of a single-value descriptor then this method returns that value as an array of size one. If key is not a valid key this method returns null.
      Specified by:
      getValues in interface Descriptors
      Parameters:
      key - a descriptor key.
      Returns:
      the value array for the indicated descriptor