Tabnine Logo
DeletionTime$Serializer.deserialize
Code IndexAdd Tabnine to your IDE (free)

How to use
deserialize
method
in
org.apache.cassandra.db.DeletionTime$Serializer

Best Java code snippets using org.apache.cassandra.db.DeletionTime$Serializer.deserialize (Showing top 20 results out of 315)

origin: com.facebook.presto.cassandra/cassandra-server

public RangeTombstone deserializeBody(DataInput in, Composite min, Descriptor.Version version) throws IOException
{
  Composite max = type.serializer().deserialize(in);
  DeletionTime dt = DeletionTime.serializer.deserialize(in);
  // If the max equals the min.end(), we can avoid keeping an extra ByteBuffer in memory by using
  // min.end() instead of max
  Composite minEnd = min.end();
  max = minEnd.equals(max) ? minEnd : max;
  return new RangeTombstone(min, max, dt);
}
origin: org.apache.cassandra/cassandra-all

/**
 * Constructor called from {@link Serializer#deserializeForCache(org.apache.cassandra.io.util.DataInputPlus)}.
 */
private IndexedEntry(long dataFilePosition, DataInputPlus in, IndexInfo.Serializer idxInfoSerializer, Version version) throws IOException
{
  super(dataFilePosition);
  this.headerLength = in.readUnsignedVInt();
  this.deletionTime = DeletionTime.serializer.deserialize(in);
  int columnsIndexCount = (int) in.readUnsignedVInt();
  TrackedDataInputPlus trackedIn = new TrackedDataInputPlus(in);
  this.columnsIndex = new IndexInfo[columnsIndexCount];
  for (int i = 0; i < columnsIndexCount; i++)
    this.columnsIndex[i] = idxInfoSerializer.deserialize(trackedIn);
  this.offsets = null;
  this.indexedPartSize = (int) trackedIn.getBytesRead();
  this.idxInfoSerializer = idxInfoSerializer;
}
origin: com.strapdata.cassandra/cassandra-all

/**
 * Constructor for key-cache deserialization
 */
private ShallowIndexedEntry(long dataFilePosition, DataInputPlus in, IndexInfo.Serializer idxInfoSerializer) throws IOException
{
  super(dataFilePosition);
  this.indexFilePosition = in.readUnsignedVInt();
  this.headerLength = in.readUnsignedVInt();
  this.deletionTime = DeletionTime.serializer.deserialize(in);
  this.columnsIndexCount = (int) in.readUnsignedVInt();
  this.indexedPartSize = (int) in.readUnsignedVInt();
  this.idxInfoSerializer = idxInfoSerializer;
  this.fieldsSerializedSize = serializedSize(deletionTime, headerLength, columnsIndexCount);
  this.offsetsOffset = indexedPartSize + fieldsSerializedSize - columnsIndexCount * TypeSizes.sizeof(0);
}
origin: jsevellec/cassandra-unit

public static SSTableIdentityIterator create(SSTableReader sstable, RandomAccessReader file, DecoratedKey key)
{
  try
  {
    DeletionTime partitionLevelDeletion = DeletionTime.serializer.deserialize(file);
    SerializationHelper helper = new SerializationHelper(sstable.metadata, sstable.descriptor.version.correspondingMessagingVersion(), SerializationHelper.Flag.LOCAL);
    SSTableSimpleIterator iterator = SSTableSimpleIterator.create(sstable.metadata, file, sstable.header, helper, partitionLevelDeletion);
    return new SSTableIdentityIterator(sstable, key, partitionLevelDeletion, file.getPath(), iterator);
  }
  catch (IOException e)
  {
    sstable.markSuspect();
    throw new CorruptSSTableException(e, file.getPath());
  }
}
origin: com.strapdata.cassandra/cassandra-all

public static SSTableIdentityIterator create(SSTableReader sstable, RandomAccessReader file, DecoratedKey key)
{
  try
  {
    DeletionTime partitionLevelDeletion = DeletionTime.serializer.deserialize(file);
    SerializationHelper helper = new SerializationHelper(sstable.metadata, sstable.descriptor.version.correspondingMessagingVersion(), SerializationHelper.Flag.LOCAL);
    SSTableSimpleIterator iterator = SSTableSimpleIterator.create(sstable.metadata, file, sstable.header, helper, partitionLevelDeletion);
    return new SSTableIdentityIterator(sstable, key, partitionLevelDeletion, file.getPath(), iterator);
  }
  catch (IOException e)
  {
    sstable.markSuspect();
    throw new CorruptSSTableException(e, file.getPath());
  }
}
origin: jsevellec/cassandra-unit

/**
 * Constructor for key-cache deserialization
 */
private ShallowIndexedEntry(long dataFilePosition, DataInputPlus in, IndexInfo.Serializer idxInfoSerializer) throws IOException
{
  super(dataFilePosition);
  this.indexFilePosition = in.readUnsignedVInt();
  this.headerLength = in.readUnsignedVInt();
  this.deletionTime = DeletionTime.serializer.deserialize(in);
  this.columnsIndexCount = (int) in.readUnsignedVInt();
  this.indexedPartSize = (int) in.readUnsignedVInt();
  this.idxInfoSerializer = idxInfoSerializer;
  this.fieldsSerializedSize = serializedSize(deletionTime, headerLength, columnsIndexCount);
  this.offsetsOffset = indexedPartSize + fieldsSerializedSize - columnsIndexCount * TypeSizes.sizeof(0);
}
origin: org.apache.cassandra/cassandra-all

/**
 * Constructor for key-cache deserialization
 */
private ShallowIndexedEntry(long dataFilePosition, DataInputPlus in, IndexInfo.Serializer idxInfoSerializer) throws IOException
{
  super(dataFilePosition);
  this.indexFilePosition = in.readUnsignedVInt();
  this.headerLength = in.readUnsignedVInt();
  this.deletionTime = DeletionTime.serializer.deserialize(in);
  this.columnsIndexCount = (int) in.readUnsignedVInt();
  this.indexedPartSize = (int) in.readUnsignedVInt();
  this.idxInfoSerializer = idxInfoSerializer;
  this.fieldsSerializedSize = serializedSize(deletionTime, headerLength, columnsIndexCount);
  this.offsetsOffset = indexedPartSize + fieldsSerializedSize - columnsIndexCount * TypeSizes.sizeof(0);
}
origin: com.netflix.sstableadaptor/sstable-adaptor-cassandra

/**
 * Constructor for key-cache deserialization
 */
private ShallowIndexedEntry(long dataFilePosition, DataInputPlus in, IndexInfo.Serializer idxInfoSerializer) throws IOException
{
  super(dataFilePosition);
  this.indexFilePosition = in.readUnsignedVInt();
  this.headerLength = in.readUnsignedVInt();
  this.deletionTime = DeletionTime.serializer.deserialize(in);
  this.columnsIndexCount = (int) in.readUnsignedVInt();
  this.indexedPartSize = (int) in.readUnsignedVInt();
  this.idxInfoSerializer = idxInfoSerializer;
  this.fieldsSerializedSize = serializedSize(deletionTime, headerLength, columnsIndexCount);
  this.offsetsOffset = indexedPartSize + fieldsSerializedSize - columnsIndexCount * TypeSizes.sizeof(0);
}
origin: jsevellec/cassandra-unit

/**
 * Constructor called from {@link Serializer#deserializeForCache(org.apache.cassandra.io.util.DataInputPlus)}.
 */
private IndexedEntry(long dataFilePosition, DataInputPlus in, IndexInfo.Serializer idxInfoSerializer, Version version) throws IOException
{
  super(dataFilePosition);
  this.headerLength = in.readUnsignedVInt();
  this.deletionTime = DeletionTime.serializer.deserialize(in);
  int columnsIndexCount = (int) in.readUnsignedVInt();
  TrackedDataInputPlus trackedIn = new TrackedDataInputPlus(in);
  this.columnsIndex = new IndexInfo[columnsIndexCount];
  for (int i = 0; i < columnsIndexCount; i++)
    this.columnsIndex[i] = idxInfoSerializer.deserialize(trackedIn);
  this.offsets = null;
  this.indexedPartSize = (int) trackedIn.getBytesRead();
  this.idxInfoSerializer = idxInfoSerializer;
}
origin: org.apache.cassandra/cassandra-all

public static SSTableIdentityIterator create(SSTableReader sstable, RandomAccessReader file, DecoratedKey key)
{
  try
  {
    DeletionTime partitionLevelDeletion = DeletionTime.serializer.deserialize(file);
    SerializationHelper helper = new SerializationHelper(sstable.metadata, sstable.descriptor.version.correspondingMessagingVersion(), SerializationHelper.Flag.LOCAL);
    SSTableSimpleIterator iterator = SSTableSimpleIterator.create(sstable.metadata, file, sstable.header, helper, partitionLevelDeletion);
    return new SSTableIdentityIterator(sstable, key, partitionLevelDeletion, file.getPath(), iterator);
  }
  catch (IOException e)
  {
    sstable.markSuspect();
    throw new CorruptSSTableException(e, file.getPath());
  }
}
origin: com.netflix.sstableadaptor/sstable-adaptor-cassandra

public static SSTableIdentityIterator create(SSTableReader sstable, RandomAccessReader file, DecoratedKey key)
{
  try
  {
    DeletionTime partitionLevelDeletion = DeletionTime.serializer.deserialize(file);
    SerializationHelper helper = new SerializationHelper(sstable.metadata, sstable.descriptor.version.correspondingMessagingVersion(), SerializationHelper.Flag.LOCAL);
    SSTableSimpleIterator iterator = SSTableSimpleIterator.create(sstable.metadata, file, sstable.header, helper, partitionLevelDeletion);
    return new SSTableIdentityIterator(sstable, key, partitionLevelDeletion, file.getPath(), iterator);
  }
  catch (IOException e)
  {
    sstable.markSuspect();
    throw new CorruptSSTableException(e, file.getPath());
  }
}
origin: com.facebook.presto.cassandra/cassandra-server

private static DeletionTime readDeletionTime(DataInput in, SSTableReader sstable, String filename)
{
  try
  {
    return DeletionTime.serializer.deserialize(in);
  }
  catch (IOException e)
  {
    if (sstable != null)
      sstable.markSuspect();
    throw new CorruptSSTableException(e, filename);
  }
}
origin: com.strapdata.cassandra/cassandra-all

public StreamDeserializer newPartition() throws IOException
{
  key = metadata.decorateKey(ByteBufferUtil.readWithShortLength(in));
  partitionLevelDeletion = DeletionTime.serializer.deserialize(in);
  iterator = SSTableSimpleIterator.create(metadata, in, header, helper, partitionLevelDeletion);
  staticRow = iterator.readStaticRow();
  return this;
}
origin: com.netflix.sstableadaptor/sstable-adaptor-cassandra

public static LegacyRangeTombstone readLegacyRangeTombstoneBody(CFMetaData metadata, DataInputPlus in, ByteBuffer boundname) throws IOException
{
  LegacyBound min = decodeBound(metadata, boundname, true);
  LegacyBound max = decodeBound(metadata, ByteBufferUtil.readWithShortLength(in), false);
  DeletionTime dt = DeletionTime.serializer.deserialize(in);
  return new LegacyRangeTombstone(min, max, dt);
}
origin: jsevellec/cassandra-unit

public static LegacyRangeTombstone readLegacyRangeTombstoneBody(CFMetaData metadata, DataInputPlus in, ByteBuffer boundname) throws IOException
{
  LegacyBound min = decodeBound(metadata, boundname, true);
  LegacyBound max = decodeBound(metadata, ByteBufferUtil.readWithShortLength(in), false);
  DeletionTime dt = DeletionTime.serializer.deserialize(in);
  return new LegacyRangeTombstone(min, max, dt);
}
origin: com.facebook.presto.cassandra/cassandra-server

public DeletionInfo deserialize(DataInput in, int version) throws IOException
{
  DeletionTime topLevel = DeletionTime.serializer.deserialize(in);
  RangeTombstoneList ranges = rtlSerializer.deserialize(in, version);
  return new DeletionInfo(topLevel, ranges);
}
origin: org.apache.cassandra/cassandra-all

public StreamDeserializer newPartition() throws IOException
{
  key = metadata.decorateKey(ByteBufferUtil.readWithShortLength(in));
  partitionLevelDeletion = DeletionTime.serializer.deserialize(in);
  iterator = SSTableSimpleIterator.create(metadata, in, header, helper, partitionLevelDeletion);
  staticRow = iterator.readStaticRow();
  return this;
}
origin: jsevellec/cassandra-unit

public StreamDeserializer newPartition() throws IOException
{
  key = metadata.decorateKey(ByteBufferUtil.readWithShortLength(in));
  partitionLevelDeletion = DeletionTime.serializer.deserialize(in);
  iterator = SSTableSimpleIterator.create(metadata, in, header, helper, partitionLevelDeletion);
  staticRow = iterator.readStaticRow();
  return this;
}
origin: com.strapdata.cassandra/cassandra-all

public static LegacyRangeTombstone readLegacyRangeTombstoneBody(CFMetaData metadata, DataInputPlus in, ByteBuffer boundname) throws IOException
{
  LegacyBound min = decodeBound(metadata, boundname, true);
  LegacyBound max = decodeBound(metadata, ByteBufferUtil.readWithShortLength(in), false);
  DeletionTime dt = DeletionTime.serializer.deserialize(in);
  return new LegacyRangeTombstone(min, max, dt);
}
origin: org.apache.cassandra/cassandra-all

public static LegacyRangeTombstone readLegacyRangeTombstoneBody(CFMetaData metadata, DataInputPlus in, ByteBuffer boundname) throws IOException
{
  LegacyBound min = decodeBound(metadata, boundname, true);
  LegacyBound max = decodeBound(metadata, ByteBufferUtil.readWithShortLength(in), false);
  DeletionTime dt = DeletionTime.serializer.deserialize(in);
  return new LegacyRangeTombstone(min, max, dt);
}
org.apache.cassandra.dbDeletionTime$Serializerdeserialize

Popular methods of DeletionTime$Serializer

  • serialize
  • serializedSize
  • skip

Popular in Java

  • Parsing JSON documents to java classes using gson
  • requestLocationUpdates (LocationManager)
  • onRequestPermissionsResult (Fragment)
  • getExternalFilesDir (Context)
  • URLEncoder (java.net)
    This class is used to encode a string using the format required by application/x-www-form-urlencoded
  • Timer (java.util)
    Timers schedule one-shot or recurring TimerTask for execution. Prefer java.util.concurrent.Scheduled
  • ExecutorService (java.util.concurrent)
    An Executor that provides methods to manage termination and methods that can produce a Future for tr
  • Notification (javax.management)
  • DataSource (javax.sql)
    An interface for the creation of Connection objects which represent a connection to a database. This
  • Response (javax.ws.rs.core)
    Defines the contract between a returned instance and the runtime when an application needs to provid
  • Top Vim plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now