public abstract class CSVLoaderBase extends ContentStreamLoader
Modifier and Type | Field and Description |
---|---|
static String |
EMPTY |
static String |
ENCAPSULATOR |
static String |
ESCAPE |
static String |
FIELDNAMES |
static String |
HEADER |
static String |
LITERALS_PREFIX |
static String |
MAP |
static String |
OVERWRITE |
protected UpdateRequestProcessor |
processor |
static String |
ROW_ID |
static String |
ROW_ID_OFFSET |
static String |
SEPARATOR |
static String |
SKIP |
static String |
SKIPLINES |
static String |
SPLIT |
protected AddUpdateCommand |
templateAdd |
static String |
TRIM |
Modifier | Constructor and Description |
---|---|
protected |
CSVLoaderBase(SolrQueryRequest req,
UpdateRequestProcessor processor) |
Modifier and Type | Method and Description |
---|---|
abstract void |
addDoc(int line,
String[] vals)
called for each line of values (document)
|
protected void |
doAdd(int line,
String[] vals,
SolrInputDocument doc,
AddUpdateCommand template)
this must be MT safe...
|
void |
load(SolrQueryRequest req,
SolrQueryResponse rsp,
ContentStream stream,
UpdateRequestProcessor processor)
load the CSV input
|
getDefaultWT, init
public static final String SEPARATOR
public static final String FIELDNAMES
public static final String HEADER
public static final String SKIP
public static final String SKIPLINES
public static final String MAP
public static final String TRIM
public static final String EMPTY
public static final String SPLIT
public static final String ENCAPSULATOR
public static final String ESCAPE
public static final String OVERWRITE
public static final String LITERALS_PREFIX
public static final String ROW_ID
public static final String ROW_ID_OFFSET
protected final UpdateRequestProcessor processor
protected final AddUpdateCommand templateAdd
protected CSVLoaderBase(SolrQueryRequest req, UpdateRequestProcessor processor)
public void load(SolrQueryRequest req, SolrQueryResponse rsp, ContentStream stream, UpdateRequestProcessor processor) throws IOException
load
in class ContentStreamLoader
req
- The input SolrQueryRequest
rsp
- The response, in case the Loader wishes to add anythingstream
- The ContentStream
to addprocessor
- The UpdateRequestProcessor
to useIOException
public abstract void addDoc(int line, String[] vals) throws IOException
IOException
protected void doAdd(int line, String[] vals, SolrInputDocument doc, AddUpdateCommand template) throws IOException
IOException
Copyright © 2000-2021 Apache Software Foundation. All Rights Reserved.