@Override public Row applyToRow(Row row) { lastRowClustering = row.clustering(); return row; }
public void add(int i, Row row) { clustering = row.clustering(); rows[i] = row; ++rowsToMerge; lastRowSet = i; }
public void add(int i, Row row) { clustering = row.clustering(); rows[i] = row; ++rowsToMerge; lastRowSet = i; }
@Override public Row applyToRow(Row row) { lastClustering = row.clustering(); return row; }
public Row next() { Row row = this.rowIterator.next(); lastClustering = row.clustering(); return row; } }
protected void recordLast(DecoratedKey key, Row last) { if (last != null) { lastReturnedKey = key; if (last.clustering() != Clustering.STATIC_CLUSTERING) lastReturnedRow = PagingState.RowMark.create(command.metadata(), last, protocolVersion); } }
protected void recordLast(DecoratedKey key, Row last) { if (last != null && last.clustering() != Clustering.STATIC_CLUSTERING) lastReturned = PagingState.RowMark.create(command.metadata(), last, protocolVersion); }
@Override public Row applyToRow(Row row) { collector.updateClusteringValues(row.clustering()); cellCount += Rows.collectStats(row, collector); return row; }
public void removeRow(Row row) { if (isPrimaryKeyIndex()) return; if (indexedColumn.isComplex()) removeCells(row.clustering(), row.getComplexColumnData(indexedColumn)); else removeCell(row.clustering(), row.getCell(indexedColumn)); }
public boolean isFullyCoveredBy(CachedPartition partition) { if (partition.isEmpty()) return false; // 'partition' contains all columns, so it covers our filter if our last clusterings // is smaller than the last in the cache return clusterings.comparator().compare(clusterings.last(), partition.lastRow().clustering()) <= 0; }
public boolean isFullyCoveredBy(CachedPartition partition) { if (partition.isEmpty()) return false; // 'partition' contains all columns, so it covers our filter if our last clusterings // is smaller than the last in the cache return clusterings.comparator().compare(clusterings.last(), partition.lastRow().clustering()) <= 0; }
private void validateClusterings(PartitionUpdate update) throws InvalidRequestException { assert indexedColumn.isClusteringColumn(); for (Row row : update) validateIndexedValue(getIndexedValue(null, row.clustering(), null)); }
public Row readStaticRow() throws IOException { Row row = super.readStaticRow(); if (!row.deletion().isLive()) return BTreeRow.emptyDeletedRow(row.clustering(), row.deletion()); return Rows.EMPTY_STATIC_ROW; }
private long serializedSize(Row row, SerializationHeader header, long previousUnfilteredSize, int version) { long size = 1; // flags if (hasExtendedFlags(row)) size += 1; // extended flags if (!row.isStatic()) size += Clustering.serializer.serializedSize(row.clustering(), version, header.clusteringTypes()); return size + serializedRowBodySize(row, header, previousUnfilteredSize, version); }
private long serializedSize(Row row, SerializationHeader header, long previousUnfilteredSize, int version) { long size = 1; // flags if (hasExtendedFlags(row)) size += 1; // extended flags if (!row.isStatic()) size += Clustering.serializer.serializedSize(row.clustering(), version, header.clusteringTypes()); return size + serializedRowBodySize(row, header, previousUnfilteredSize, version); }
@Override public boolean equals(Object other) { if(!(other instanceof Row)) return false; Row that = (Row)other; if (!this.clustering().equals(that.clustering()) || !this.primaryKeyLivenessInfo().equals(that.primaryKeyLivenessInfo()) || !this.deletion().equals(that.deletion())) return false; return Iterables.elementsEqual(this, that); }
public Row readStaticRow() throws IOException { if (header.hasStatic()) { Row staticRow = UnfilteredSerializer.serializer.deserializeStaticRow(in, header, helper); if (!staticRow.deletion().isLive()) return BTreeRow.emptyDeletedRow(staticRow.clustering(), staticRow.deletion()); } return Rows.EMPTY_STATIC_ROW; }
public Row readStaticRow() throws IOException { if (header.hasStatic()) { Row staticRow = UnfilteredSerializer.serializer.deserializeStaticRow(in, header, helper); if (!staticRow.deletion().isLive()) return BTreeRow.emptyDeletedRow(staticRow.clustering(), staticRow.deletion()); } return Rows.EMPTY_STATIC_ROW; }
public boolean isFullyCoveredBy(CachedPartition partition) { // Partition is guaranteed to cover the whole filter if it includes the filter start and finish bounds. // (note that since partition is the head of a partition, to have no lower bound is ok) if (!slices.hasUpperBound() || partition.isEmpty()) return false; return partition.metadata().comparator.compare(slices.get(slices.size() - 1).end(), partition.lastRow().clustering()) <= 0; }
public boolean isFullyCoveredBy(CachedPartition partition) { // Partition is guaranteed to cover the whole filter if it includes the filter start and finish bounds. // (note that since partition is the head of a partition, to have no lower bound is ok) if (!slices.hasUpperBound() || partition.isEmpty()) return false; return partition.metadata().comparator.compare(slices.get(slices.size() - 1).end(), partition.lastRow().clustering()) <= 0; }