Package org.apache.solr.handler.extraction

Examples of org.apache.solr.handler.extraction.SolrContentHandler.newDocument()


        if (inputStream != null) {
          Closeables.closeQuietly(inputStream);
        }
      }
     
      SolrInputDocument doc = handler.newDocument();
      LOG.debug("solr doc: {}", doc);     
      Record outputRecord = toRecord(doc);
      return getChild().process(outputRecord);
    }
View Full Code Here


    StripNonCharSolrContentHandlerFactory contentHandlerFactory =
      new StripNonCharSolrContentHandlerFactory(DateUtil.DEFAULT_DATE_FORMATS);
    IndexSchema schema = h.getCore().getLatestSchema();
    SolrContentHandler contentHandler =
      contentHandlerFactory.createSolrContentHandler(metadata, new MapSolrParams(new HashMap()), schema);
    SolrInputDocument doc = contentHandler.newDocument();
    String foobar = doc.getFieldValue(fieldName).toString();
    assertTrue("foobar".equals(foobar));
  }

  /**
 
View Full Code Here

        if (inputStream != null) {
          Closeables.closeQuietly(inputStream);
        }
      }
     
      SolrInputDocument doc = handler.newDocument();
      LOG.debug("solr doc: {}", doc);     
      Record outputRecord = toRecord(doc);
      return getChild().process(outputRecord);
    }
View Full Code Here

    StripNonCharSolrContentHandlerFactory contentHandlerFactory =
      new StripNonCharSolrContentHandlerFactory(DateUtil.DEFAULT_DATE_FORMATS);
    IndexSchema schema = h.getCore().getLatestSchema();
    SolrContentHandler contentHandler =
      contentHandlerFactory.createSolrContentHandler(metadata, new MapSolrParams(new HashMap()), schema);
    SolrInputDocument doc = contentHandler.newDocument();
    String foobar = doc.getFieldValue(fieldName).toString();
    assertTrue("foobar".equals(foobar));
  }

  /**
 
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.