Class BlankConditionConfig
java.lang.Object
com.norconex.importer.handler.BaseLabelableConfig
com.norconex.importer.handler.condition.BaseConditionConfig
com.norconex.importer.handler.condition.impl.BlankConditionConfig
- All Implemented Interfaces:
Labelable
A condition based on whether the document content (default) or
any of the specified metadata fields are blank or inexistent.
For metadata fields,
control characters (char <= 32) are removed before evaluating whether
their values are empty. Dealing with the document content will
rather check if it is null or empty (no bytes returned
when read).
Multiple fields and values:
By default, ALL values for all fields matched by your field matcher
expression must be blank for this condition to be true.
You can change the logic to have ANY values to be blank for the condition
to be true with setMatchAnyBlank(boolean).
If no fields are matched, the conditions is also considered empty
(true).
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected booleanbooleaninthashCode()booleansetFieldMatcher(TextMatcher fieldMatcher) setMatchAnyBlank(boolean matchAnyBlank) toString()Methods inherited from class com.norconex.importer.handler.BaseLabelableConfig
getLabel, setLabel
-
Constructor Details
-
BlankConditionConfig
public BlankConditionConfig()
-
-
Method Details
-
setFieldMatcher
-
getFieldMatcher
-
isMatchAnyBlank
public boolean isMatchAnyBlank() -
setMatchAnyBlank
- Returns:
this.
-
equals
- Overrides:
equalsin classBaseLabelableConfig
-
canEqual
- Overrides:
canEqualin classBaseLabelableConfig
-
hashCode
public int hashCode()- Overrides:
hashCodein classBaseLabelableConfig
-
toString
- Overrides:
toStringin classBaseLabelableConfig
-