org.apache.solr.handler.loader

## Class ContentStreamLoader

- java.lang.Object
- - org.apache.solr.handler.loader.ContentStreamLoader

- Direct Known Subclasses:
    CSVLoader, JavabinLoader, JsonLoader, XMLLoader

      public abstract class ContentStreamLoader
      extends Object

  Load a `ContentStream` into Solr This should be thread safe and can be called from multiple threads

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected static int` | `pollQueueTime`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `ContentStreamLoader()`

  - ### Method Summary

    All Methods Instance Methods Abstract Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `String` | `getDefaultWT()`
    `ContentStreamLoader` | `init(SolrParams args)` This should be called once for each RequestHandler
    `abstract void` | `load(SolrQueryRequest req, SolrQueryResponse rsp, ContentStream stream, UpdateRequestProcessor processor)` Loaders are responsible for closing the stream

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### pollQueueTime

          protected static final int pollQueueTime

  - ### Constructor Detail

    - #### ContentStreamLoader

          public ContentStreamLoader()

  - ### Method Detail

    - #### init

          public ContentStreamLoader init(SolrParams args)

      This should be called once for each RequestHandler

    - #### getDefaultWT

          public String getDefaultWT()

    - #### load

          public abstract void load(SolrQueryRequest req,
                                    SolrQueryResponse rsp,
                                    ContentStream stream,
                                    UpdateRequestProcessor processor)
                             throws Exception

      Loaders are responsible for closing the stream
      Parameters:
        `req` - The input `SolrQueryRequest`
        `rsp` - The response, in case the Loader wishes to add anything
        `stream` - The `ContentStream` to add
        `processor` - The `UpdateRequestProcessor` to use
      Throws:
        `Exception`

Copyright © 2000-2016 Apache Software Foundation. All Rights Reserved.