当前位置: 首页>>代码示例>>Java>>正文


Java CompactEndpointSerializationHelper.deserialize方法代码示例

本文整理汇总了Java中org.apache.cassandra.net.CompactEndpointSerializationHelper.deserialize方法的典型用法代码示例。如果您正苦于以下问题:Java CompactEndpointSerializationHelper.deserialize方法的具体用法?Java CompactEndpointSerializationHelper.deserialize怎么用?Java CompactEndpointSerializationHelper.deserialize使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.apache.cassandra.net.CompactEndpointSerializationHelper的用法示例。


在下文中一共展示了CompactEndpointSerializationHelper.deserialize方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: deserialize

import org.apache.cassandra.net.CompactEndpointSerializationHelper; //导入方法依赖的package包/类
public GossipDigestAck deserialize(DataInput dis, int version) throws IOException
{
    List<GossipDigest> gDigestList = GossipDigestSerializationHelper.deserialize(dis, version);
    if (version < MessagingService.VERSION_12)
        dis.readBoolean(); // 0.6 compatibility
    int size = dis.readInt();
    Map<InetAddress, EndpointState> epStateMap = new HashMap<InetAddress, EndpointState>(size);

    for (int i = 0; i < size; ++i)
    {
        InetAddress ep = CompactEndpointSerializationHelper.deserialize(dis);
        EndpointState epState = EndpointState.serializer.deserialize(dis, version);
        epStateMap.put(ep, epState);
    }
    return new GossipDigestAck(gDigestList, epStateMap);
}
 
开发者ID:dprguiuc,项目名称:Cassandra-Wasef,代码行数:17,代码来源:GossipDigestAck.java

示例2: deserialize

import org.apache.cassandra.net.CompactEndpointSerializationHelper; //导入方法依赖的package包/类
public GossipDigest deserialize(DataInput in, int version) throws IOException
{
    InetAddress endpoint = CompactEndpointSerializationHelper.deserialize(in);
    int generation = in.readInt();
    int maxVersion = in.readInt();
    return new GossipDigest(endpoint, generation, maxVersion);
}
 
开发者ID:vcostet,项目名称:cassandra-kmean,代码行数:8,代码来源:GossipDigest.java

示例3: deserialize

import org.apache.cassandra.net.CompactEndpointSerializationHelper; //导入方法依赖的package包/类
public GossipDigestAck2 deserialize(DataInput in, int version) throws IOException
{
    int size = in.readInt();
    Map<InetAddress, EndpointState> epStateMap = new HashMap<InetAddress, EndpointState>(size);

    for (int i = 0; i < size; ++i)
    {
        InetAddress ep = CompactEndpointSerializationHelper.deserialize(in);
        EndpointState epState = EndpointState.serializer.deserialize(in, version);
        epStateMap.put(ep, epState);
    }
    return new GossipDigestAck2(epStateMap);
}
 
开发者ID:vcostet,项目名称:cassandra-kmean,代码行数:14,代码来源:GossipDigestAck2.java

示例4: deserialize

import org.apache.cassandra.net.CompactEndpointSerializationHelper; //导入方法依赖的package包/类
public GossipDigestAck deserialize(DataInput in, int version) throws IOException
{
    List<GossipDigest> gDigestList = GossipDigestSerializationHelper.deserialize(in, version);
    int size = in.readInt();
    Map<InetAddress, EndpointState> epStateMap = new HashMap<InetAddress, EndpointState>(size);

    for (int i = 0; i < size; ++i)
    {
        InetAddress ep = CompactEndpointSerializationHelper.deserialize(in);
        EndpointState epState = EndpointState.serializer.deserialize(in, version);
        epStateMap.put(ep, epState);
    }
    return new GossipDigestAck(gDigestList, epStateMap);
}
 
开发者ID:vcostet,项目名称:cassandra-kmean,代码行数:15,代码来源:GossipDigestAck.java

示例5: deserialize

import org.apache.cassandra.net.CompactEndpointSerializationHelper; //导入方法依赖的package包/类
public SyncRequest deserialize(DataInput in, int version) throws IOException
{
    RepairJobDesc desc = RepairJobDesc.serializer.deserialize(in, version);
    InetAddress owner = CompactEndpointSerializationHelper.deserialize(in);
    InetAddress src = CompactEndpointSerializationHelper.deserialize(in);
    InetAddress dst = CompactEndpointSerializationHelper.deserialize(in);
    int rangesCount = in.readInt();
    List<Range<Token>> ranges = new ArrayList<>(rangesCount);
    for (int i = 0; i < rangesCount; ++i)
        ranges.add((Range<Token>) AbstractBounds.serializer.deserialize(in, version).toTokenBounds());
    return new SyncRequest(desc, owner, src, dst, ranges);
}
 
开发者ID:vcostet,项目名称:cassandra-kmean,代码行数:13,代码来源:SyncRequest.java

示例6: deserialize

import org.apache.cassandra.net.CompactEndpointSerializationHelper; //导入方法依赖的package包/类
public StreamInitMessage deserialize(DataInput in, int version) throws IOException
{
    InetAddress from = CompactEndpointSerializationHelper.deserialize(in);
    int sessionIndex = in.readInt();
    UUID planId = UUIDSerializer.serializer.deserialize(in, MessagingService.current_version);
    String description = in.readUTF();
    boolean sentByInitiator = in.readBoolean();
    return new StreamInitMessage(from, sessionIndex, planId, description, sentByInitiator);
}
 
开发者ID:vcostet,项目名称:cassandra-kmean,代码行数:10,代码来源:StreamInitMessage.java

示例7: deserialize

import org.apache.cassandra.net.CompactEndpointSerializationHelper; //导入方法依赖的package包/类
public StreamInitMessage deserialize(DataInput in, int version) throws IOException
{
    InetAddress from = CompactEndpointSerializationHelper.deserialize(in);
    UUID planId = UUIDSerializer.serializer.deserialize(in, MessagingService.current_version);
    String description = in.readUTF();
    boolean sentByInitiator = in.readBoolean();
    return new StreamInitMessage(from, planId, description, sentByInitiator);
}
 
开发者ID:pgaref,项目名称:ACaZoo,代码行数:9,代码来源:StreamInitMessage.java

示例8: deserialize

import org.apache.cassandra.net.CompactEndpointSerializationHelper; //导入方法依赖的package包/类
public GossipDigest deserialize(DataInputPlus in, int version) throws IOException
{
    InetAddress endpoint = CompactEndpointSerializationHelper.deserialize(in);
    int generation = in.readInt();
    int maxVersion = in.readInt();
    return new GossipDigest(endpoint, generation, maxVersion);
}
 
开发者ID:scylladb,项目名称:scylla-tools-java,代码行数:8,代码来源:GossipDigest.java

示例9: deserialize

import org.apache.cassandra.net.CompactEndpointSerializationHelper; //导入方法依赖的package包/类
public GossipDigestAck2 deserialize(DataInputPlus in, int version) throws IOException
{
    int size = in.readInt();
    Map<InetAddress, EndpointState> epStateMap = new HashMap<InetAddress, EndpointState>(size);

    for (int i = 0; i < size; ++i)
    {
        InetAddress ep = CompactEndpointSerializationHelper.deserialize(in);
        EndpointState epState = EndpointState.serializer.deserialize(in, version);
        epStateMap.put(ep, epState);
    }
    return new GossipDigestAck2(epStateMap);
}
 
开发者ID:scylladb,项目名称:scylla-tools-java,代码行数:14,代码来源:GossipDigestAck2.java

示例10: deserialize

import org.apache.cassandra.net.CompactEndpointSerializationHelper; //导入方法依赖的package包/类
public GossipDigestAck deserialize(DataInputPlus in, int version) throws IOException
{
    List<GossipDigest> gDigestList = GossipDigestSerializationHelper.deserialize(in, version);
    int size = in.readInt();
    Map<InetAddress, EndpointState> epStateMap = new HashMap<InetAddress, EndpointState>(size);

    for (int i = 0; i < size; ++i)
    {
        InetAddress ep = CompactEndpointSerializationHelper.deserialize(in);
        EndpointState epState = EndpointState.serializer.deserialize(in, version);
        epStateMap.put(ep, epState);
    }
    return new GossipDigestAck(gDigestList, epStateMap);
}
 
开发者ID:scylladb,项目名称:scylla-tools-java,代码行数:15,代码来源:GossipDigestAck.java

示例11: deserialize

import org.apache.cassandra.net.CompactEndpointSerializationHelper; //导入方法依赖的package包/类
public SyncRequest deserialize(DataInputPlus in, int version) throws IOException
{
    RepairJobDesc desc = RepairJobDesc.serializer.deserialize(in, version);
    InetAddress owner = CompactEndpointSerializationHelper.deserialize(in);
    InetAddress src = CompactEndpointSerializationHelper.deserialize(in);
    InetAddress dst = CompactEndpointSerializationHelper.deserialize(in);
    int rangesCount = in.readInt();
    List<Range<Token>> ranges = new ArrayList<>(rangesCount);
    for (int i = 0; i < rangesCount; ++i)
        ranges.add((Range<Token>) AbstractBounds.tokenSerializer.deserialize(in, MessagingService.globalPartitioner(), version));
    return new SyncRequest(desc, owner, src, dst, ranges);
}
 
开发者ID:scylladb,项目名称:scylla-tools-java,代码行数:13,代码来源:SyncRequest.java

示例12: deserialize

import org.apache.cassandra.net.CompactEndpointSerializationHelper; //导入方法依赖的package包/类
public StreamInitMessage deserialize(DataInputPlus in, int version) throws IOException
{
    InetAddress from = CompactEndpointSerializationHelper.deserialize(in);
    int sessionIndex = in.readInt();
    UUID planId = UUIDSerializer.serializer.deserialize(in, MessagingService.current_version);
    String description = in.readUTF();
    boolean sentByInitiator = in.readBoolean();
    boolean keepSSTableLevel = in.readBoolean();
    boolean isIncremental = in.readBoolean();
    return new StreamInitMessage(from, sessionIndex, planId, description, sentByInitiator, keepSSTableLevel, isIncremental);
}
 
开发者ID:scylladb,项目名称:scylla-tools-java,代码行数:12,代码来源:StreamInitMessage.java

示例13: deserialize

import org.apache.cassandra.net.CompactEndpointSerializationHelper; //导入方法依赖的package包/类
public GossipDigestAck2 deserialize(DataInput dis, int version) throws IOException
{
    int size = dis.readInt();
    Map<InetAddress, EndpointState> epStateMap = new HashMap<InetAddress, EndpointState>(size);

    for (int i = 0; i < size; ++i)
    {
        InetAddress ep = CompactEndpointSerializationHelper.deserialize(dis);
        EndpointState epState = EndpointState.serializer.deserialize(dis, version);
        epStateMap.put(ep, epState);
    }
    return new GossipDigestAck2(epStateMap);
}
 
开发者ID:wso2,项目名称:wso2-cassandra,代码行数:14,代码来源:GossipDigestAck2.java

示例14: deserialize

import org.apache.cassandra.net.CompactEndpointSerializationHelper; //导入方法依赖的package包/类
public StreamingRepairTask deserialize(DataInput dis, int version) throws IOException
{
    UUID id = UUIDSerializer.serializer.deserialize(dis, version);
    InetAddress owner = CompactEndpointSerializationHelper.deserialize(dis);
    InetAddress src = CompactEndpointSerializationHelper.deserialize(dis);
    InetAddress dst = CompactEndpointSerializationHelper.deserialize(dis);
    String tableName = dis.readUTF();
    String cfName = dis.readUTF();
    int rangesCount = dis.readInt();
    List<Range<Token>> ranges = new ArrayList<Range<Token>>(rangesCount);
    for (int i = 0; i < rangesCount; ++i)
        ranges.add((Range<Token>) AbstractBounds.serializer.deserialize(dis, version).toTokenBounds());
    return new StreamingRepairTask(id, owner, src, dst, tableName, cfName, ranges, makeReplyingCallback(owner, id));
}
 
开发者ID:wso2,项目名称:wso2-cassandra,代码行数:15,代码来源:StreamingRepairTask.java

示例15: deserialize

import org.apache.cassandra.net.CompactEndpointSerializationHelper; //导入方法依赖的package包/类
public StreamRequest deserialize(DataInput dis, int version) throws IOException
{
    UUID sessionId = UUIDSerializer.serializer.deserialize(dis, MessagingService.current_version);
    InetAddress target = CompactEndpointSerializationHelper.deserialize(dis);
    boolean singleFile = dis.readBoolean();
    if (singleFile)
    {
        PendingFile file = PendingFile.serializer.deserialize(dis, version);
        return new StreamRequest(target, file, sessionId);
    }
    else
    {
        String table = dis.readUTF();
        int size = dis.readInt();
        List<Range<Token>> ranges = (size == 0) ? null : new ArrayList<Range<Token>>(size);
        for (int i = 0; i < size; ++i)
            ranges.add((Range<Token>) AbstractBounds.serializer.deserialize(dis, version).toTokenBounds());
        OperationType type = OperationType.valueOf(dis.readUTF());

        List<ColumnFamilyStore> stores = new ArrayList<ColumnFamilyStore>();
        int cfsSize = dis.readInt();
        for (int i = 0; i < cfsSize; ++i)
            stores.add(Table.open(table).getColumnFamilyStore(ColumnFamily.serializer.deserializeCfId(dis, version)));

        return new StreamRequest(target, ranges, table, stores, sessionId, type);
    }
}
 
开发者ID:jackliu8722,项目名称:cassandra-1.2.16,代码行数:28,代码来源:StreamRequest.java


注:本文中的org.apache.cassandra.net.CompactEndpointSerializationHelper.deserialize方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。