Uses of Interface
org.supercsv.cellprocessor.ift.CellProcessor
Packages that use CellProcessor
Package
Description
Provides CellProcessor classes for conversion, formatting and parsing.
Provides CellProcessor classes for enforcing constraints.
Provides CellProcessor interfaces, used to control/restrict how processors can be chained together.
Provides CellProcessor classes for converting, formatting and parsing
java.time
classes.Provides the exceptions that may be thrown by Super CSV.
Provides the various readers and writers used to read/write Strings, Maps, or Objects.
Provides the utility classes used by Super CSV.
-
Uses of CellProcessor in org.supercsv.cellprocessor
Classes in org.supercsv.cellprocessor that implement CellProcessorModifier and TypeClassDescriptionclass
Abstract super class containing shared behaviour of all cell processors.private static final class
This is an implementation-specific processor and should only be used by the CellProcessorAdaptor class.class
This processor collects each value it encounters and adds it to the supplied Collection.class
This processor returns a specified default value if the input is null.class
Converts a Boolean into a formatted string.class
Converts a date into a formatted string using theSimpleDateFormat
class.class
Converts a double into a formatted string using theDecimalFormat
class and the default locale.class
Maps from one object to another, by looking up a Map with the input as the key, and returning its corresponding value.class
This processor is used to indicate that a cell is optional, and will avoid executing further processors if it encounters null.class
Convert a String to a BigDecimal.class
Converts a String to a Boolean.class
Converts a String to a Character.class
Converts a String to a Date using theSimpleDateFormat
class.class
Converts a String to a Double.class
Converts a String to an Enum.class
Converts a String to an Integer.class
Converts a String to a Long.class
Replaces each substring of the input string that matches the given regular expression with the given replacement.class
This processor is used in the situations you want to be able to check for the presence of a "special token".class
Ensure that Strings or String-representations of objects are trimmed (contain no surrounding whitespace).class
Ensure that Strings or String-representations of objects are truncated to a maximum size.Fields in org.supercsv.cellprocessor declared as CellProcessorModifier and TypeFieldDescriptionprotected final CellProcessor
CellProcessorAdaptor.next
the next processor in the chainConstructors in org.supercsv.cellprocessor with parameters of type CellProcessorModifierConstructorDescriptionprotected
Constructor used by CellProcessors that require CellProcessor chaining (further processing is required).Collector
(Collection<Object> collection, CellProcessor next) Constructs a new Collector, which collects each value it encounters, adds it to the supplied Collection, then calls the next processor in the chain.ConvertNullTo
(Object returnValue, CellProcessor next) Constructs a new ConvertNullTo processor, which returns a specified default value if the input is null.HashMapper
(Map<Object, Object> mapping, Object defaultValue, CellProcessor next) Constructs a new HashMapper processor, which maps from one object to another, by looking up a Map with the input as the key, and returning its corresponding value.HashMapper
(Map<Object, Object> mapping, CellProcessor next) Constructs a new HashMapper processor, which maps from one object to another, by looking up a Map with the input as the key, and returning its corresponding value.Optional
(CellProcessor next) Constructs a new Optional processor, which when encountering null will return null , for all other values it will call the next processor in the chain.ParseBigDecimal
(DecimalFormatSymbols symbols, CellProcessor next) Constructs a new ParseBigDecimal processor, which converts a String to a BigDecimal using the supplied DecimalFormatSymbols object to convert any decimal separator to a "." before creating the BigDecimal, then calls the next processor in the chain.ParseBigDecimal
(CellProcessor next) Constructs a new ParseBigDecimal processor, which converts a String to a BigDecimal then calls the next processor in the chain.ParseEnum
(Class<T> enumClass, boolean ignoreCase, CellProcessor next) Constructs a new ParseEnum processor, which converts a String to a Enum, ignoring the case of the input (or not) depending on the supplied flag, then calls the next processor in the chain.ParseEnum
(Class<T> enumClass, CellProcessor next) Constructs a new ParseEnum processor, which converts a String to a Enum then calls the next processor in the chain.Token
(Object token, Object returnValue, CellProcessor next) Constructs a new Token processor, which returns the supplied value if the token is encountered, otherwise it passes the input unchanged to the next processor in the chain. -
Uses of CellProcessor in org.supercsv.cellprocessor.constraint
Classes in org.supercsv.cellprocessor.constraint that implement CellProcessorModifier and TypeClassDescriptionclass
Converts the input data to a Double and ensures that number is within a specified numeric range (inclusive).class
This constraint ensures that all input data is equal (to each other, or to a supplied constant value).class
Converts the input to a String and ensures that it doesn't contain any of the supplied substrings.class
This processor ensures that the input value is an element of a Collection.class
This processor ensures that the input value belongs to a specific set of (unchangeable) values.class
Converts the input data to a Long and and ensures the value is between the supplied min and max values (inclusive).class
This processor ensures that the input is not null.class
This processor converts the input to a String, and ensures that the input's hash function matches any of a given set of hashcodes.class
Converts the input to a String and ensures that the input contains at least one of the specified substrings.class
This processor ensures that the input String has a length equal to any of the supplied lengths.class
This constraint ensures that the input data has a string length between the supplied min and max values (both inclusive).class
This processor checks if the input is null or an empty string, and raises an exception in that case.class
This constraint ensures that the input data matches the given regular expression.class
Ensure that upon processing a CSV file (reading or writing), that values of the column all are unique.class
Ensure that upon processing a CSV file (reading or writing), that values of the column are all unique.Constructors in org.supercsv.cellprocessor.constraint with parameters of type CellProcessorModifierConstructorDescriptionEquals
(Object constantValue, CellProcessor next) Constructs a new Equals processor, which ensures all input data is equal to the supplied constant value, then calls the the next processor in the chain.Equals
(CellProcessor next) Constructs a new Equals processor, which ensures all input data is equal, then calls the the next processor in the chain.ForbidSubStr
(String[] forbiddenSubStrings, CellProcessor next) Constructs a new ForbidSubStr processor which ensures the input doesn't contain any of the supplied substrings, then calls the next processor in the chain.ForbidSubStr
(String forbiddenSubString, CellProcessor next) Constructs a new ForbidSubStr processor which ensures the input doesn't contain the supplied substring, then calls the next processor in the chain.ForbidSubStr
(List<String> forbiddenSubStrings, CellProcessor next) Constructs a new ForbidSubStr processor which ensures the input doesn't contain any of the supplied substrings, then calls the next processor in the chain.IsElementOf
(Collection<Object> collection, CellProcessor next) Constructs a new IsElementOf, which ensures that the input value is an element of a Collection, then calls the next processor in the chain.IsIncludedIn
(Object[] possibleValues, CellProcessor next) Constructs a new IsIncludedIn processor, which ensures that the input value belongs to a specific set of given values, then calls the next processor in the chain.IsIncludedIn
(Set<Object> possibleValues, CellProcessor next) Constructs a new IsIncludedIn processor, which ensures that the input value belongs to a specific set of given values, then calls the next processor in the chain.NotNull
(CellProcessor next) Constructs a new NotNull which ensures that the input is not null, then calls the next processor in the chain.RequireHashCode
(int[] requiredHashcodes, CellProcessor next) Constructs a new RequireHashCode processor, which converts the input to a String, ensures that the input's hash function matches any of a given set of hashcodes, then calls the next processor in the chain.RequireHashCode
(int requiredHashcode, CellProcessor next) Constructs a new RequireHashCode processor, which converts the input to a String, ensures that the input's hash function matches the supplied hashcode, then calls the next processor in the chain.RequireSubStr
(String[] requiredSubStrings, CellProcessor next) Converts the input to a String, ensures that the input contains at least one of the specified substrings, then calls the next processor in the chain.RequireSubStr
(String requiredSubString, CellProcessor next) Converts the input to a String, ensures that the input contains the specified substring, then calls the next processor in the chain.RequireSubStr
(List<String> requiredSubStrings, CellProcessor next) Converts the input to a String, ensures that the input contains at least one of the specified substrings, then calls the next processor in the chain.Strlen
(int[] requiredLengths, CellProcessor next) Constructs a new Strlen processor, which ensures that the input String has a length equal to any of the supplied lengths, then calls the next processor in the chain.Strlen
(int requiredLength, CellProcessor next) Constructs a new Strlen processor, which ensures that the input String has a length equal to the supplied length, then calls the next processor in the chain.StrMinMax
(long min, long max, CellProcessor next) Constructs a new StrMinMax processor, which ensures that the input data has a string length between the supplied min and max values (both inclusive), then calls the next processor in the chain.Constructs a new StrNotNullOrEmpty processor, which checks for null/empty Strings, then calls the next processor in the chain.Unique
(CellProcessor next) Constructs a new Unique processor, which ensures that all rows in a column are unique, then calls the next processor in the chain.UniqueHashCode
(CellProcessor next) Constructs a new UniqueHashCode processor, which ensures that all rows in a column are unique, then calls the next processor in the chain. -
Uses of CellProcessor in org.supercsv.cellprocessor.ift
Subinterfaces of CellProcessor in org.supercsv.cellprocessor.iftModifier and TypeInterfaceDescriptioninterface
Interface to indicate the a CellProcessor is capable of processing Boolean values.interface
Interface to indicate the a CellProcessor is capable of processing Date values.interface
Interface to indicate the a CellProcessor is capable of processing Double values.interface
Interface to indicate the a CellProcessor is capable of processing Long values.interface
Interface to indicate the a CellProcessor is capable of processing String values. -
Uses of CellProcessor in org.supercsv.cellprocessor.time
Classes in org.supercsv.cellprocessor.time that implement CellProcessorModifier and TypeClassDescriptionclass
Abstract base class for cell processors convertingTemporalAccessor
types to Strings.class
Abstract base class for cell processors converting Strings toTemporalAccessor
types.class
Converts a Duration to a String.class
Converts a LocalDate to a String.class
Converts a LocalDateTime to a String.class
Converts a LocalTime to a String.class
Converts a Period to a String.class
Converts a ZonedDateTime to a String.class
Converts a ZoneId to a String.class
Converts a String to a Duration.class
Converts a String to a LocalDate.class
Converts a String to a LocalDateTime.class
Converts a String to a LocalTime.class
Converts a String to a Period.class
Converts a String to a ZonedDateTime.class
Converts a String to a ZoneId.Constructors in org.supercsv.cellprocessor.time with parameters of type CellProcessorModifierConstructorDescriptionAbstractTemporalAccessorFormattingProcessor
(DateTimeFormatter formatter, CellProcessor next) Constructs a new AbstractTemporalAccessorFormattingProcessor processor, which formats the type as a String using the supplied formatter, then calls the next processor in the chain.Constructs a new AbstractTemporalAccessorFormattingProcessor processor, which formats the type as a String, then calls the next processor in the chain.AbstractTemporalAccessorParsingProcessor
(DateTimeFormatter formatter, CellProcessor next) Constructs a new AbstractTemporalAccessorParsingProcessor processor, which parses a String as aTemporalAccessor
type using the supplied formatter, then calls the next processor in the chain.Constructs a new AbstractTemporalAccessorParsingProcessor processor, which parses a String as aTemporalAccessor
type, then calls the next processor in the chain.FmtDuration
(CellProcessor next) Constructs a new FmtDuration processor, which formats a Duration as a String, then calls the next processor in the chain.FmtLocalDate
(DateTimeFormatter formatter, CellProcessor next) Constructs a new FmtLocalDate processor, which formats a LocalDate as a String using the supplied formatter, then calls the next processor in the chain.FmtLocalDate
(CellProcessor next) Constructs a new FmtLocalDate processor, which formats a LocalDate as a String, then calls the next processor in the chain.FmtLocalDateTime
(DateTimeFormatter formatter, CellProcessor next) Constructs a new FmtLocalDateTime processor, which formats a LocalDateTime as a String using the supplied formatter, then calls the next processor in the chain.Constructs a new FmtLocalDateTime processor, which formats a LocalDateTime as a String, then calls the next processor in the chain.FmtLocalTime
(DateTimeFormatter formatter, CellProcessor next) Constructs a new FmtLocalTime processor, which formats a LocalTime as a String using the supplied formatter, then calls the next processor in the chain.FmtLocalTime
(CellProcessor next) Constructs a new FmtLocalTime processor, which formats a LocalTime as a String, then calls the next processor in the chain.FmtPeriod
(CellProcessor next) Constructs a new FmtPeriod processor, which formats a Period as a String, then calls the next processor in the chain.FmtZonedDateTime
(DateTimeFormatter formatter, CellProcessor next) Constructs a new FmtZonedDateTime processor, which formats a ZonedDateTime as a String using the supplied formatter, then calls the next processor in the chain.Constructs a new FmtZonedDateTime processor, which formats a ZonedDateTime as a String, then calls the next processor in the chain.FmtZoneId
(TextStyle textStyle, Locale locale, CellProcessor next) Constructs a new FmtZoneId processor, which formats a ZoneId as String, then calls the next processor in the chain.FmtZoneId
(CellProcessor next) Constructs a new FmtZoneId processor, which formats a ZoneId as a String, then calls the next processor in the chain.ParseDuration
(CellProcessor next) Constructs a new ParseDuration processor, which parses a String as a Duration, then calls the next processor in the chain.ParseLocalDate
(DateTimeFormatter formatter, CellProcessor next) Constructs a new ParseLocalDate processor, which parses a String as a LocalDate using the supplied formatter, then calls the next processor in the chain.ParseLocalDate
(CellProcessor next) Constructs a new ParseLocalDate processor, which parses a String recognised byLocalDate.parse(CharSequence)
as a LocalDate, then calls the next processor in the chain.ParseLocalDateTime
(DateTimeFormatter formatter, CellProcessor next) Constructs a new ParseLocalDateTime processor, which parses a String as a LocalDateTime using the supplied formatter, then calls the next processor in the chain.Constructs a new ParseLocalDateTime processor, which parses a String as a LocalDateTime, then calls the next processor in the chain.ParseLocalTime
(DateTimeFormatter formatter, CellProcessor next) Constructs a new ParseLocalTime processor, which parses a String as a LocalTime using the supplied formatter, then calls the next processor in the chain.ParseLocalTime
(CellProcessor next) Constructs a new ParseLocalTime processor, which parses a String as a LocalTime, then calls the next processor in the chain.ParsePeriod
(CellProcessor next) Constructs a new ParsePeriod processor, which parses a String as a Period, then calls the next processor in the chain.ParseZonedDateTime
(DateTimeFormatter formatter, CellProcessor next) Constructs a new ParseZonedDateTime processor, which parses a String as a ZonedDateTime using the supplied formatter, then calls the next processor in the chain.Constructs a new ParseZonedDateTime processor, which parses a String as a ZonedDateTime, then calls the next processor in the chain.ParseZoneId
(Map<String, String> aliasMap, CellProcessor next) Constructs a new ParseZoneId processor, which parses a String as a ZoneId using the supplied Zone ID mappings, then calls the next processor in the chain.ParseZoneId
(CellProcessor next) Constructs a new ParseZoneId processor, which parses a String as a ZoneId, then calls the next processor in the chain. -
Uses of CellProcessor in org.supercsv.exception
Fields in org.supercsv.exception declared as CellProcessorModifier and TypeFieldDescriptionprivate final CellProcessor
SuperCsvCellProcessorException.processor
Methods in org.supercsv.exception that return CellProcessorModifier and TypeMethodDescriptionSuperCsvCellProcessorException.getProcessor()
Gets the processor that was executing.Constructors in org.supercsv.exception with parameters of type CellProcessorModifierConstructorDescriptionSuperCsvCellProcessorException
(Class<?> expectedType, Object actualValue, CsvContext context, CellProcessor processor) Constructs a new SuperCsvCellProcessorException to indicate that the value received by a CellProcessor wasn't of the correct type.SuperCsvCellProcessorException
(String msg, CsvContext context, CellProcessor processor) Constructs a new SuperCsvCellProcessorException.SuperCsvCellProcessorException
(String msg, CsvContext context, CellProcessor processor, Throwable t) Constructs a new SuperCsvCellProcessorException.SuperCsvConstraintViolationException
(String msg, CsvContext context, CellProcessor processor) Constructs a new SuperCsvConstraintViolationException.SuperCsvConstraintViolationException
(String msg, CsvContext context, CellProcessor processor, Throwable t) Constructs a new SuperCsvConstraintViolationException. -
Uses of CellProcessor in org.supercsv.io
Methods in org.supercsv.io with parameters of type CellProcessorModifier and TypeMethodDescriptionAbstractCsvReader.executeProcessors
(List<Object> processedColumns, CellProcessor[] processors) Executes the supplied cell processors on the last row of CSV that was read and populates the supplied List of processed columns.CsvListReader.executeProcessors
(CellProcessor... processors) Executes the supplied cell processors on the last row of CSV that was read.ICsvListReader.executeProcessors
(CellProcessor... processors) Executes the supplied cell processors on the last row of CSV that was read.<T> T
CsvBeanReader.read
(Class<T> clazz, String[] nameMapping, CellProcessor... processors) Reads a row of a CSV file and populates an instance of the specified class, using the supplied name mapping to map column values to the appropriate fields.<T> T
CsvBeanReader.read
(T bean, String[] nameMapping, CellProcessor... processors) Reads a row of a CSV file and populates the bean, using the supplied name mapping to map column values to the appropriate fields.CsvListReader.read
(CellProcessor... processors) Reads a row of a CSV file and returns a List of Objects containing each column.CsvMapReader.read
(String[] nameMapping, CellProcessor[] processors) Reads a row of a CSV file into a Map, using the supplied name mapping to map column values to the appropriate map entries, and the supplied processors to process the values before adding them to the Map.<T> T
ICsvBeanReader.read
(Class<T> clazz, String[] nameMapping, CellProcessor... processors) Reads a row of a CSV file and populates an instance of the specified class, using the supplied name mapping to map column values to the appropriate fields.<T> T
ICsvBeanReader.read
(T bean, String[] nameMapping, CellProcessor... processors) Reads a row of a CSV file and populates the bean, using the supplied name mapping to map column values to the appropriate fields.ICsvListReader.read
(CellProcessor... processors) Reads a row of a CSV file and returns a List of Objects containing each column.ICsvMapReader.read
(String[] nameMapping, CellProcessor[] processors) Reads a row of a CSV file into a Map, using the supplied name mapping to map column values to the appropriate map entries, and the supplied processors to process the values before adding them to the Map.private <T> T
CsvBeanReader.readIntoBean
(T bean, String[] nameMapping, CellProcessor[] processors) Reads a row of a CSV file and populates the bean, using the supplied name mapping to map column values to the appropriate fields.void
CsvBeanWriter.write
(Object source, String[] nameMapping, CellProcessor[] processors) Writes the fields of the object as columns of a CSV file, using the supplied name mapping to map fields to the appropriate columns.void
CsvListWriter.write
(List<?> columns, CellProcessor[] processors) Writes a List of Objects as columns of a CSV file, performing any necessary processing beforehand.void
CsvMapWriter.write
(Map<String, ?> values, String[] nameMapping, CellProcessor[] processors) Writes the values of the Map as columns of a CSV file, using the supplied name mapping to map values to the appropriate columns.void
CsvResultSetWriter.write
(ResultSet resultSet, CellProcessor[] writeProcessors) Writes a JDBCResultSet
as a CSV file.void
ICsvBeanWriter.write
(Object source, String[] nameMapping, CellProcessor[] processors) Writes the fields of the object as columns of a CSV file, using the supplied name mapping to map fields to the appropriate columns.void
ICsvListWriter.write
(List<?> columns, CellProcessor[] processors) Writes a List of Objects as columns of a CSV file, performing any necessary processing beforehand.void
ICsvMapWriter.write
(Map<String, ?> values, String[] nameMapping, CellProcessor[] processors) Writes the values of the Map as columns of a CSV file, using the supplied name mapping to map values to the appropriate columns.void
ICsvResultSetWriter.write
(ResultSet resultSet, CellProcessor[] cellProcessors) Writes a JDBCResultSet
as a CSV file.private void
CsvResultSetWriter.writeContents
(ResultSet resultSet, CellProcessor[] writeProcessors) -
Uses of CellProcessor in org.supercsv.util
Methods in org.supercsv.util with parameters of type CellProcessorModifier and TypeMethodDescriptionstatic void
Util.executeCellProcessors
(List<Object> destination, List<?> source, CellProcessor[] processors, int lineNo, int rowNo) Processes each element in the source List (using the corresponding processor chain in the processors array) and adds it to the destination List.