DocumentSearchFilter

A document filter to use with the search window. It filters the documents depending on some of their attributes (keywords for title and description, source, rights holder, publication and refering dates).

Constructor

new DocumentSearchFilter()

Creates a new document search filter.

Classes

DocumentSearchFilter

Members

keywords :Array.<string>

A list of keywords to search in the title or the description of the document. These keywords should be in lowercase.

Type:
  • Array.<string>

pubEndDate :Date

The upper bound of the publication date.

Type:
  • Date

pubStartDate :Date

The lower bound of the publication date.

Type:
  • Date

refEndDate :Date

The upper bound of the refering date.

Type:
  • Date

refStartDate :Date

The lower bound of the refering date.

Type:
  • Date

rightsHolder

The rights holder. Should be in lowercase.

source :string

A string representing the source. Should be in lowercase.

Type:
  • string

Methods

clear()

Clears the filter.

filterDocument(doc) → {boolean}

The function to filter the documents.

Parameters:
NameTypeDescription
docDocument

The document to filter.

Returns:

True if the document is accepted

Type: 
boolean