Class UniVocityTsvDataFormat
- java.lang.Object
-
- org.apache.camel.support.service.BaseService
-
- org.apache.camel.support.service.ServiceSupport
-
- org.apache.camel.dataformat.univocity.AbstractUniVocityDataFormat<com.univocity.parsers.tsv.TsvFormat,com.univocity.parsers.tsv.TsvWriterSettings,com.univocity.parsers.tsv.TsvWriter,com.univocity.parsers.tsv.TsvParserSettings,com.univocity.parsers.tsv.TsvParser,UniVocityTsvDataFormat>
-
- org.apache.camel.dataformat.univocity.UniVocityTsvDataFormat
-
- All Implemented Interfaces:
AutoCloseable,org.apache.camel.Service,org.apache.camel.ShutdownableService,org.apache.camel.spi.DataFormat,org.apache.camel.spi.DataFormatName,org.apache.camel.StatefulService,org.apache.camel.SuspendableService
@Dataformat("univocity-tsv") public class UniVocityTsvDataFormat extends AbstractUniVocityDataFormat<com.univocity.parsers.tsv.TsvFormat,com.univocity.parsers.tsv.TsvWriterSettings,com.univocity.parsers.tsv.TsvWriter,com.univocity.parsers.tsv.TsvParserSettings,com.univocity.parsers.tsv.TsvParser,UniVocityTsvDataFormat>This class is the data format that uses the TSV uniVocity parser.
-
-
Field Summary
Fields Modifier and Type Field Description protected CharacterescapeChar-
Fields inherited from class org.apache.camel.dataformat.univocity.AbstractUniVocityDataFormat
asMap, comment, emptyValue, headerExtractionEnabled, headers, headersDisabled, ignoreLeadingWhitespaces, ignoreTrailingWhitespaces, lazyLoad, lineSeparator, normalizedLineSeparator, nullValue, numberOfRecordsToRead, skipEmptyLines
-
-
Constructor Summary
Constructors Constructor Description UniVocityTsvDataFormat()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidconfigureFormat(com.univocity.parsers.tsv.TsvFormat format)Configures the format.protected com.univocity.parsers.tsv.TsvParsercreateParser(com.univocity.parsers.tsv.TsvParserSettings settings)Creates a new instance of the uniVocity parser.protected com.univocity.parsers.tsv.TsvParserSettingscreateParserSettings()Creates a new instance of the parser settings.protected com.univocity.parsers.tsv.TsvWritercreateWriter(Writer writer, com.univocity.parsers.tsv.TsvWriterSettings settings)Creates a new instance of the uniVocity writer.protected com.univocity.parsers.tsv.TsvWriterSettingscreateWriterSettings()Creates a new instance of the writer settings.StringgetDataFormatName()CharactergetEscapeChar()Gets the escape character symbol.UniVocityTsvDataFormatsetEscapeChar(Character escapeChar)Sets the escape character symbol.-
Methods inherited from class org.apache.camel.dataformat.univocity.AbstractUniVocityDataFormat
configureParserSettings, configureWriterSettings, doStart, doStop, getComment, getEmptyValue, getHeaderExtractionEnabled, getHeaders, getIgnoreLeadingWhitespaces, getIgnoreTrailingWhitespaces, getLineSeparator, getNormalizedLineSeparator, getNullValue, getNumberOfRecordsToRead, getSkipEmptyLines, isAsMap, isHeadersDisabled, isLazyLoad, marshal, setAsMap, setComment, setEmptyValue, setHeaderExtractionEnabled, setHeaders, setHeadersDisabled, setIgnoreLeadingWhitespaces, setIgnoreTrailingWhitespaces, setLazyLoad, setLineSeparator, setNormalizedLineSeparator, setNullValue, setNumberOfRecordsToRead, setSkipEmptyLines, unmarshal
-
Methods inherited from class org.apache.camel.support.service.BaseService
build, doBuild, doFail, doInit, doLifecycleChange, doResume, doShutdown, doSuspend, fail, getStatus, init, isBuild, isInit, isNew, isRunAllowed, isShutdown, isStarted, isStarting, isStartingOrStarted, isStopped, isStopping, isStoppingOrStopped, isSuspended, isSuspending, isSuspendingOrSuspended, resume, shutdown, start, stop, suspend
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
-
-
Field Detail
-
escapeChar
protected Character escapeChar
-
-
Method Detail
-
getEscapeChar
public Character getEscapeChar()
Gets the escape character symbol. Ifnullthen the default format value is used.- Returns:
- the escape character symbol
- See Also:
TsvFormat.getEscapeChar()
-
setEscapeChar
public UniVocityTsvDataFormat setEscapeChar(Character escapeChar)
Sets the escape character symbol. Ifnullthen the default settings value is used.- Parameters:
escapeChar- the escape character symbol- Returns:
- current data format instance, fluent API
- See Also:
TsvFormat.setEscapeChar(char)
-
createWriterSettings
protected com.univocity.parsers.tsv.TsvWriterSettings createWriterSettings()
Creates a new instance of the writer settings.- Specified by:
createWriterSettingsin classAbstractUniVocityDataFormat<com.univocity.parsers.tsv.TsvFormat,com.univocity.parsers.tsv.TsvWriterSettings,com.univocity.parsers.tsv.TsvWriter,com.univocity.parsers.tsv.TsvParserSettings,com.univocity.parsers.tsv.TsvParser,UniVocityTsvDataFormat>- Returns:
- New instance of the writer settings
-
createWriter
protected com.univocity.parsers.tsv.TsvWriter createWriter(Writer writer, com.univocity.parsers.tsv.TsvWriterSettings settings)
Creates a new instance of the uniVocity writer.- Specified by:
createWriterin classAbstractUniVocityDataFormat<com.univocity.parsers.tsv.TsvFormat,com.univocity.parsers.tsv.TsvWriterSettings,com.univocity.parsers.tsv.TsvWriter,com.univocity.parsers.tsv.TsvParserSettings,com.univocity.parsers.tsv.TsvParser,UniVocityTsvDataFormat>- Parameters:
writer- Output writer to usesettings- Writer settings to use- Returns:
- New uinstance of the uniVocity writer
-
createParserSettings
protected com.univocity.parsers.tsv.TsvParserSettings createParserSettings()
Creates a new instance of the parser settings.- Specified by:
createParserSettingsin classAbstractUniVocityDataFormat<com.univocity.parsers.tsv.TsvFormat,com.univocity.parsers.tsv.TsvWriterSettings,com.univocity.parsers.tsv.TsvWriter,com.univocity.parsers.tsv.TsvParserSettings,com.univocity.parsers.tsv.TsvParser,UniVocityTsvDataFormat>- Returns:
- New instance of the parser settings
-
createParser
protected com.univocity.parsers.tsv.TsvParser createParser(com.univocity.parsers.tsv.TsvParserSettings settings)
Creates a new instance of the uniVocity parser.- Specified by:
createParserin classAbstractUniVocityDataFormat<com.univocity.parsers.tsv.TsvFormat,com.univocity.parsers.tsv.TsvWriterSettings,com.univocity.parsers.tsv.TsvWriter,com.univocity.parsers.tsv.TsvParserSettings,com.univocity.parsers.tsv.TsvParser,UniVocityTsvDataFormat>- Parameters:
settings- Parser settings to use- Returns:
- New instance of the uniVocity parser
-
configureFormat
protected void configureFormat(com.univocity.parsers.tsv.TsvFormat format)
Configures the format.- Overrides:
configureFormatin classAbstractUniVocityDataFormat<com.univocity.parsers.tsv.TsvFormat,com.univocity.parsers.tsv.TsvWriterSettings,com.univocity.parsers.tsv.TsvWriter,com.univocity.parsers.tsv.TsvParserSettings,com.univocity.parsers.tsv.TsvParser,UniVocityTsvDataFormat>- Parameters:
format- format to configure
-
getDataFormatName
public String getDataFormatName()
-
-