Class ComparableBytes

  • All Implemented Interfaces:
    Comparable<org.apache.hadoop.io.BinaryComparable>

    @Deprecated
    public class ComparableBytes
    extends org.apache.hadoop.io.BinaryComparable
    Deprecated.
    since 1.7.0 In an attempt to clean up types in the data package that were not intended to be in public API this type was deprecated. Technically this method was not considered part of the public API in 1.6.0 and earlier, therefore it could have been deleted. However a decision was made to deprecate in order to be cautious and avoid confusion between 1.6.0 and 1.7.0.
    An array of bytes wrapped so as to extend Hadoop's BinaryComparable class.
    • Field Detail

      • data

        public byte[] data
        Deprecated.
    • Constructor Detail

      • ComparableBytes

        public ComparableBytes​(byte[] b)
        Deprecated.
        Creates a new byte wrapper. The given byte array is used directly as a backing array, so later changes made to the array reflect into the new object.
        Parameters:
        b - bytes to wrap
    • Method Detail

      • getBytes

        public byte[] getBytes()
        Deprecated.
        Gets the wrapped bytes in this object.
        Specified by:
        getBytes in class org.apache.hadoop.io.BinaryComparable
        Returns:
        bytes
      • getLength

        public int getLength()
        Deprecated.
        Specified by:
        getLength in class org.apache.hadoop.io.BinaryComparable