Example usage for org.apache.solr.client.solrj.io Tuple getDouble

List of usage examples for org.apache.solr.client.solrj.io Tuple getDouble

Introduction

In this page you can find the example usage for org.apache.solr.client.solrj.io Tuple getDouble.

Prototype

public Double getDouble(Object key) 

Source Link

Usage

From source file:org.deeplearning4j.nn.dataimport.solr.client.solrj.io.stream.TupleStreamDataSetIterator.java

License:Apache License

private static double getValue(Tuple tuple, String key, String idKey) {
    final Double value = tuple.getDouble(key);
    if (value == null) {
        // log potentially useful debugging info here ...
        if (idKey == null) {
            log.info("tuple[{}]={}", key, value);
        } else {/*w  w w  .  j av  a2 s  .  c  o m*/
            log.info("tuple[{}]={} tuple[{}]={}", key, value, idKey, tuple.get(idKey));
        }
        // ... before proceeding to hit the NullPointerException below
    }
    return value.doubleValue();
}