public HiveKey read(Kryo kryo, Input input, Class<HiveKey> type) { int len = input.readVarInt(true); byte[] bytes = new byte[len]; input.readBytes(bytes); return new HiveKey(bytes, input.readVarInt(false)); } }
public BytesWritable read(Kryo kryo, Input input, Class<BytesWritable> type) { int len = input.readVarInt(true); byte[] bytes = new byte[len]; input.readBytes(bytes); return new BytesWritable(bytes); }
public HiveKey read(Kryo kryo, Input input, Class<HiveKey> type) { int len = input.readVarInt(true); byte[] bytes = new byte[len]; input.readBytes(bytes); return new HiveKey(bytes); } }
/** Reads a 1-5 byte int. This stream may consider such a variable length encoding request as a hint. It is not guaranteed that * a variable length encoding will be really used. The stream may decide to use native-sized integer representation for * efficiency reasons. **/ public int readInt (boolean optimizePositive) throws KryoException { return readVarInt(optimizePositive); }
/** Reads a 1-5 byte int. This stream may consider such a variable length encoding request as a hint. It is not guaranteed that * a variable length encoding will be really used. The stream may decide to use native-sized integer representation for * efficiency reasons. **/ public int readInt (boolean optimizePositive) throws KryoException { return readVarInt(optimizePositive); }
/** Reads a 1-5 byte int. This stream may consider such a variable length encoding request as a hint. It is not guaranteed that * a variable length encoding will be really used. The stream may decide to use native-sized integer representation for * efficiency reasons. **/ public int readInt (boolean optimizePositive) throws KryoException { return readVarInt(optimizePositive); }
public float[] read (Kryo kryo, Input input, Class<float[]> type) { int length = input.readVarInt(true); if (length == NULL) return null; return input.readFloats(length - 1); }
public boolean[] read (Kryo kryo, Input input, Class<boolean[]> type) { int length = input.readVarInt(true); if (length == NULL) return null; boolean[] array = new boolean[--length]; for (int i = 0; i < length; i++) array[i] = input.readBoolean(); return array; }
public char[] read (Kryo kryo, Input input, Class<char[]> type) { int length = input.readVarInt(true); if (length == NULL) return null; return input.readChars(length-1); }
public byte[] read (Kryo kryo, Input input, Class<byte[]> type) { int length = input.readVarInt(true); if (length == NULL) return null; return input.readBytes(length - 1); }
public long[] read (Kryo kryo, Input input, Class<long[]> type) { int length = input.readVarInt(true); if (length == NULL) return null; return input.readLongs(length-1, false); }
public int[] read (Kryo kryo, Input input, Class<int[]> type) { int length = input.readVarInt(true); if (length == NULL) return null; return input.readInts(length - 1, false); }
public char[] read (Kryo kryo, Input input, Class<char[]> type) { int length = input.readVarInt(true); if (length == NULL) return null; return input.readChars(length - 1); }
public boolean[] read (Kryo kryo, Input input, Class<boolean[]> type) { int length = input.readVarInt(true); if (length == NULL) return null; boolean[] array = new boolean[--length]; for (int i = 0; i < length; i++) array[i] = input.readBoolean(); return array; }
public Enum read (Kryo kryo, Input input, Class<Enum> type) { int ordinal = input.readVarInt(true); if (ordinal == NULL) return null; ordinal--; if (ordinal < 0 || ordinal > enumConstants.length - 1) throw new KryoException("Invalid ordinal for enum \"" + type.getName() + "\": " + ordinal); Object constant = enumConstants[ordinal]; return (Enum)constant; } }
public byte[] read (Kryo kryo, Input input, Class<byte[]> type) { int length = input.readVarInt(true); if (length == NULL) return null; return input.readBytes(length - 1); }
public long[] read (Kryo kryo, Input input, Class<long[]> type) { int length = input.readVarInt(true); if (length == NULL) return null; return input.readLongs(length - 1, false); }
public int[] read (Kryo kryo, Input input, Class<int[]> type) { int length = input.readVarInt(true); if (length == NULL) return null; return input.readInts(length - 1, false); }
public short[] read (Kryo kryo, Input input, Class<short[]> type) { int length = input.readVarInt(true); if (length == NULL) return null; return input.readShorts(length-1); }
public char[] read (Kryo kryo, Input input, Class<char[]> type) { int length = input.readVarInt(true); if (length == NULL) return null; return input.readChars(length - 1); }