Package net.sf.okapi.filters.plaintext
Class PlainTextFilter
- java.lang.Object
-
- net.sf.okapi.common.filters.AbstractFilter
-
- net.sf.okapi.common.filters.AbstractCompoundFilter
-
- net.sf.okapi.filters.plaintext.PlainTextFilter
-
- All Implemented Interfaces:
AutoCloseable,Iterator<Event>,IFilter
public class PlainTextFilter extends AbstractCompoundFilter
Plain Text filter, processes text files encoded in ANSI, Unicode, UTF-8, UTF-16. Provides the byte-order mask detection. The filter is aware of the following line terminators:- Carriage return character followed immediately by a newline character ("\r\n")
- Newline (line feed) character ("\n")
- Stand-alone carriage return character ("\r")
-
-
Field Summary
Fields Modifier and Type Field Description static StringFILTER_MIMEstatic StringFILTER_NAME-
Fields inherited from interface net.sf.okapi.common.filters.IFilter
SUB_FILTER
-
-
Constructor Summary
Constructors Constructor Description PlainTextFilter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidsetFilterConfigurationMapper(IFilterConfigurationMapper fcMapper)Sets the filter configuration mapper for this filter.-
Methods inherited from class net.sf.okapi.common.filters.AbstractCompoundFilter
addSiblingFilter, cancel, close, createFilterWriter, createSkeletonWriter, getActiveParameters, getActiveSiblingFilter, hasNext, next, open, open, setActiveSiblingFilter, setConfiguration, setParameters, updateSiblingFilters
-
Methods inherited from class net.sf.okapi.common.filters.AbstractFilter
addConfiguration, addConfiguration, addConfiguration, addConfigurations, createEndFilterEvent, createStartFilterEvent, findConfiguration, getConfiguration, getConfigurations, getDisplayName, getDocumentId, getDocumentName, getEncoderManager, getEncoding, getFilterConfigurationMapper, getMimeType, getName, getNewlineType, getParameters, getParameters, getParametersClassName, getParentId, getSrcLoc, getTrgLoc, isCanceled, isGenerateSkeleton, isMultilingual, isUtf8Bom, isUtf8Encoding, removeConfiguration, setDisplayName, setDocumentName, setEncoding, setGenerateSkeleton, setMimeType, setMultilingual, setName, setNewlineType, setOptions, setParentId, setSrcLoc, setTrgLoc
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface java.util.Iterator
forEachRemaining, remove
-
-
-
-
Field Detail
-
FILTER_NAME
public static final String FILTER_NAME
- See Also:
- Constant Field Values
-
FILTER_MIME
public static final String FILTER_MIME
- See Also:
- Constant Field Values
-
-
Method Detail
-
setFilterConfigurationMapper
public void setFilterConfigurationMapper(IFilterConfigurationMapper fcMapper)
Description copied from interface:IFilterSets the filter configuration mapper for this filter. This object is used by this filter if it needs to instantiate sub-filters. The implementations of IFilter that do not use sub-filters can use an empty stub for this method.- Specified by:
setFilterConfigurationMapperin interfaceIFilter- Overrides:
setFilterConfigurationMapperin classAbstractFilter- Parameters:
fcMapper- the mapper to set.
-
-