Ignore:
Timestamp:
2016-10-31T09:27:42+13:00 (7 years ago)
Author:
davidb
Message:

Further reversal of Base class. Switch to PerPage

File:
1 edited

Legend:

Unmodified
Added
Removed
  • other-projects/hathitrust/solr-extracted-features/trunk/src/main/java/org/hathitrust/extractedfeatures/PagedJSON.java

    r31003 r31006  
    44import java.util.Iterator;
    55import org.apache.spark.api.java.function.FlatMapFunction;
    6 import org.apache.spark.api.java.function.VoidFunction;
    76import org.apache.spark.util.DoubleAccumulator;
    87import org.json.JSONArray;
     
    1918
    2019
    21 class PagedJSON extends BasePerJSON implements FlatMapFunction<String, JSONObject>
     20class PagedJSON implements FlatMapFunction<String, JSONObject>
    2221//public class PagedJSON implements VoidFunction<String>
    2322{
    2423    private static final long serialVersionUID = 1L;
    2524   
    26     public PagedJSON()
    27     {
    28         super();
    29     }
     25    protected String _input_dir;
     26    protected String _solr_url;
     27    protected String _output_dir;
     28    protected int    _verbosity;
     29   
     30    protected DoubleAccumulator _progress_accum;
     31    protected double            _progress_step;
     32   
    3033    public PagedJSON(String input_dir, String solr_url, String output_dir, int verbosity,
    3134                     DoubleAccumulator progress_accum, double progress_step)
    3235    {
    33         super(input_dir,solr_url,output_dir,verbosity,progress_accum,progress_step);
     36        _input_dir  = input_dir;
     37        _solr_url   = solr_url;
     38        _output_dir = output_dir;
     39        _verbosity  = verbosity;
     40       
     41        _progress_accum = progress_accum;
     42        _progress_step  = progress_step;
    3443    }
    35    
    3644   
    3745    public Iterator<JSONObject> call(String json_file_in)
Note: See TracChangeset for help on using the changeset viewer.