@Override public int hashCode() { return Objects.hash(column(), isCounterCell(), timestamp(), ttl(), localDeletionTime(), value(), path()); }
@Override public int hashCode() { return Objects.hash(column(), isCounterCell(), timestamp(), ttl(), localDeletionTime(), value(), path()); }
@Override public int hashCode() { return Objects.hash(column(), isCounterCell(), timestamp(), ttl(), localDeletionTime(), value(), path()); }
@Override public int hashCode() { return Objects.hash(column(), isCounterCell(), timestamp(), ttl(), localDeletionTime(), value(), path()); }
public void digest(MessageDigest digest) { if (isCounterCell()) { CounterContext.instance().updateDigest(digest, value()); } else { digest.update(value().duplicate()); } FBUtilities.updateWithLong(digest, timestamp()); FBUtilities.updateWithInt(digest, ttl()); FBUtilities.updateWithBoolean(digest, isCounterCell()); if (path() != null) path().digest(digest); }
public void digest(MessageDigest digest) { if (isCounterCell()) { CounterContext.instance().updateDigest(digest, value()); } else { digest.update(value().duplicate()); } FBUtilities.updateWithLong(digest, timestamp()); FBUtilities.updateWithInt(digest, ttl()); FBUtilities.updateWithBoolean(digest, isCounterCell()); if (path() != null) path().digest(digest); }
public void digest(MessageDigest digest) { digest.update(value().duplicate()); FBUtilities.updateWithLong(digest, timestamp()); FBUtilities.updateWithInt(digest, ttl()); FBUtilities.updateWithBoolean(digest, isCounterCell()); if (path() != null) path().digest(digest); }
public void digest(MessageDigest digest) { if (isCounterCell()) { CounterContext.instance().updateDigest(digest, value()); } else { digest.update(value().duplicate()); } FBUtilities.updateWithLong(digest, timestamp()); FBUtilities.updateWithInt(digest, ttl()); FBUtilities.updateWithBoolean(digest, isCounterCell()); if (path() != null) path().digest(digest); }
public Cell markCounterLocalToBeCleared() { if (!isCounterCell()) return this; ByteBuffer value = value(); ByteBuffer marked = CounterContext.instance().markLocalToBeCleared(value); return marked == value ? this : new BufferCell(column, timestamp(), ttl(), localDeletionTime(), marked, path()); }
public Cell markCounterLocalToBeCleared() { if (!isCounterCell()) return this; ByteBuffer value = value(); ByteBuffer marked = CounterContext.instance().markLocalToBeCleared(value); return marked == value ? this : new BufferCell(column, timestamp(), ttl(), localDeletionTime(), marked, path()); }
public Cell markCounterLocalToBeCleared() { if (!isCounterCell()) return this; ByteBuffer value = value(); ByteBuffer marked = CounterContext.instance().markLocalToBeCleared(value); return marked == value ? this : new BufferCell(column, timestamp(), ttl(), localDeletionTime(), marked, path()); }
@Override public boolean equals(Object other) { if (this == other) return true; if(!(other instanceof Cell)) return false; Cell that = (Cell)other; return this.column().equals(that.column()) && this.isCounterCell() == that.isCounterCell() && this.timestamp() == that.timestamp() && this.ttl() == that.ttl() && this.localDeletionTime() == that.localDeletionTime() && Objects.equals(this.value(), that.value()) && Objects.equals(this.path(), that.path()); }
public Cell markCounterLocalToBeCleared() { if (!isCounterCell()) return this; ByteBuffer value = value(); ByteBuffer marked = CounterContext.instance().markLocalToBeCleared(value); return marked == value ? this : new BufferCell(column, timestamp(), ttl(), localDeletionTime(), marked, path()); }
@Override public boolean equals(Object other) { if (this == other) return true; if(!(other instanceof Cell)) return false; Cell that = (Cell)other; return this.column().equals(that.column()) && this.isCounterCell() == that.isCounterCell() && this.timestamp() == that.timestamp() && this.ttl() == that.ttl() && this.localDeletionTime() == that.localDeletionTime() && Objects.equals(this.value(), that.value()) && Objects.equals(this.path(), that.path()); }
@Override public boolean equals(Object other) { if (this == other) return true; if(!(other instanceof Cell)) return false; Cell that = (Cell)other; return this.column().equals(that.column()) && this.isCounterCell() == that.isCounterCell() && this.timestamp() == that.timestamp() && this.ttl() == that.ttl() && this.localDeletionTime() == that.localDeletionTime() && Objects.equals(this.value(), that.value()) && Objects.equals(this.path(), that.path()); }
@Override public boolean equals(Object other) { if (this == other) return true; if(!(other instanceof Cell)) return false; Cell that = (Cell)other; return this.column().equals(that.column()) && this.isCounterCell() == that.isCounterCell() && this.timestamp() == that.timestamp() && this.ttl() == that.ttl() && this.localDeletionTime() == that.localDeletionTime() && Objects.equals(this.value(), that.value()) && Objects.equals(this.path(), that.path()); }
@Override public String toString() { if (isCounterCell()) return String.format("[%s=%d ts=%d]", column().name, CounterContext.instance().total(value()), timestamp()); AbstractType<?> type = column().type; if (type instanceof CollectionType && type.isMultiCell()) { CollectionType ct = (CollectionType)type; return String.format("[%s[%s]=%s %s]", column().name, ct.nameComparator().getString(path().get(0)), ct.valueComparator().getString(value()), livenessInfoString()); } if (isTombstone()) return String.format("[%s=<tombstone> %s]", column().name, livenessInfoString()); else return String.format("[%s=%s %s]", column().name, type.getString(value()), livenessInfoString()); }
@Override public String toString() { if (isCounterCell()) return String.format("[%s=%d ts=%d]", column().name, CounterContext.instance().total(value()), timestamp()); AbstractType<?> type = column().type; if (type instanceof CollectionType && type.isMultiCell()) { CollectionType ct = (CollectionType)type; return String.format("[%s[%s]=%s %s]", column().name, ct.nameComparator().getString(path().get(0)), ct.valueComparator().getString(value()), livenessInfoString()); } if (isTombstone()) return String.format("[%s=<tombstone> %s]", column().name, livenessInfoString()); else return String.format("[%s=%s %s]", column().name, type.getString(value()), livenessInfoString()); }
@Override public String toString() { if (isCounterCell()) return String.format("[%s=%d ts=%d]", column().name, CounterContext.instance().total(value()), timestamp()); AbstractType<?> type = column().type; if (type instanceof CollectionType && type.isMultiCell()) { CollectionType ct = (CollectionType)type; return String.format("[%s[%s]=%s %s]", column().name, ct.nameComparator().getString(path().get(0)), ct.valueComparator().getString(value()), livenessInfoString()); } if (isTombstone()) return String.format("[%s=<tombstone> %s]", column().name, livenessInfoString()); else return String.format("[%s=%s %s]", column().name, type.getString(value()), livenessInfoString()); }
@Override public String toString() { if (isCounterCell()) return String.format("[%s=%d ts=%d]", column().name, CounterContext.instance().total(value()), timestamp()); AbstractType<?> type = column().type; if (type instanceof CollectionType && type.isMultiCell()) { CollectionType ct = (CollectionType)type; return String.format("[%s[%s]=%s %s]", column().name, ct.nameComparator().getString(path().get(0)), ct.valueComparator().getString(value()), livenessInfoString()); } if (isTombstone()) return String.format("[%s=<tombstone> %s]", column().name, livenessInfoString()); else return String.format("[%s=%s %s]", column().name, type.getString(value()), livenessInfoString()); }