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


Java OFDescriptionStatistics.getDatapathDescription方法代码示例

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


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

示例1: SwitchSyncRepresentation

import org.openflow.protocol.statistics.OFDescriptionStatistics; //导入方法依赖的package包/类
public SwitchSyncRepresentation(OFFeaturesReply fr,
                                OFDescriptionStatistics d) {
    this.dpid = fr.getDatapathId();
    this.buffers = fr.getBuffers();
    this.tables = fr.getTables();
    this.capabilities = fr.getCapabilities();
    this.actions = fr.getActions();
    this.ports = toSyncedPortList(
            ImmutablePort.immutablePortListOf(fr.getPorts()));

    this.manufacturerDescription = d.getManufacturerDescription();
    this.hardwareDescription = d.getHardwareDescription();
    this.softwareDescription = d.getSoftwareDescription();
    this.serialNumber = d.getSerialNumber();
    this.datapathDescription = d.getDatapathDescription();
}
 
开发者ID:JianqingJiang,项目名称:QoS-floodlight,代码行数:17,代码来源:SwitchSyncRepresentation.java

示例2: getOFSwitchImpl

import org.openflow.protocol.statistics.OFDescriptionStatistics; //导入方法依赖的package包/类
@Override
public IOFSwitch getOFSwitchImpl(String regis_desc,
                                 OFDescriptionStatistics description) {
    String model = description.getDatapathDescription();
 
    if (regis_desc.startsWith("big switch networks")) {
        // BigTest Mininet, avoid OVS optimization
        if (model.startsWith("bigtest")) {
            return new BetterOFSwitchImpl();
        }
    }
    if (regis_desc.equals("Big Switch Networks")) {
        if (description.getHardwareDescription().startsWith("Open vSwitch")) {
            return new BetterOFSwitchBSNOVS();
        } else if (description.getHardwareDescription().startsWith("Xenon")) {
            return new BetterOFSwitchXenon();
        }
    }
    if (regis_desc.equals("")) {
        String vendor = description.getManufacturerDescription();
        String make = description.getHardwareDescription();
        // Production OVS, optimize topology probing
        if (vendor.startsWith("Nicira") &&
                make.startsWith("Open vSwitch")) {
            return new BetterOFSwitchOVS();
        }
        return new BetterOFSwitchImpl();
    }
    log.warn("Unknown model registered: " + regis_desc);
    return null;
}
 
开发者ID:opendaylight,项目名称:archived-net-virt-platform,代码行数:32,代码来源:BetterDriverManager.java

示例3: descriptionStatisticsRefreshed

import org.openflow.protocol.statistics.OFDescriptionStatistics; //导入方法依赖的package包/类
@Override
public void descriptionStatisticsRefreshed(Long switchId, List<OFStatistics> descriptionStats) {
    Node node = NodeCreator.createOFNode(switchId);
    Set<Property> properties = new HashSet<Property>(1);
    OFDescriptionStatistics ofDesc = (OFDescriptionStatistics) descriptionStats.get(0);
    Description desc = new Description(ofDesc.getDatapathDescription());
    properties.add(desc);

    // Notify all internal and external listeners
    notifyInventoryShimListener(node, UpdateType.CHANGED, properties);
}
 
开发者ID:lbchen,项目名称:ODL,代码行数:12,代码来源:InventoryServiceShim.java


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