RESOLVED - issue BATCH-376: Problem with DelimitedLineTokenizer and empty quoted value
http://jira.springframework.org/browse/BATCH-376
This commit is contained in:
@@ -164,7 +164,12 @@ public class DelimitedLineTokenizer extends AbstractLineTokenizer {
|
||||
String value = string.trim();
|
||||
if (isQuoted(value)) {
|
||||
value = StringUtils.replace(value, "" + quoteCharacter + quoteCharacter, "" + quoteCharacter);
|
||||
string = value.substring(1, value.length() - 1);
|
||||
int endLength = value.length() - 1;
|
||||
// used to deal with empty quoted values
|
||||
if(endLength == 0) {
|
||||
endLength = 1;
|
||||
}
|
||||
string = value.substring(1, endLength);
|
||||
}
|
||||
return string;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user