Skip to main content

BlankCondition

Evaluates to true when matching document fields are blank or empty.

Notes

Evaluates to true when one or more matching document fields are blank (null, empty, or whitespace-only). Useful in importer flow control to route documents that are missing or have empty values for specific fields.

Examples

Matches documents where both title and dc:title are blank or missing.

condition:
class: BlankCondition
fieldMatcher:
method: regex
pattern: (title|dc:title)

Usage

Full configuration skeleton, with every option and its default
class: BlankCondition
fieldMatcher:
ignoreCase: false
ignoreDiacritic: false
matchEmpty: false
method: BASIC
negateMatches: false
partial: false
pattern: string
replaceAll: false
trim: false
label: string
matchAnyBlank: false

Properties

PropertyTypeRequiredDefault
fieldMatcherTextMatcherNoTextMatcher
labelstringNo-
matchAnyBlankbooleanNofalse

Property Details

fieldMatcher

Matches document fields based on specified patterns and methods. Use this to restrict the handler to operate only on fields whose names satisfy the matcher criteria.

label

An optional, user-supplied label for this step in the importer pipeline. It has no effect on processing — it exists purely to help identify this step, for example in large configurations or in the visual configurator.

matchAnyBlank

Whether one blank value is enough. By default (false) every value of every matched field must be blank for the condition to hold; set it to true and any single blank value satisfies it.

Note that a field matcher matching nothing at all also counts as blank.