Package org.apache.nutch.indexwriter.csv
Class CSVIndexWriter.Separator
- java.lang.Object
-
- org.apache.nutch.indexwriter.csv.CSVIndexWriter.Separator
-
- Enclosing class:
- CSVIndexWriter
protected class CSVIndexWriter.Separator extends Object
represent separators (also quote and escape characters) as char(s) and byte(s) in the output encoding for efficiency.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected int
find(String value, int start)
Get index of first occurrence of any separator characters.protected void
set(String str)
protected void
setFromConf(IndexWriterParams parameters, String property)
protected void
setFromConf(IndexWriterParams parameters, String property, boolean isChar)
String
toString()
-
-
-
Field Detail
-
sepStr
protected String sepStr
-
chars
protected char[] chars
-
bytes
protected byte[] bytes
-
-
Constructor Detail
-
Separator
protected Separator(String sep)
-
-
Method Detail
-
set
protected void set(String str)
-
setFromConf
protected void setFromConf(IndexWriterParams parameters, String property)
-
setFromConf
protected void setFromConf(IndexWriterParams parameters, String property, boolean isChar)
-
find
protected int find(String value, int start)
Get index of first occurrence of any separator characters.- Parameters:
value
- String to scanstart
- position/index to start scan from- Returns:
- position of first occurrence or -1 (not found or empty separator)
-
-