/** * @param t operands * @return Array of byte arrays made from passed array of Text */ public static byte [][] toByteArrays(final String [] t) { byte [][] result = new byte[t.length][]; for (int i = 0; i < t.length; i++) { result[i] = Bytes.toBytes(t[i]); } return result; }
/** * @param t operands * @return Array of byte arrays made from passed array of Text */ public static byte [][] toByteArrays(final String [] t) { byte [][] result = new byte[t.length][]; for (int i = 0; i < t.length; i++) { result[i] = Bytes.toBytes(t[i]); } return result; }
@Override public byte [] asByteArray() { return Bytes.toBytes(timestamp); }
@Override public byte [] asByteArray() { return Bytes.toBytes(jdate); }
@Override public byte[] asByteArray() { return Bytes.toBytes(val); }
@Override public byte [] asByteArray() { return Bytes.toBytes(timestamp); }
@Override public byte[] asByteArray() { return Bytes.toBytes(val); }
/** * Serialize a double as the IEEE 754 double format output. The resultant * array will be 8 bytes long. * * @param d value * @return the double represented as byte [] */ public static byte [] toBytes(final double d) { // Encode it as a long return Bytes.toBytes(Double.doubleToRawLongBits(d)); }
/** * Serialize a double as the IEEE 754 double format output. The resultant * array will be 8 bytes long. * * @param d value * @return the double represented as byte [] */ public static byte [] toBytes(final double d) { // Encode it as a long return Bytes.toBytes(Double.doubleToRawLongBits(d)); }
/** * @param f float value * @return the float represented as byte [] */ public static byte [] toBytes(final float f) { // Encode it as int return Bytes.toBytes(Float.floatToRawIntBits(f)); }
/** * @param f float value * @return the float represented as byte [] */ public static byte [] toBytes(final float f) { // Encode it as int return Bytes.toBytes(Float.floatToRawIntBits(f)); }
/** * @param f float value * @return the float represented as byte [] */ public static byte [] toBytes(final float f) { // Encode it as int return Bytes.toBytes(Float.floatToRawIntBits(f)); }
/** * @param f float value * @return the float represented as byte [] */ public static byte [] toBytes(final float f) { // Encode it as int return Bytes.toBytes(Float.floatToRawIntBits(f)); }
/** * Serialize a double as the IEEE 754 double format output. The resultant * array will be 8 bytes long. * * @param d value * @return the double represented as byte [] */ public static byte [] toBytes(final double d) { // Encode it as a long return Bytes.toBytes(Double.doubleToRawLongBits(d)); }
/** * Serialize a double as the IEEE 754 double format output. The resultant * array will be 8 bytes long. * * @param d value * @return the double represented as byte [] */ public static byte [] toBytes(final double d) { // Encode it as a long return Bytes.toBytes(Double.doubleToRawLongBits(d)); }
@Override public byte [] asByteArray() { return Bytes.toBytes(asInt8()); }
/** * @param column operand * @return A byte array of a byte array where first and only entry is * <code>column</code> */ public static byte [][] toByteArrays(final String column) { return toByteArrays(toBytes(column)); }
/** * @param column operand * @return A byte array of a byte array where first and only entry is * <code>column</code> */ public static byte [][] toByteArrays(final String column) { return toByteArrays(toBytes(column)); }
@Override public byte [] asByteArray() { return Bytes.toBytes(asInt8()); }
public HTableDescriptor getTableDescriptor(String tableName) throws IOException { try (HBaseAdmin admin = new HBaseAdmin(conf)) { return admin.getTableDescriptor(Bytes.toBytes(tableName)); } }