use of org.apache.hadoop.io.ShortWritable in project hadoop by apache.
the class FSImageSerialization method readShort.
/** read short value */
static short readShort(DataInput in) throws IOException {
ShortWritable uShort = TL_DATA.get().U_SHORT;
uShort.readFields(in);
return uShort.get();
}
use of org.apache.hadoop.io.ShortWritable in project hadoop by apache.
the class FSImageSerialization method writeShort.
/** write short value */
static void writeShort(short value, DataOutputStream out) throws IOException {
ShortWritable uShort = TL_DATA.get().U_SHORT;
uShort.set(value);
uShort.write(out);
}
use of org.apache.hadoop.io.ShortWritable in project druid by druid-io.
the class OrcStructConverterTest method testConvertRootFieldWithNonNullShortReturningOriginalValue.
@Test
public void testConvertRootFieldWithNonNullShortReturningOriginalValue() {
final OrcStructConverter converter = new OrcStructConverter(false);
assertConversion(converter, TypeDescription.createShort(), (short) 128, new ShortWritable((short) 128));
}
Aggregations