public static DataBlockEncoding getEncodingById(short dataBlockEncodingId) {
    DataBlockEncoding algorithm = null;
    if (dataBlockEncodingId >= 0 && dataBlockEncodingId <= Byte.MAX_VALUE) {
      algorithm = idArray[dataBlockEncodingId];
    }
    if (algorithm == null) {
      throw new IllegalArgumentException(String
        .format("There is no data block encoder for given id '%d'", (int) dataBlockEncodingId));
    }
    return algorithm;
  }
Check if given encoder has this id.
@param encoder   encoder which id will be checked
@param encoderId id which we except
@return true if id is right for given encoder, false otherwise
@exception IllegalArgumentException thrown when there is no matching data block encoder
hbase-common/src/main/java/org/apache/hadoop/hbase/io/encoding/DataBlockEncoding.java