@Override public boolean equals(Object other) { if(other == null || !(other instanceof ComparableSplit)) return false; return (compareTo((ComparableSplit) other) == 0); }
public GuaguaSequenceRecordReader(Configuration conf, GuaguaFileSplit split, Class<? extends Writable> keyClass, Class<? extends Writable> valueClass) throws IOException { this.conf = conf; this.keyClass = keyClass; this.valueClass = valueClass; if(split != null) { initialize(split); } }
@Override public RecordWriter<Text, Text> getRecordWriter(TaskAttemptContext context) throws IOException, InterruptedException { return new GuaguaRecordWriter(); }
@Override public OutputCommitter getOutputCommitter(TaskAttemptContext context) throws IOException, InterruptedException { return new GuaguaOutputCommitter(); }
void removeFromNodes() { for(Node node: nodes) node.remove(this); }
private static void removeSplits(List<ComparableSplit> splits) { for(ComparableSplit split: splits) split.removeFromNodes(); }
public GuaguaLineRecordReader(Configuration conf, GuaguaFileSplit split) throws IOException { this.conf = conf; initialize(split); }
/** * Create a <code>GuaguaOptionsParser</code> to parse given options as well as generic Hadoop options. * * The resulting <code>CommandLine</code> object can be obtained by {@link #getCommandLine()}. * * @param conf * the configuration to modify * @param options * options built by the caller * @param args * User-specified arguments * @throws IOException */ public GuaguaOptionsParser(Configuration conf, Options options, String[] args) throws IOException { parseGeneralOptions(options, conf, args); this.conf = conf; }
@Override protected void cleanup(org.apache.hadoop.mapreduce.Mapper<LongWritable, Text, Text, Text>.Context context) throws IOException, InterruptedException { this.getGuaguaService().stop(); }
@Override public int hashCode() { final int prime = 31; int result = 1; result = prime * result + (isHalt() ? 1231 : 1237); result = prime * result + ((writable == null) ? 0 : writable.hashCode()); return result; }
@Override public boolean equals(Object other) { if(other == null || !(other instanceof ComparableSplit)) return false; return (compareTo((ComparableSplit) other) == 0); }
public GuaguaSequenceRecordReader(Configuration conf, GuaguaFileSplit split, Class<? extends Writable> keyClass, Class<? extends Writable> valueClass) throws IOException { this.conf = conf; this.keyClass = keyClass; this.valueClass = valueClass; if(split != null) { initialize(split); } }
@Override public RecordWriter<Text, Text> getRecordWriter(TaskAttemptContext context) throws IOException, InterruptedException { return new GuaguaRecordWriter(); }
@Override public OutputCommitter getOutputCommitter(TaskAttemptContext context) throws IOException, InterruptedException { return new GuaguaOutputCommitter(); }
void removeFromNodes() { for(Node node: nodes) node.remove(this); }
private static void removeSplits(List<ComparableSplit> splits) { for(ComparableSplit split: splits) split.removeFromNodes(); }
public GuaguaLineRecordReader(Configuration conf, GuaguaFileSplit split) throws IOException { this.conf = conf; initialize(split); }
/** * Create a <code>GuaguaOptionsParser</code> to parse given options as well as generic Hadoop options. * * The resulting <code>CommandLine</code> object can be obtained by {@link #getCommandLine()}. * * @param conf * the configuration to modify * @param options * options built by the caller * @param args * User-specified arguments * @throws IOException */ public GuaguaOptionsParser(Configuration conf, Options options, String[] args) throws IOException { parseGeneralOptions(options, conf, args); this.conf = conf; }
@Override protected void cleanup(org.apache.hadoop.mapreduce.Mapper<LongWritable, Text, Text, Text>.Context context) throws IOException, InterruptedException { this.getGuaguaService().stop(); }
@Override public int hashCode() { final int prime = 31; int result = 1; result = prime * result + (isHalt() ? 1231 : 1237); result = prime * result + ((writable == null) ? 0 : writable.hashCode()); return result; }