public class Optional extends ConvertNullTo
Prior to version 2.0.0, this processor returned null for empty String (""), but was updated because
Tokenizer now reads empty columns as null. It also means that Optional can now be used when writing as well
(instead of using ConvertNullTo("")
).
next
Constructor and Description |
---|
Optional()
Constructs a new Optional processor, which when encountering null will return null,
for all other values it will return the value unchanged.
|
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.
|
execute
toString, validateInputNotNull
public Optional()
public Optional(CellProcessor next)
next
- the next CellProcessor in the chainNullPointerException
- if next is nullCopyright © 2007–2015 Super CSV. All rights reserved.