long[] offsets = new EstimatedHistogram().getBucketOffsets();
@Override public int hashCode() { return Objects.hashCode(getBucketOffsets(), getBuckets(false)); }
@Override public boolean equals(Object o) { if (this == o) return true; if (!(o instanceof EstimatedHistogram)) return false; EstimatedHistogram that = (EstimatedHistogram) o; return Arrays.equals(getBucketOffsets(), that.getBucketOffsets()) && Arrays.equals(getBuckets(false), that.getBuckets(false)); }
@Override public boolean equals(Object o) { if (this == o) return true; if (!(o instanceof EstimatedHistogram)) return false; EstimatedHistogram that = (EstimatedHistogram) o; return Arrays.equals(getBucketOffsets(), that.getBucketOffsets()) && Arrays.equals(getBuckets(false), that.getBuckets(false)); }
@Override public boolean equals(Object o) { if (this == o) return true; if (!(o instanceof EstimatedHistogram)) return false; EstimatedHistogram that = (EstimatedHistogram) o; return Arrays.equals(getBucketOffsets(), that.getBucketOffsets()) && Arrays.equals(getBuckets(false), that.getBuckets(false)); }
@Override public boolean equals(Object o) { if (this == o) return true; if (!(o instanceof EstimatedHistogram)) return false; EstimatedHistogram that = (EstimatedHistogram) o; return Arrays.equals(getBucketOffsets(), that.getBucketOffsets()) && Arrays.equals(getBuckets(false), that.getBuckets(false)); }
@Override public int hashCode() { return Objects.hashCode(getBucketOffsets(), getBuckets(false)); }
@Override public boolean equals(Object o) { if (this == o) return true; if (!(o instanceof EstimatedHistogram)) return false; EstimatedHistogram that = (EstimatedHistogram) o; return Arrays.equals(getBucketOffsets(), that.getBucketOffsets()) && Arrays.equals(getBuckets(false), that.getBuckets(false)); }
@Override public int hashCode() { return Objects.hashCode(getBucketOffsets(), getBuckets(false)); }
private static void printHistograms(StatsMetadata metadata, PrintStream out) { long[] offsets = metadata.estimatedPartitionSize.getBucketOffsets(); long[] ersh = metadata.estimatedPartitionSize.getBuckets(false); long[] ecch = metadata.estimatedColumnCount.getBuckets(false); out.println(String.format("%-10s%18s%18s", "Count", "Row Size", "Cell Count")); for (int i = 0; i < offsets.length; i++) { out.println(String.format("%-10d%18s%18s", offsets[i], (i < ersh.length ? ersh[i] : ""), (i < ecch.length ? ecch[i] : ""))); } }
@Override public int hashCode() { return Objects.hashCode(getBucketOffsets(), getBuckets(false)); }
@Override public int hashCode() { return Objects.hashCode(getBucketOffsets(), getBuckets(false)); }
public void serialize(EstimatedHistogram eh, DataOutputPlus out) throws IOException { long[] offsets = eh.getBucketOffsets(); long[] buckets = eh.getBuckets(false); out.writeInt(buckets.length); for (int i = 0; i < buckets.length; i++) { out.writeLong(offsets[i == 0 ? 0 : i - 1]); out.writeLong(buckets[i]); } }
public void serialize(EstimatedHistogram eh, DataOutputPlus out) throws IOException { long[] offsets = eh.getBucketOffsets(); long[] buckets = eh.getBuckets(false); out.writeInt(buckets.length); for (int i = 0; i < buckets.length; i++) { out.writeLong(offsets[i == 0 ? 0 : i - 1]); out.writeLong(buckets[i]); } }
public void serialize(EstimatedHistogram eh, DataOutputPlus out) throws IOException { long[] offsets = eh.getBucketOffsets(); long[] buckets = eh.getBuckets(false); out.writeInt(buckets.length); for (int i = 0; i < buckets.length; i++) { out.writeLong(offsets[i == 0 ? 0 : i - 1]); out.writeLong(buckets[i]); } }
public void serialize(EstimatedHistogram eh, DataOutputPlus out) throws IOException { long[] offsets = eh.getBucketOffsets(); long[] buckets = eh.getBuckets(false); out.writeInt(buckets.length); for (int i = 0; i < buckets.length; i++) { out.writeLong(offsets[i == 0 ? 0 : i - 1]); out.writeLong(buckets[i]); } }
public void serialize(EstimatedHistogram eh, DataOutputPlus out) throws IOException { long[] offsets = eh.getBucketOffsets(); long[] buckets = eh.getBuckets(false); out.writeInt(buckets.length); for (int i = 0; i < buckets.length; i++) { out.writeLong(offsets[i == 0 ? 0 : i - 1]); out.writeLong(buckets[i]); } }
public long serializedSize(EstimatedHistogram eh) { int size = 0; long[] offsets = eh.getBucketOffsets(); long[] buckets = eh.getBuckets(false); size += TypeSizes.sizeof(buckets.length); for (int i = 0; i < buckets.length; i++) { size += TypeSizes.sizeof(offsets[i == 0 ? 0 : i - 1]); size += TypeSizes.sizeof(buckets[i]); } return size; } }
public long serializedSize(EstimatedHistogram eh) { int size = 0; long[] offsets = eh.getBucketOffsets(); long[] buckets = eh.getBuckets(false); size += TypeSizes.sizeof(buckets.length); for (int i = 0; i < buckets.length; i++) { size += TypeSizes.sizeof(offsets[i == 0 ? 0 : i - 1]); size += TypeSizes.sizeof(buckets[i]); } return size; } }
public long serializedSize(EstimatedHistogram eh) { int size = 0; long[] offsets = eh.getBucketOffsets(); long[] buckets = eh.getBuckets(false); size += TypeSizes.sizeof(buckets.length); for (int i = 0; i < buckets.length; i++) { size += TypeSizes.sizeof(offsets[i == 0 ? 0 : i - 1]); size += TypeSizes.sizeof(buckets[i]); } return size; } }