Class TextConditionConfig
java.lang.Object
com.norconex.importer.handler.BaseLabelableConfig
com.norconex.importer.handler.condition.BaseConditionConfig
com.norconex.importer.handler.condition.impl.TextConditionConfig
- All Implemented Interfaces:
Labelable
A condition based on a text pattern matching a document content (default), or matching specific field(s). When used on very large content, it is possible the pattern matching will be done in chunks, sometimes not achieving expected results.
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected booleanbooleanGets the text matcher of field names.intThe maximum number of characters to read at once, used for filtering.The presumed source character encoding.Gets the text matcher for content or field values.inthashCode()setFieldMatcher(TextMatcher fieldMatcher) Sets the text matcher of field names.setMaxReadSize(int maxReadSize) The maximum number of characters to read at once, used for filtering.setSourceCharset(Charset sourceCharset) The presumed source character encoding.setValueMatcher(TextMatcher valueMatcher) Sets the text matcher for content or field values.toString()Methods inherited from class com.norconex.importer.handler.BaseLabelableConfig
getLabel, setLabel
-
Constructor Details
-
TextConditionConfig
public TextConditionConfig()
-
-
Method Details
-
getValueMatcher
Gets the text matcher for content or field values.- Returns:
- text matcher
-
setValueMatcher
Sets the text matcher for content or field values. Copies it.- Parameters:
valueMatcher- text matcher- Returns:
- this instance
-
getFieldMatcher
Gets the text matcher of field names.- Returns:
- field matcher
-
setFieldMatcher
Sets the text matcher of field names. Copies it.- Parameters:
fieldMatcher- text matcher- Returns:
- this instance
-
getSourceCharset
The presumed source character encoding. Usually ignored and presumed to be UTF-8 if the document has been parsed already.- Returns:
- character encoding of the source to be transformed
-
getMaxReadSize
public int getMaxReadSize()The maximum number of characters to read at once, used for filtering. Default isTextReader.DEFAULT_MAX_READ_SIZE.- Returns:
- maximum read size
-
setSourceCharset
The presumed source character encoding. Usually ignored and presumed to be UTF-8 if the document has been parsed already.- Parameters:
sourceCharset- character encoding of the source to be transformed- Returns:
this.
-
setMaxReadSize
The maximum number of characters to read at once, used for filtering. Default isTextReader.DEFAULT_MAX_READ_SIZE.- Parameters:
maxReadSize- maximum read size- Returns:
this.
-
equals
- Overrides:
equalsin classBaseLabelableConfig
-
canEqual
- Overrides:
canEqualin classBaseLabelableConfig
-
hashCode
public int hashCode()- Overrides:
hashCodein classBaseLabelableConfig
-
toString
- Overrides:
toStringin classBaseLabelableConfig
-