Package org.refcodes.textual
Interface CsvBuilder
-
- All Known Implementing Classes:
CsvBuilderImpl
public interface CsvBuilder
The Interface CsvBuilder.- Author:
- steiner
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description CsvEscapeMode
getCsvEscapeMode()
Retrieves the CSV escape mode from the CSV escape mode property.char
getDelimiterChar()
Retrieves the delimiter char from the delimiter char property.java.util.Collection<java.lang.Object>
getFields()
Retrieves the CSV elements from the CSV elements property.java.lang.String
getRecord()
Retrieves the CSV line from the CSV line property.void
setCsvEscapeMode(CsvEscapeMode aCsvEscapeMode)
Sets the CSV escape mode for the CSV escape mode property.void
setDelimiterChar(char aDelimiterChar)
Sets the delimiter char for the delimiter char property.default void
setFields(boolean... aFields)
Sets the CSV elements for the CSV elements property.default void
setFields(byte... aFields)
Sets the CSV elements for the CSV elements property.default void
setFields(char... aFields)
Sets the CSV elements for the CSV elements property.default void
setFields(double... aFields)
Sets the CSV elements for the CSV elements property.default void
setFields(float... aFields)
Sets the CSV elements for the CSV elements property.default void
setFields(int... aFields)
Sets the CSV elements for the CSV elements property.default void
setFields(long... aFields)
Sets the CSV elements for the CSV elements property.default void
setFields(short... aFields)
Sets the CSV elements for the CSV elements property.default void
setFields(java.lang.Boolean... aFields)
Sets the CSV elements for the CSV elements property.default void
setFields(java.lang.Byte... aFields)
Sets the CSV elements for the CSV elements property.default void
setFields(java.lang.Character... aFields)
Sets the CSV elements for the CSV elements property.default void
setFields(java.lang.Double... aFields)
Sets the CSV elements for the CSV elements property.default void
setFields(java.lang.Float... aFields)
Sets the CSV elements for the CSV elements property.default void
setFields(java.lang.Integer... aFields)
Sets the CSV elements for the CSV elements property.default void
setFields(java.lang.Long... aFields)
Sets the CSV elements for the CSV elements property.void
setFields(java.lang.Object... aFields)
Sets the CSV elements for the CSV elements property.default void
setFields(java.lang.Short... aFields)
Sets the CSV elements for the CSV elements property.default void
setFields(java.lang.String... aFields)
Sets the CSV elements for the CSV elements property.void
setFields(java.util.Collection<java.lang.Object> aFields)
Sets the CSV elements for the CSV elements property.void
setRecord(java.lang.String aRecord)
Sets the CSV line for the CSV line property.java.util.List<java.lang.String>
toFields()
Creates a list ofString
elements from the CSV line being set viasetRecord(String)
orwithRecord(String)
.default java.lang.String[]
toFields(java.lang.String aRecord)
To fields.java.lang.String
toRecord()
Creates a CSV line from the elements being set viasetFields(String[])
orwithFields(String[])
.default java.lang.String
toRecord(boolean... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method).default java.lang.String
toRecord(byte... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method).default java.lang.String
toRecord(char... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method).default java.lang.String
toRecord(double... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method).default java.lang.String
toRecord(float... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method).default java.lang.String
toRecord(int... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method).default java.lang.String
toRecord(long... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method).default java.lang.String
toRecord(short... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method).default java.lang.String
toRecord(java.lang.Boolean... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method).default java.lang.String
toRecord(java.lang.Byte... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method).default java.lang.String
toRecord(java.lang.Character... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method).default java.lang.String
toRecord(java.lang.Double... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method).default java.lang.String
toRecord(java.lang.Float... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method).default java.lang.String
toRecord(java.lang.Integer... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method).default java.lang.String
toRecord(java.lang.Long... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method).java.lang.String
toRecord(java.lang.Object... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method).default java.lang.String
toRecord(java.lang.Short... aFields)
To record.default java.lang.String
toRecord(java.lang.String... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method).java.lang.String
toRecord(java.util.Collection<java.lang.Object> aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method).java.lang.String
toString()
TheString
being build by the builder upon the settings of the attributes.java.lang.String[]
toStrings()
Creates an array ofString
s from the CSV line being set viasetRecord(String)
orwithRecord(String)
.java.lang.String[]
toStrings(java.lang.String aRecord)
Creates an array ofString
s from the CSV line being set viasetRecord(String)
orwithRecord(String)
.default CsvBuilder
withCsvEscapeMode(CsvEscapeMode aCsvEscapeMode)
Sets the CSV escape mode for the CSV escape mode property.default CsvBuilder
withDelimiterChar(char aDelimiterChar)
Sets the delimiter char for the delimiter char property.default CsvBuilder
withFields(boolean... aFields)
Sets the CSV elements for the CSV elements property.default CsvBuilder
withFields(byte... aFields)
Sets the CSV elements for the CSV elements property.default CsvBuilder
withFields(char... aFields)
Sets the CSV elements for the CSV elements property.default CsvBuilder
withFields(double... aFields)
Sets the CSV elements for the CSV elements property.default CsvBuilder
withFields(float... aFields)
Sets the CSV elements for the CSV elements property.default CsvBuilder
withFields(int... aFields)
Sets the CSV elements for the CSV elements property.default CsvBuilder
withFields(long... aFields)
Sets the CSV elements for the CSV elements property.default CsvBuilder
withFields(short... aFields)
Sets the CSV elements for the CSV elements property.default CsvBuilder
withFields(java.lang.Boolean... aFields)
Sets the CSV elements for the CSV elements property.default CsvBuilder
withFields(java.lang.Byte... aFields)
Sets the CSV elements for the CSV elements property.default CsvBuilder
withFields(java.lang.Character... aFields)
Sets the CSV elements for the CSV elements property.default CsvBuilder
withFields(java.lang.Double... aFields)
Sets the CSV elements for the CSV elements property.default CsvBuilder
withFields(java.lang.Float... aFields)
Sets the CSV elements for the CSV elements property.default CsvBuilder
withFields(java.lang.Integer... aFields)
Sets the CSV elements for the CSV elements property.default CsvBuilder
withFields(java.lang.Long... aFields)
Sets the CSV elements for the CSV elements property.default CsvBuilder
withFields(java.lang.Object... aFields)
Sets the CSV elements for the CSV elements property.default CsvBuilder
withFields(java.lang.Short... aFields)
Sets the CSV elements for the CSV elements property.default CsvBuilder
withFields(java.lang.String... aFields)
Sets the CSV elements for the CSV elements property.default CsvBuilder
withFields(java.util.Collection<java.lang.Object> aFields)
Sets the CSV elements for the CSV elements property.default CsvBuilder
withRecord(java.lang.String aRecord)
Sets the CSV line for the CSV line property.
-
-
-
Method Detail
-
getCsvEscapeMode
CsvEscapeMode getCsvEscapeMode()
Retrieves the CSV escape mode from the CSV escape mode property.- Returns:
- The CSV escape mode stored by the CSV escape mode property.
-
setCsvEscapeMode
void setCsvEscapeMode(CsvEscapeMode aCsvEscapeMode)
Sets the CSV escape mode for the CSV escape mode property.- Parameters:
aCsvEscapeMode
- The CSV escape mode to be stored by the align text mode property.
-
withCsvEscapeMode
default CsvBuilder withCsvEscapeMode(CsvEscapeMode aCsvEscapeMode)
Sets the CSV escape mode for the CSV escape mode property.- Parameters:
aCsvEscapeMode
- The CSV escape mode to be stored by the align text mode property.- Returns:
- The builder for applying multiple build operations.
-
getDelimiterChar
char getDelimiterChar()
Retrieves the delimiter char from the delimiter char property.- Returns:
- The delimiter char stored by the Separator char property.
-
setDelimiterChar
void setDelimiterChar(char aDelimiterChar)
Sets the delimiter char for the delimiter char property.- Parameters:
aDelimiterChar
- The delimiter char to be stored by the text align mode property.
-
withDelimiterChar
default CsvBuilder withDelimiterChar(char aDelimiterChar)
Sets the delimiter char for the delimiter char property.- Parameters:
aDelimiterChar
- The delimiter char to be stored by the text align mode property.- Returns:
- The builder for applying multiple build operations.
-
getRecord
java.lang.String getRecord()
Retrieves the CSV line from the CSV line property.- Returns:
- The CSV line stored by the CSV line property.
-
setRecord
void setRecord(java.lang.String aRecord)
Sets the CSV line for the CSV line property.- Parameters:
aRecord
- The CSV line to be stored by the CSV line property.
-
withRecord
default CsvBuilder withRecord(java.lang.String aRecord)
Sets the CSV line for the CSV line property.- Parameters:
aRecord
- The CSV line to be stored by the CSV line property.- Returns:
- The builder for applying multiple build operations.
-
setFields
void setFields(java.lang.Object... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.
-
setFields
default void setFields(boolean... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.
-
setFields
default void setFields(byte... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.
-
setFields
default void setFields(short... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.
-
setFields
default void setFields(int... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.
-
setFields
default void setFields(long... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.
-
setFields
default void setFields(float... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.
-
setFields
default void setFields(double... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.
-
setFields
default void setFields(char... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.
-
withFields
default CsvBuilder withFields(boolean... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.- Returns:
- The builder for applying multiple build operations.
-
withFields
default CsvBuilder withFields(byte... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.- Returns:
- The builder for applying multiple build operations.
-
withFields
default CsvBuilder withFields(short... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.- Returns:
- The builder for applying multiple build operations.
-
withFields
default CsvBuilder withFields(int... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.- Returns:
- The builder for applying multiple build operations.
-
withFields
default CsvBuilder withFields(long... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.- Returns:
- The builder for applying multiple build operations.
-
withFields
default CsvBuilder withFields(float... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.- Returns:
- The builder for applying multiple build operations.
-
withFields
default CsvBuilder withFields(double... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.- Returns:
- The builder for applying multiple build operations.
-
withFields
default CsvBuilder withFields(char... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.- Returns:
- The builder for applying multiple build operations.
-
setFields
default void setFields(java.lang.Boolean... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.
-
setFields
default void setFields(java.lang.Byte... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.
-
setFields
default void setFields(java.lang.Short... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.
-
setFields
default void setFields(java.lang.Integer... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.
-
setFields
default void setFields(java.lang.Long... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.
-
setFields
default void setFields(java.lang.Float... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.
-
setFields
default void setFields(java.lang.Double... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.
-
setFields
default void setFields(java.lang.Character... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.
-
setFields
default void setFields(java.lang.String... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.
-
withFields
default CsvBuilder withFields(java.lang.Object... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.- Returns:
- The builder for applying multiple build operations.
-
withFields
default CsvBuilder withFields(java.lang.Boolean... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.- Returns:
- The builder for applying multiple build operations.
-
withFields
default CsvBuilder withFields(java.lang.Byte... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.- Returns:
- The builder for applying multiple build operations.
-
withFields
default CsvBuilder withFields(java.lang.Short... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.- Returns:
- The builder for applying multiple build operations.
-
withFields
default CsvBuilder withFields(java.lang.Integer... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.- Returns:
- The builder for applying multiple build operations.
-
withFields
default CsvBuilder withFields(java.lang.Long... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.- Returns:
- The builder for applying multiple build operations.
-
withFields
default CsvBuilder withFields(java.lang.Float... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.- Returns:
- The builder for applying multiple build operations.
-
withFields
default CsvBuilder withFields(java.lang.Double... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.- Returns:
- The builder for applying multiple build operations.
-
withFields
default CsvBuilder withFields(java.lang.Character... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.- Returns:
- The builder for applying multiple build operations.
-
withFields
default CsvBuilder withFields(java.lang.String... aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.- Returns:
- The builder for applying multiple build operations.
-
getFields
java.util.Collection<java.lang.Object> getFields()
Retrieves the CSV elements from the CSV elements property.- Returns:
- The CSV elements stored by the CSV elements property.
-
setFields
void setFields(java.util.Collection<java.lang.Object> aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.
-
withFields
default CsvBuilder withFields(java.util.Collection<java.lang.Object> aFields)
Sets the CSV elements for the CSV elements property.- Parameters:
aFields
- The CSV elements to be stored by the CSV elements property.- Returns:
- The builder for applying multiple build operations.
-
toFields
java.util.List<java.lang.String> toFields() throws java.lang.IllegalStateException
Creates a list ofString
elements from the CSV line being set viasetRecord(String)
orwithRecord(String)
.- Returns:
- The elements created from the CSV line.
- Throws:
java.lang.IllegalStateException
- Thrown in case no elements have been set via thewithFields(String[])
orsetFields(String[])
methods.
-
toRecord
java.lang.String toRecord() throws java.lang.IllegalStateException
Creates a CSV line from the elements being set viasetFields(String[])
orwithFields(String[])
.- Returns:
- The CSV line created from the CSV line.
- Throws:
java.lang.IllegalStateException
- Thrown in case no CSV line has been set via thewithRecord(String)
orsetRecord(String)
methods.
-
toRecord
default java.lang.String toRecord(boolean... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method). Still changing for example the delimiter viawithDelimiterChar(char)
can cause side effects! For avoiding thread race conditions / side effects regarding the fields (and the resulting record), use this method instead of the combination ofwithFields(String...)
withtoRecord()
.- Parameters:
aFields
- The CSV elements to be converted into a record.- Returns:
- The CSV line created from the fields.
-
toRecord
default java.lang.String toRecord(byte... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method). Still changing for example the delimiter viawithDelimiterChar(char)
can cause side effects! For avoiding thread race conditions / side effects regarding the fields (and the resulting record), use this method instead of the combination ofwithFields(String...)
withtoRecord()
.- Parameters:
aFields
- The CSV elements to be converted into a record.- Returns:
- The CSV line created from the fields.
-
toRecord
default java.lang.String toRecord(short... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method). Still changing for example the delimiter viawithDelimiterChar(char)
can cause side effects! For avoiding thread race conditions / side effects regarding the fields (and the resulting record), use this method instead of the combination ofwithFields(String...)
withtoRecord()
.- Parameters:
aFields
- The CSV elements to be converted into a record.- Returns:
- The CSV line created from the fields.
-
toRecord
default java.lang.String toRecord(int... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method). Still changing for example the delimiter viawithDelimiterChar(char)
can cause side effects! For avoiding thread race conditions / side effects regarding the fields (and the resulting record), use this method instead of the combination ofwithFields(String...)
withtoRecord()
.- Parameters:
aFields
- The CSV elements to be converted into a record.- Returns:
- The CSV line created from the fields.
-
toRecord
default java.lang.String toRecord(long... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method). Still changing for example the delimiter viawithDelimiterChar(char)
can cause side effects! For avoiding thread race conditions / side effects regarding the fields (and the resulting record), use this method instead of the combination ofwithFields(String...)
withtoRecord()
.- Parameters:
aFields
- The CSV elements to be converted into a record.- Returns:
- The CSV line created from the fields.
-
toRecord
default java.lang.String toRecord(float... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method). Still changing for example the delimiter viawithDelimiterChar(char)
can cause side effects! For avoiding thread race conditions / side effects regarding the fields (and the resulting record), use this method instead of the combination ofwithFields(String...)
withtoRecord()
.- Parameters:
aFields
- The CSV elements to be converted into a record.- Returns:
- The CSV line created from the fields.
-
toRecord
default java.lang.String toRecord(double... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method). Still changing for example the delimiter viawithDelimiterChar(char)
can cause side effects! For avoiding thread race conditions / side effects regarding the fields (and the resulting record), use this method instead of the combination ofwithFields(String...)
withtoRecord()
.- Parameters:
aFields
- The CSV elements to be converted into a record.- Returns:
- The CSV line created from the fields.
-
toRecord
default java.lang.String toRecord(char... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method). Still changing for example the delimiter viawithDelimiterChar(char)
can cause side effects! For avoiding thread race conditions / side effects regarding the fields (and the resulting record), use this method instead of the combination ofwithFields(String...)
withtoRecord()
.- Parameters:
aFields
- The CSV elements to be converted into a record.- Returns:
- The CSV line created from the fields.
-
toRecord
java.lang.String toRecord(java.lang.Object... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method). Still changing for example the delimiter viawithDelimiterChar(char)
can cause side effects! For avoiding thread race conditions / side effects regarding the fields (and the resulting record), use this method instead of the combination ofwithFields(String...)
withtoRecord()
.- Parameters:
aFields
- The CSV elements to be converted into a record.- Returns:
- The CSV line created from the fields.
-
toRecord
java.lang.String toRecord(java.util.Collection<java.lang.Object> aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method). Still changing for example the delimiter viawithDelimiterChar(char)
can cause side effects! For avoiding thread race conditions / side effects regarding the fields (and the resulting record), use this method instead of the combination ofwithFields(String...)
withtoRecord()
.- Parameters:
aFields
- The CSV elements to be converted into a record.- Returns:
- The CSV line created from the fields.
-
toRecord
default java.lang.String toRecord(java.lang.Boolean... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method). Still changing for example the delimiter viawithDelimiterChar(char)
can cause side effects! For avoiding thread race conditions / side effects regarding the fields (and the resulting record), use this method instead of the combination ofwithFields(String...)
withtoRecord()
.- Parameters:
aFields
- The CSV elements to be converted into a record.- Returns:
- The CSV line created from the fields.
-
toRecord
default java.lang.String toRecord(java.lang.Byte... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method). Still changing for example the delimiter viawithDelimiterChar(char)
can cause side effects! For avoiding thread race conditions / side effects regarding the fields (and the resulting record), use this method instead of the combination ofwithFields(String...)
withtoRecord()
.- Parameters:
aFields
- The CSV elements to be converted into a record.- Returns:
- The CSV line created from the fields.
-
toRecord
default java.lang.String toRecord(java.lang.Short... aFields)
To record.- Parameters:
aFields
- the fields- Returns:
- the string
-
toRecord
default java.lang.String toRecord(java.lang.Integer... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method). Still changing for example the delimiter viawithDelimiterChar(char)
can cause side effects! For avoiding thread race conditions / side effects regarding the fields (and the resulting record), use this method instead of the combination ofwithFields(String...)
withtoRecord()
.- Parameters:
aFields
- The CSV elements to be converted into a record.- Returns:
- The CSV line created from the fields.
-
toRecord
default java.lang.String toRecord(java.lang.Long... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method). Still changing for example the delimiter viawithDelimiterChar(char)
can cause side effects! For avoiding thread race conditions / side effects regarding the fields (and the resulting record), use this method instead of the combination ofwithFields(String...)
withtoRecord()
.- Parameters:
aFields
- The CSV elements to be converted into a record.- Returns:
- The CSV line created from the fields.
-
toRecord
default java.lang.String toRecord(java.lang.Float... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method). Still changing for example the delimiter viawithDelimiterChar(char)
can cause side effects! For avoiding thread race conditions / side effects regarding the fields (and the resulting record), use this method instead of the combination ofwithFields(String...)
withtoRecord()
.- Parameters:
aFields
- The CSV elements to be converted into a record.- Returns:
- The CSV line created from the fields.
-
toRecord
default java.lang.String toRecord(java.lang.Double... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method). Still changing for example the delimiter viawithDelimiterChar(char)
can cause side effects! For avoiding thread race conditions / side effects regarding the fields (and the resulting record), use this method instead of the combination ofwithFields(String...)
withtoRecord()
.- Parameters:
aFields
- The CSV elements to be converted into a record.- Returns:
- The CSV line created from the fields.
-
toRecord
default java.lang.String toRecord(java.lang.Character... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method). Still changing for example the delimiter viawithDelimiterChar(char)
can cause side effects! For avoiding thread race conditions / side effects regarding the fields (and the resulting record), use this method instead of the combination ofwithFields(String...)
withtoRecord()
.- Parameters:
aFields
- The CSV elements to be converted into a record.- Returns:
- The CSV line created from the fields.
-
toRecord
default java.lang.String toRecord(java.lang.String... aFields)
Creates a CSV line from the fields being provided This method is to be side effect free in terms of the fields (and the resulting record) is not part of the state for this instance (from the point of view of this method). Still changing for example the delimiter viawithDelimiterChar(char)
can cause side effects! For avoiding thread race conditions / side effects regarding the fields (and the resulting record), use this method instead of the combination ofwithFields(String...)
withtoRecord()
.- Parameters:
aFields
- The CSV elements to be converted into a record.- Returns:
- The CSV line created from the fields.
-
toStrings
java.lang.String[] toStrings()
Creates an array ofString
s from the CSV line being set viasetRecord(String)
orwithRecord(String)
. It should return the same result as an array as a call totoFields()
.- Returns:
- The elements created from the CSV line.
-
toFields
default java.lang.String[] toFields(java.lang.String aRecord)
To fields.- Parameters:
aRecord
- the record- Returns:
- the string[]
- See Also:
toStrings(String)
-
toStrings
java.lang.String[] toStrings(java.lang.String aRecord)
Creates an array ofString
s from the CSV line being set viasetRecord(String)
orwithRecord(String)
. It should return the same result as an array as a call totoFields()
. This method is to be side effect free in terms of the record (and the resulting fields) is not part of the state for this instance (from the point of view of this method). Still changing for example the delimiter viawithDelimiterChar(char)
can cause side effects! For avoiding thread race conditions / side effects regarding the record (and the resulting fields), use this method instead of the combination ofwithRecord(String)
withtoStrings()
.- Parameters:
aRecord
- The CSV line to be stored by the CSV line property.- Returns:
- The elements created from the CSV line.
-
toString
java.lang.String toString()
TheString
being build by the builder upon the settings of the attributes. It should return the same result as a call totoRecord()
.- Overrides:
toString
in classjava.lang.Object
- Returns:
- The according resulting
String
-
-