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


Java OFAsyncGetReply类代码示例

本文整理汇总了Java中org.projectfloodlight.openflow.protocol.OFAsyncGetReply的典型用法代码示例。如果您正苦于以下问题:Java OFAsyncGetReply类的具体用法?Java OFAsyncGetReply怎么用?Java OFAsyncGetReply使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


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

示例1: decodeAsyncGetReply

import org.projectfloodlight.openflow.protocol.OFAsyncGetReply; //导入依赖的package包/类
@SuppressWarnings("unused")
private void decodeAsyncGetReply(OFAsyncGetReply rep) {
    long frm = rep.getFlowRemovedMaskEqualMaster();
    long frs = rep.getFlowRemovedMaskSlave();
    long pim = rep.getPacketInMaskEqualMaster();
    long pis = rep.getPacketInMaskSlave();
    long psm = rep.getPortStatusMaskEqualMaster();
    long pss = rep.getPortStatusMaskSlave();

    if (role == Role.MASTER || role == Role.EQUAL) { // should separate
        log.info("FRM:{}", HexString.toHexString((frm & TEST_FLOW_REMOVED_MASK)));
        log.info("PIM:{}", HexString.toHexString((pim & TEST_PACKET_IN_MASK)));
        log.info("PSM:{}", HexString.toHexString((psm & TEST_PORT_STATUS_MASK)));
    }

}
 
开发者ID:opennetworkinglab,项目名称:spring-open,代码行数:17,代码来源:OFSwitchImplSpringOpenTTP.java

示例2: decodeAsyncGetReply

import org.projectfloodlight.openflow.protocol.OFAsyncGetReply; //导入依赖的package包/类
private void decodeAsyncGetReply(OFAsyncGetReply rep) {
    long frm = rep.getFlowRemovedMaskEqualMaster();
    //long frs = rep.getFlowRemovedMaskSlave();
    long pim = rep.getPacketInMaskEqualMaster();
    //long pis = rep.getPacketInMaskSlave();
    long psm = rep.getPortStatusMaskEqualMaster();
    //long pss = rep.getPortStatusMaskSlave();

    if (role == RoleState.MASTER || role == RoleState.EQUAL) { // should separate
        log.info("FRM:{}", HexString.toHexString((frm & TEST_FLOW_REMOVED_MASK)));
        log.info("PIM:{}", HexString.toHexString((pim & TEST_PACKET_IN_MASK)));
        log.info("PSM:{}", HexString.toHexString((psm & TEST_PORT_STATUS_MASK)));
    }

}
 
开发者ID:ravikumaran2015,项目名称:ravikumaran201504,代码行数:16,代码来源:OFSwitchImplCPqD13.java

示例3: processOFMessage

import org.projectfloodlight.openflow.protocol.OFAsyncGetReply; //导入依赖的package包/类
void processOFMessage(IOFSwitch sw, OFMessage m) throws IOException {
    switch (m.getType()) {
    case BARRIER_REPLY:
        processBarrierReply(m);
        break;

    case ERROR:
        processErrorMessage(m);
        break;

    case GET_ASYNC_REPLY:
        OFAsyncGetReply asrep = (OFAsyncGetReply) m;
        decodeAsyncGetReply(asrep);
        break;

    case PACKET_IN:
        // not ready to handle packet-ins
        break;

    case QUEUE_GET_CONFIG_REPLY:
        // not doing queue config yet
        break;

    case STATS_REPLY:
        processStatsReply((OFStatsReply) m);
        break;

    case ROLE_REPLY: // channelHandler should handle this
    case PORT_STATUS: // channelHandler should handle this
    case FEATURES_REPLY: // don't care
    case FLOW_REMOVED: // don't care
    default:
        log.debug("Received message {} during switch-driver subhandshake "
                + "from switch {} ... Ignoring message", m, sw.getStringId());
    }
}
 
开发者ID:opennetworkinglab,项目名称:spring-open,代码行数:37,代码来源:OFSwitchImplSpringOpenTTP.java

示例4: processOFGetAsyncReply

import org.projectfloodlight.openflow.protocol.OFAsyncGetReply; //导入依赖的package包/类
void processOFGetAsyncReply(OFChannelHandler h,
        OFAsyncGetReply m) {
    unhandledMessageReceived(h, m);
}
 
开发者ID:shlee89,项目名称:athena,代码行数:5,代码来源:OFChannelHandler.java

示例5: processDriverHandshakeMessage

import org.projectfloodlight.openflow.protocol.OFAsyncGetReply; //导入依赖的package包/类
@Override
public void processDriverHandshakeMessage(OFMessage m) {
    if (!startDriverHandshakeCalled) {
        throw new SwitchDriverSubHandshakeNotStarted();
    }
    if (driverHandshakeComplete.get()) {
        throw new SwitchDriverSubHandshakeCompleted(m);
    }

    switch (m.getType()) {
    case BARRIER_REPLY:
        if (m.getXid() == barrierXidToWaitFor) {
            driverHandshakeComplete.set(true);
        }
        break;

    case ERROR:
        log.error("Switch {} Error {}", getStringId(), m);
        break;

    case GET_ASYNC_REPLY:
        OFAsyncGetReply asrep = (OFAsyncGetReply) m;
        decodeAsyncGetReply(asrep);
        break;
    case STATS_REPLY:
        processStatsReply((OFStatsReply) m);
        break;
    case PACKET_IN:
    case PORT_STATUS:
    case QUEUE_GET_CONFIG_REPLY:
    case ROLE_REPLY:
    case FEATURES_REPLY:
    case FLOW_REMOVED:
        break;

    default:
        log.debug("Received message {} during switch-driver subhandshake "
                + "from switch {} ... Ignoring message", m, getStringId());

    }
}
 
开发者ID:ravikumaran2015,项目名称:ravikumaran201504,代码行数:42,代码来源:OFSwitchImplCPqD13.java


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