public class ContentCleanup extends MultiContextDocumentProcessor implements com.exalead.util.Checkable, java.io.Serializable
MultiContextDocumentProcessor.InputContexts, MultiContextDocumentProcessor.Transformer<T>
DocumentProcessor.FromDataModel
Modifier and Type | Field and Description |
---|---|
static boolean |
DEFAULT_DUPLICATE_WHITESPACES |
static boolean |
DEFAULT_LEADING |
static boolean |
DEFAULT_SPACES |
static boolean |
DEFAULT_STRIP_H_T_M_L |
static boolean |
DEFAULT_TRAILING |
boolean |
duplicateWhitespaces |
boolean |
leading |
boolean |
spaces |
boolean |
stripHTML |
boolean |
trailing |
inputContexts
acceptCondition, dataModelClass, dataModelProperty, dataModelState, DEFAULT_DISABLED, disabled, fromDataModel, name
Constructor and Description |
---|
ContentCleanup() |
ContentCleanup(ContentCleanup o)
Copy constructor
|
Modifier and Type | Method and Description |
---|---|
<T> T |
accept(DocumentProcessor.Transformer<T> transformer,
T[] t) |
<T> T |
accept(MultiContextDocumentProcessor.Transformer<T> transformer,
T[] t) |
void |
check(boolean deep,
java.lang.String errorContext)
Checks this ContentCleanup.
|
static ContentCleanup |
fromString(java.lang.String s)
String representation of this ContentCleanup.
|
boolean |
isDuplicateWhitespaces()
Removes duplicate whitespaces.
|
boolean |
isLeading()
Removes the leading whitespaces
|
boolean |
isSpaces()
Removes *all* whitespaces.
|
boolean |
isStripHTML()
Strips HTML tags
|
boolean |
isTrailing()
Removes the trailing whitespaces
|
ContentCleanup |
makeCopy()
Creates and returns a deep copy of this ContentCleanup.
|
static ContentCleanup |
readFrom(java.io.InputStream is)
Read this ContentCleanup from an XML fragment.
|
void |
setDuplicateWhitespaces(boolean duplicateWhitespaces)
Removes duplicate whitespaces.
|
void |
setLeading(boolean leading)
Removes the leading whitespaces
|
void |
setSpaces(boolean spaces)
Removes *all* whitespaces.
|
void |
setStripHTML(boolean stripHTML)
Strips HTML tags
|
void |
setTrailing(boolean trailing)
Removes the trailing whitespaces
|
java.lang.String |
toString()
String representation of this ContentCleanup.
|
ContentCleanup |
withAcceptCondition(AcceptCondition acceptCondition) |
ContentCleanup |
withDataModelClass(java.lang.String dataModelClass) |
ContentCleanup |
withDataModelProperty(java.lang.String dataModelProperty) |
ContentCleanup |
withDataModelState(java.lang.String dataModelState) |
ContentCleanup |
withDisabled(boolean disabled) |
ContentCleanup |
withDisabled(java.lang.Boolean disabled) |
ContentCleanup |
withDuplicateWhitespaces(boolean duplicateWhitespaces) |
ContentCleanup |
withDuplicateWhitespaces(java.lang.Boolean duplicateWhitespaces) |
ContentCleanup |
withFromDataModel(DocumentProcessor fromDataModel) |
ContentCleanup |
withInputContexts(java.util.Collection<StringValue> __values) |
ContentCleanup |
withInputContexts(StringValue... __values)
The processor will only be applied to DocumentChunks with a ContextName specified in this list.
|
ContentCleanup |
withLeading(boolean leading) |
ContentCleanup |
withLeading(java.lang.Boolean leading) |
ContentCleanup |
withName(java.lang.String name) |
ContentCleanup |
withSpaces(boolean spaces) |
ContentCleanup |
withSpaces(java.lang.Boolean spaces) |
ContentCleanup |
withStripHTML(boolean stripHTML) |
ContentCleanup |
withStripHTML(java.lang.Boolean stripHTML) |
ContentCleanup |
withTrailing(boolean trailing) |
ContentCleanup |
withTrailing(java.lang.Boolean trailing) |
void |
writeTo(java.io.OutputStream os)
Write this ContentCleanup as an XML fragment
|
getInputContexts, setInputContexts, withInputContexts
getAcceptCondition, getDataModelClass, getDataModelProperty, getDataModelState, getFromDataModel, getName, isDisabled, setAcceptCondition, setDataModelClass, setDataModelProperty, setDataModelState, setDisabled, setFromDataModel, setName
public boolean duplicateWhitespaces
public static final boolean DEFAULT_DUPLICATE_WHITESPACES
public boolean leading
public static final boolean DEFAULT_LEADING
public boolean trailing
public static final boolean DEFAULT_TRAILING
public boolean spaces
public static final boolean DEFAULT_SPACES
public boolean stripHTML
public static final boolean DEFAULT_STRIP_H_T_M_L
public ContentCleanup()
public ContentCleanup(ContentCleanup o)
public ContentCleanup withInputContexts(StringValue... __values)
withInputContexts
in class MultiContextDocumentProcessor
public ContentCleanup withInputContexts(java.util.Collection<StringValue> __values)
withInputContexts
in class MultiContextDocumentProcessor
public ContentCleanup withAcceptCondition(AcceptCondition acceptCondition)
withAcceptCondition
in class MultiContextDocumentProcessor
public ContentCleanup withName(java.lang.String name)
withName
in class MultiContextDocumentProcessor
public ContentCleanup withDataModelState(java.lang.String dataModelState)
withDataModelState
in class MultiContextDocumentProcessor
public ContentCleanup withFromDataModel(DocumentProcessor fromDataModel)
withFromDataModel
in class MultiContextDocumentProcessor
public ContentCleanup withDataModelClass(java.lang.String dataModelClass)
withDataModelClass
in class MultiContextDocumentProcessor
public ContentCleanup withDataModelProperty(java.lang.String dataModelProperty)
withDataModelProperty
in class MultiContextDocumentProcessor
public ContentCleanup withDisabled(boolean disabled)
withDisabled
in class MultiContextDocumentProcessor
public ContentCleanup withDisabled(java.lang.Boolean disabled)
withDisabled
in class MultiContextDocumentProcessor
public void setDuplicateWhitespaces(boolean duplicateWhitespaces)
public boolean isDuplicateWhitespaces()
public ContentCleanup withDuplicateWhitespaces(boolean duplicateWhitespaces)
public ContentCleanup withDuplicateWhitespaces(java.lang.Boolean duplicateWhitespaces)
public void setLeading(boolean leading)
public boolean isLeading()
public ContentCleanup withLeading(boolean leading)
public ContentCleanup withLeading(java.lang.Boolean leading)
public void setTrailing(boolean trailing)
public boolean isTrailing()
public ContentCleanup withTrailing(boolean trailing)
public ContentCleanup withTrailing(java.lang.Boolean trailing)
public void setSpaces(boolean spaces)
public boolean isSpaces()
public ContentCleanup withSpaces(boolean spaces)
public ContentCleanup withSpaces(java.lang.Boolean spaces)
public void setStripHTML(boolean stripHTML)
public boolean isStripHTML()
public ContentCleanup withStripHTML(boolean stripHTML)
public ContentCleanup withStripHTML(java.lang.Boolean stripHTML)
public ContentCleanup makeCopy()
makeCopy
in class MultiContextDocumentProcessor
public static ContentCleanup readFrom(java.io.InputStream is) throws javax.xml.bind.JAXBException
javax.xml.bind.JAXBException
public void writeTo(java.io.OutputStream os) throws javax.xml.bind.JAXBException, java.io.IOException
writeTo
in class MultiContextDocumentProcessor
javax.xml.bind.JAXBException
java.io.IOException
public static ContentCleanup fromString(java.lang.String s) throws javax.xml.bind.JAXBException, java.io.UnsupportedEncodingException
javax.xml.bind.JAXBException
java.io.UnsupportedEncodingException
public java.lang.String toString()
toString
in class MultiContextDocumentProcessor
public void check(boolean deep, java.lang.String errorContext) throws com.exalead.util.TypedException
check
in interface com.exalead.util.Checkable
check
in class MultiContextDocumentProcessor
com.exalead.util.TypedException
public <T> T accept(MultiContextDocumentProcessor.Transformer<T> transformer, T[] t) throws com.exalead.util.TypedException
accept
in class MultiContextDocumentProcessor
com.exalead.util.TypedException
public <T> T accept(DocumentProcessor.Transformer<T> transformer, T[] t) throws com.exalead.util.TypedException
accept
in class DocumentProcessor
com.exalead.util.TypedException
Copyright © 2021 Dassault Systèmes, All Rights Reserved.