Class FilterUtils

java.lang.Object
org.dspace.content.logic.FilterUtils

public class FilterUtils extends Object
General utility methods for logical item filtering
Author:
Kim Shepherd
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static Filter
    Get a Filter by configuration property name For example, if a module has implemented "my-feature.filter" configuration property this method will return a filter with the ID specified by the configuration property
    static Filter
    getFilterFromConfiguration(String property, Filter defaultFilter)
    Get a Filter by configuration property name For example, if a module has implemented "my-feature.filter" configuration property this method will return a filter with the ID specified by the configuration property
    static Map<Class<? extends Identifier>,Filter>
    getIdentifierFilters(boolean inProgress)
    Get a map of identifier types and filters to use when creating workspace or archived items This is used by services installing new archived or workspace items to filter by identifier type as some filters should apply to DOI creation but not Handle creation, and so on.

    Methods inherited from class java.lang.Object

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

    • FilterUtils

      public FilterUtils()
  • Method Details

    • getFilterFromConfiguration

      public static Filter getFilterFromConfiguration(String property)
      Get a Filter by configuration property name For example, if a module has implemented "my-feature.filter" configuration property this method will return a filter with the ID specified by the configuration property
      Parameters:
      property - DSpace configuration property name (Apache Commons config)
      Returns:
      Filter object, with a bean ID configured for this property key, or null
    • getFilterFromConfiguration

      public static Filter getFilterFromConfiguration(String property, Filter defaultFilter)
      Get a Filter by configuration property name For example, if a module has implemented "my-feature.filter" configuration property this method will return a filter with the ID specified by the configuration property
      Parameters:
      property - DSpace configuration property name (Apache Commons config)
      Returns:
      Filter object, with a bean ID configured for this property key, or default filter
    • getIdentifierFilters

      public static Map<Class<? extends Identifier>,Filter> getIdentifierFilters(boolean inProgress)
      Get a map of identifier types and filters to use when creating workspace or archived items This is used by services installing new archived or workspace items to filter by identifier type as some filters should apply to DOI creation but not Handle creation, and so on. The in progress or archived status will be used to load the appropriate filter from configuration

      Parameters:
      inProgress -
      Returns: