Enum Class Filter

java.lang.Object
java.lang.Enum<Filter>
org.dspace.contentreport.Filter
All Implemented Interfaces:
Serializable, Comparable<Filter>, Constable

public enum Filter extends Enum<Filter>
Available filters for the Filtered Collections and Filtered Items reports. In this enum, each item corresponds to a separate property, not values of a single property, hence the @JsonProperty applied to each of them. For each item, the annotation value is read through reflection and copied into the id property, which eliminates repetitions, hence reducing the risk or errors.
Author:
Jean-François Morin (Université Laval)
  • Enum Constant Details

    • IS_ITEM

      public static final Filter IS_ITEM
    • IS_WITHDRAWN

      public static final Filter IS_WITHDRAWN
    • IS_NOT_WITHDRAWN

      public static final Filter IS_NOT_WITHDRAWN
    • IS_DISCOVERABLE

      public static final Filter IS_DISCOVERABLE
    • IS_NOT_DISCOVERABLE

      public static final Filter IS_NOT_DISCOVERABLE
    • HAS_MULTIPLE_ORIGINALS

      public static final Filter HAS_MULTIPLE_ORIGINALS
      Matches items having multiple original bitstreams.
    • HAS_NO_ORIGINALS

      public static final Filter HAS_NO_ORIGINALS
      Matches items having no original bitstreams.
    • HAS_ONE_ORIGINAL

      public static final Filter HAS_ONE_ORIGINAL
      Matches items having exactly one original bitstream.
    • HAS_DOC_ORIGINAL

      public static final Filter HAS_DOC_ORIGINAL
      Matches items having bitstreams with a MIME type that matches one defined in the "rest.report-mime-document" configuration property.
    • HAS_IMAGE_ORIGINAL

      public static final Filter HAS_IMAGE_ORIGINAL
      Matches items having bitstreams with a MIME type starting with "image" (e.g., image/jpeg, image/png).
    • HAS_UNSUPPORTED_TYPE

      public static final Filter HAS_UNSUPPORTED_TYPE
      Matches items having bitstreams with a MIME type other than document (cf. HAS_DOCUMENT above) or image (cf. HAS_IMAGE_ORIGINAL above).
    • HAS_MIXED_ORIGINAL

      public static final Filter HAS_MIXED_ORIGINAL
      Matches items having bitstreams of multiple types (document, image, other).
    • HAS_PDF_ORIGINAL

      public static final Filter HAS_PDF_ORIGINAL
    • HAS_JPEG_ORIGINAL

      public static final Filter HAS_JPEG_ORIGINAL
    • HAS_SMALL_PDF

      public static final Filter HAS_SMALL_PDF
      Matches items having at least one PDF of size less than 20 kb (configurable in rest.cfg).
    • HAS_LARGE_PDF

      public static final Filter HAS_LARGE_PDF
      Matches items having at least one PDF of size more than 25 Mb (configurable in rest.cfg).
    • HAS_DOC_WITHOUT_TEXT

      public static final Filter HAS_DOC_WITHOUT_TEXT
      Matches items having at least one non-text bitstream.
    • HAS_ONLY_SUPPORTED_IMAGE_TYPE

      public static final Filter HAS_ONLY_SUPPORTED_IMAGE_TYPE
      Matches items having at least one image, but all of supported types.
    • HAS_UNSUPPORTED_IMAGE_TYPE

      public static final Filter HAS_UNSUPPORTED_IMAGE_TYPE
      Matches items having at least one image of an unsupported type.
    • HAS_ONLY_SUPPORTED_DOC_TYPE

      public static final Filter HAS_ONLY_SUPPORTED_DOC_TYPE
      Matches items having at least one document, but all of supported types.
    • HAS_UNSUPPORTED_DOC_TYPE

      public static final Filter HAS_UNSUPPORTED_DOC_TYPE
      Matches items having at least one document of an unsupported type.
    • HAS_UNSUPPORTED_BUNDLE

      public static final Filter HAS_UNSUPPORTED_BUNDLE
      Matches items having at least one unsupported bundle.
    • HAS_SMALL_THUMBNAIL

      public static final Filter HAS_SMALL_THUMBNAIL
      Matches items having at least one thumbnail of size less than 400 bytes (configurable in rest.cfg).
    • HAS_ORIGINAL_WITHOUT_THUMBNAIL

      public static final Filter HAS_ORIGINAL_WITHOUT_THUMBNAIL
      Matches items having at least one original without a thumbnail.
    • HAS_INVALID_THUMBNAIL_NAME

      public static final Filter HAS_INVALID_THUMBNAIL_NAME
      Matches items having at least one non-JPEG thumbnail.
    • HAS_NON_GENERATED_THUMBNAIL

      public static final Filter HAS_NON_GENERATED_THUMBNAIL
      Matches items having at least one non-generated thumbnail.
    • NO_LICENSE

      public static final Filter NO_LICENSE
      Matches items having no licence-typed bitstreams.
    • HAS_LICENSE_DOCUMENTATION

      public static final Filter HAS_LICENSE_DOCUMENTATION
      Matches items having licence documentation (a licence bitstream named other than license.txt).
    • HAS_RESTRICTED_ORIGINAL

      public static final Filter HAS_RESTRICTED_ORIGINAL
      Matches items having at least one original with restricted access.
    • HAS_RESTRICTED_THUMBNAIL

      public static final Filter HAS_RESTRICTED_THUMBNAIL
      Matches items having at least one thumbnail with restricted access.
    • HAS_RESTRICTED_METADATA

      public static final Filter HAS_RESTRICTED_METADATA
      Matches items having metadata with restricted access.
  • Method Details

    • values

      public static Filter[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static Filter valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • getId

      public String getId()
    • getCategory

      public FilterCategory getCategory()
    • testItem

      public boolean testItem(Context context, Item item)
    • get

      public static Filter get(String id)
    • getFilters

      public static Set<Filter> getFilters(String filters)