isEmpty_ = sketch.isEmpty(); theta_ = Math.min(sketch.getThetaLong(), theta); seedHash_ = Util.computeSeedHash(sketch.getSeed()); final int count = sketch.getRetainedEntries(); if (count > 0) {
)); dstMem.putByte(NUM_VALUES_BYTE, (byte) numValues_); dstMem.putShort(SEED_HASH_SHORT, Util.computeSeedHash(sketch.getSeed())); theta_ = Math.min(sketch.getThetaLong(), theta); dstMem.putLong(THETA_LONG, theta_);
@Override public String toString() { final StringBuilder sb = new StringBuilder(); sb.append("### ").append(this.getClass().getSimpleName()).append(" SUMMARY: ").append(LS); sb.append(" Estimate : ").append(getEstimate()).append(LS); sb.append(" Upper Bound, 95% conf : ").append(getUpperBound(2)).append(LS); sb.append(" Lower Bound, 95% conf : ").append(getLowerBound(2)).append(LS); sb.append(" Theta (double) : ").append(getTheta()).append(LS); sb.append(" Theta (long) : ").append(getThetaLong()).append(LS); sb.append(" EstMode? : ").append(isEstimationMode()).append(LS); sb.append(" Empty? : ").append(isEmpty()).append(LS); sb.append(" Retained Entries : ").append(getRetainedEntries()).append(LS); if (this instanceof ArrayOfDoublesUpdatableSketch) { final ArrayOfDoublesUpdatableSketch updatable = (ArrayOfDoublesUpdatableSketch) this; sb.append(" Nominal Entries (k) : ").append(updatable.getNominalEntries()).append(LS); sb.append(" Current Capacity : ").append(updatable.getCurrentCapacity()).append(LS); sb.append(" Resize Factor : ").append(updatable.getResizeFactor().getValue()).append(LS); sb.append(" Sampling Probability (p): ").append(updatable.getSamplingProbability()).append(LS); sb.append(" Update Seed : ") .append(Long.toHexString(updatable.getSeed())).append(" | ") .append(Long.toString(updatable.getSeed())).append(LS); } sb.append(" Seed Hash : ") .append(Integer.toHexString(Short.toUnsignedInt(getSeedHash()))).append(LS); sb.append("### END SKETCH SUMMARY").append(LS); return sb.toString(); }
isEmpty_ = sketch.isEmpty(); theta_ = Math.min(sketch.getThetaLong(), theta); seedHash_ = Util.computeSeedHash(sketch.getSeed()); final int count = sketch.getRetainedEntries(); if (count > 0) {
)); dstMem.putByte(NUM_VALUES_BYTE, (byte) numValues_); dstMem.putShort(SEED_HASH_SHORT, Util.computeSeedHash(sketch.getSeed())); theta_ = Math.min(sketch.getThetaLong(), theta); dstMem.putLong(THETA_LONG, theta_);