public long readLong() throws IOException { return dataReader.readLong(); }
public EstimatedHistogram deserialize(DataInputPlus in) throws IOException { int size = in.readInt(); long[] offsets = new long[size - 1]; long[] buckets = new long[size]; for (int i = 0; i < size; i++) { offsets[i == 0 ? 0 : i - 1] = in.readLong(); buckets[i] = in.readLong(); } return new EstimatedHistogram(offsets, buckets); }
public EstimatedHistogram deserialize(DataInputPlus in) throws IOException { int size = in.readInt(); long[] offsets = new long[size - 1]; long[] buckets = new long[size]; for (int i = 0; i < size; i++) { offsets[i == 0 ? 0 : i - 1] = in.readLong(); buckets[i] = in.readLong(); } return new EstimatedHistogram(offsets, buckets); }
/** * Reads only the data 'position' of the index entry and returns it. Note that this left 'in' in the middle * of reading an entry, so this is only useful if you know what you are doing and in most case 'deserialize' * should be used instead. */ public static long readPosition(DataInputPlus in, Version version) throws IOException { return version.storeRows() ? in.readUnsignedVInt() : in.readLong(); }
/** * Reads only the data 'position' of the index entry and returns it. Note that this left 'in' in the middle * of reading an entry, so this is only useful if you know what you are doing and in most case 'deserialize' * should be used instead. */ public static long readPosition(DataInputPlus in, Version version) throws IOException { return version.storeRows() ? in.readUnsignedVInt() : in.readLong(); }
public DeletionTime deserialize(DataInputPlus in) throws IOException { int ldt = in.readInt(); long mfda = in.readLong(); return mfda == Long.MIN_VALUE && ldt == Integer.MAX_VALUE ? LIVE : new DeletionTime(mfda, ldt); }
static long deserializePositionAndSkip(DataInputPlus in) throws IOException { long position = in.readLong(); int size = in.readInt(); if (size > 0) in.skipBytesFully(size); return position; } }
static long deserializePositionAndSkip(DataInputPlus in) throws IOException { long position = in.readLong(); int size = in.readInt(); if (size > 0) in.skipBytesFully(size); return position; } }
public DeletionTime deserialize(DataInputPlus in) throws IOException { int ldt = in.readInt(); long mfda = in.readLong(); return mfda == Long.MIN_VALUE && ldt == Integer.MAX_VALUE ? LIVE : new DeletionTime(mfda, ldt); }
/** * Reads only the data 'position' of the index entry and returns it. Note that this left 'in' in the middle * of reading an entry, so this is only useful if you know what you are doing and in most case 'deserialize' * should be used instead. */ public static long readPosition(DataInputPlus in, Version version) throws IOException { return version.storeRows() ? in.readUnsignedVInt() : in.readLong(); }
public DeletionTime deserialize(DataInputPlus in) throws IOException { int ldt = in.readInt(); long mfda = in.readLong(); return mfda == Long.MIN_VALUE && ldt == Integer.MAX_VALUE ? LIVE : new DeletionTime(mfda, ldt); }
public StreamingHistogram deserialize(DataInputPlus in) throws IOException { int maxBinSize = in.readInt(); int size = in.readInt(); Map<Number, long[]> tmp = new HashMap<>(size); for (int i = 0; i < size; i++) { tmp.put(in.readDouble(), new long[]{in.readLong()}); } return new StreamingHistogram(maxBinSize, tmp); }
public StreamingHistogram deserialize(DataInputPlus in) throws IOException { int maxBinSize = in.readInt(); int size = in.readInt(); Map<Number, long[]> tmp = new HashMap<>(size); for (int i = 0; i < size; i++) { tmp.put(in.readDouble(), new long[]{in.readLong()}); } return new StreamingHistogram(maxBinSize, tmp); }
public IRowCacheEntry deserialize(DataInputPlus in) throws IOException { boolean isSentinel = in.readBoolean(); if (isSentinel) return new RowCacheSentinel(in.readLong()); return CachedPartition.cacheSerializer.deserialize(in); }
public StreamSummary deserialize(DataInputPlus in, int version) throws IOException { UUID cfId = UUIDSerializer.serializer.deserialize(in, MessagingService.current_version); int files = in.readInt(); long totalSize = in.readLong(); return new StreamSummary(cfId, files, totalSize); }
public Hint deserialize(DataInputPlus in, int version) throws IOException { long creationTime = in.readLong(); int gcgs = (int) in.readUnsignedVInt(); return new Hint(Mutation.serializer.deserialize(in, version), creationTime, gcgs); } }
public Hint deserialize(DataInputPlus in, int version) throws IOException { long creationTime = in.readLong(); int gcgs = (int) in.readUnsignedVInt(); return new Hint(Mutation.serializer.deserialize(in, version), creationTime, gcgs); } }
public StreamSummary deserialize(DataInputPlus in, int version) throws IOException { UUID cfId = UUIDSerializer.serializer.deserialize(in, MessagingService.current_version); int files = in.readInt(); long totalSize = in.readLong(); return new StreamSummary(cfId, files, totalSize); }
public StreamSummary deserialize(DataInputPlus in, int version) throws IOException { UUID cfId = UUIDSerializer.serializer.deserialize(in, MessagingService.current_version); int files = in.readInt(); long totalSize = in.readLong(); return new StreamSummary(cfId, files, totalSize); }
public Batch deserialize(DataInputPlus in, int version) throws IOException { UUID id = UUIDSerializer.serializer.deserialize(in, version); long creationTime = in.readLong(); /* * If version doesn't match the current one, we cannot not just read the encoded mutations verbatim, * so we decode them instead, to deal with compatibility. */ return version == MessagingService.current_version ? createRemote(id, creationTime, readEncodedMutations(in)) : createLocal(id, creationTime, decodeMutations(in, version)); }