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


Java IRoutingService类代码示例

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


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

示例1: init

import net.floodlightcontroller.routing.IRoutingService; //导入依赖的package包/类
@Override
public void init(FloodlightModuleContext context) throws FloodlightModuleException 
{
	
	floodlightProvider = context.getServiceImpl(IFloodlightProviderService.class);
	
       deviceService = context.getServiceImpl(IDeviceService.class);
       routingService = context.getServiceImpl(IRoutingService.class);
       switchService = context.getServiceImpl(IOFSwitchService.class);
	linkService = context.getServiceImpl(ILinkDiscoveryService.class);
	
       messageDamper =  new OFMessageDamper(OFMESSAGE_DAMPER_CAPACITY,
			EnumSet.of(OFType.FLOW_MOD),
			OFMESSAGE_DAMPER_TIMEOUT);
       
	library = new FP_LibFloodlight( LoggerFactory.getLogger( getClass() ));
	
}
 
开发者ID:xuraylei,项目名称:fresco_floodlight,代码行数:19,代码来源:FP_FloodlightRTE.java

示例2: getModuleDependencies

import net.floodlightcontroller.routing.IRoutingService; //导入依赖的package包/类
@Override
public Collection<Class<? extends IFloodlightService>>
        getModuleDependencies() {
    Collection<Class<? extends IFloodlightService>> l = 
            new ArrayList<Class<? extends IFloodlightService>>();
    l.add(IFloodlightProviderService.class);
    l.add(IRestApiService.class);
    l.add(IOFSwitchService.class);
    l.add(IDeviceService.class);
    l.add(IDebugCounterService.class);
    l.add(ITopologyService.class);
    l.add(IRoutingService.class);
    l.add(IStaticFlowEntryPusherService.class);

    return l;
}
 
开发者ID:xuraylei,项目名称:fresco_floodlight,代码行数:17,代码来源:LoadBalancer.java

示例3: init

import net.floodlightcontroller.routing.IRoutingService; //导入依赖的package包/类
@Override
public void init(FloodlightModuleContext context)
                                             throws FloodlightModuleException {
    floodlightProviderService = context.getServiceImpl(IFloodlightProviderService.class);
    restApiService = context.getServiceImpl(IRestApiService.class);
    debugCounterService = context.getServiceImpl(IDebugCounterService.class);
    deviceManagerService = context.getServiceImpl(IDeviceService.class);
    routingEngineService = context.getServiceImpl(IRoutingService.class);
    topologyService = context.getServiceImpl(ITopologyService.class);
    sfpService = context.getServiceImpl(IStaticFlowEntryPusherService.class);
    switchService = context.getServiceImpl(IOFSwitchService.class);
    
    vips = new HashMap<String, LBVip>();
    pools = new HashMap<String, LBPool>();
    members = new HashMap<String, LBMember>();
    vipIpToId = new HashMap<Integer, String>();
    vipIpToMac = new HashMap<Integer, MacAddress>();
    memberIpToId = new HashMap<Integer, String>();
}
 
开发者ID:xuraylei,项目名称:fresco_floodlight,代码行数:20,代码来源:LoadBalancer.java

示例4: init

import net.floodlightcontroller.routing.IRoutingService; //导入依赖的package包/类
@Override
public void init(FloodlightModuleContext context)
		throws FloodlightModuleException {
	floodlightProvider = context.getServiceImpl(IFloodlightProviderService.class);
    logger = LoggerFactory.getLogger(MulticastController.class);
	lds = context.getServiceImpl(ILinkDiscoveryService.class);
	routingService = context.getServiceImpl(IRoutingService.class);
	flowPusher = context.getServiceImpl(IStaticFlowEntryPusherService.class);
	switchService = context.getServiceImpl(IOFSwitchService.class);
	statisticsService = context.getServiceImpl(IStatisticsService.class);
	groupDB = new MulticastGroupStore(this);
	Map<String, String> configOptions = context.getConfigParams(this);
	String topologyFile = configOptions.get("topologyFile");
	String ipBandwidthQoSFile = configOptions.get("ipBandwidthQoSFile");
	if (topologyFile != null) {
		topologyHelper = new TopologyHelper(topologyFile);
	} else {
		logger.error("topologyFile not provided");
	}
	
	logger.info(" QOS file : " + ipBandwidthQoSFile);
	flowQoSDemandHelper = new FlowQoSDemandHelper(ipBandwidthQoSFile);
	if (statisticsService.getBandwidthConsumption() == null)
		statisticsService.collectStatistics(false);
}
 
开发者ID:hksoni,项目名称:SDN-Multicast,代码行数:26,代码来源:MulticastController.java

示例5: init

import net.floodlightcontroller.routing.IRoutingService; //导入依赖的package包/类
@Override
@LogMessageDocs({
    @LogMessageDoc(level="WARN",
            message="Error parsing flow idle timeout, " +
                    "using default of {number} seconds",
            explanation="The properties file contains an invalid " +
                    "flow idle timeout",
            recommendation="Correct the idle timeout in the " +
                    "properties file."),
    @LogMessageDoc(level="WARN",
            message="Error parsing flow hard timeout, " +
                    "using default of {number} seconds",
            explanation="The properties file contains an invalid " +
                        "flow hard timeout",
            recommendation="Correct the hard timeout in the " +
                            "properties file.")
})
public void init(FloodlightModuleContext context) throws FloodlightModuleException {
    super.init();
    this.floodlightProvider = context.getServiceImpl(IFloodlightProviderService.class);
    this.deviceManager = context.getServiceImpl(IDeviceService.class);
    this.routingEngine = context.getServiceImpl(IRoutingService.class);
    this.topology = context.getServiceImpl(ITopologyService.class);
    this.counterStore = context.getServiceImpl(ICounterStoreService.class);
}
 
开发者ID:JianqingJiang,项目名称:QoS-floodlight,代码行数:26,代码来源:Forwarding.java

示例6: init

import net.floodlightcontroller.routing.IRoutingService; //导入依赖的package包/类
@Override
public void init(FloodlightModuleContext context)
                                             throws FloodlightModuleException {
    floodlightProvider = context.getServiceImpl(IFloodlightProviderService.class);
    restApi = context.getServiceImpl(IRestApiService.class);
    counterStore = context.getServiceImpl(ICounterStoreService.class);
    deviceManager = context.getServiceImpl(IDeviceService.class);
    routingEngine = context.getServiceImpl(IRoutingService.class);
    topology = context.getServiceImpl(ITopologyService.class);
    sfp = context.getServiceImpl(IStaticFlowEntryPusherService.class);
    
    messageDamper = new OFMessageDamper(OFMESSAGE_DAMPER_CAPACITY, 
                                        EnumSet.of(OFType.FLOW_MOD),
                                        OFMESSAGE_DAMPER_TIMEOUT);
    
    vips = new HashMap<String, LBVip>();
    pools = new HashMap<String, LBPool>();
    members = new HashMap<String, LBMember>();
    vipIpToId = new HashMap<Integer, String>();
    vipIpToMac = new HashMap<Integer, MACAddress>();
    memberIpToId = new HashMap<Integer, String>();
}
 
开发者ID:JianqingJiang,项目名称:QoS-floodlight,代码行数:23,代码来源:LoadBalancer.java

示例7: getModuleDependencies

import net.floodlightcontroller.routing.IRoutingService; //导入依赖的package包/类
@Override
public Collection<Class<? extends IFloodlightService>>
        getModuleDependencies() {
    Collection<Class<? extends IFloodlightService>> l =
            new ArrayList<Class<? extends IFloodlightService>>();
    l.add(IFloodlightProviderService.class);
    l.add(IRestApiService.class);
    l.add(IOFSwitchService.class);
    l.add(IDeviceService.class);
    l.add(IDebugCounterService.class);
    l.add(ITopologyService.class);
    l.add(IRoutingService.class);
    l.add(IStaticFlowEntryPusherService.class);

    return l;
}
 
开发者ID:zhenshengcai,项目名称:floodlight-hardware,代码行数:17,代码来源:LoadBalancer.java

示例8: init

import net.floodlightcontroller.routing.IRoutingService; //导入依赖的package包/类
@Override
public void init(FloodlightModuleContext context)
                                             throws FloodlightModuleException {
    floodlightProviderService = context.getServiceImpl(IFloodlightProviderService.class);
    restApiService = context.getServiceImpl(IRestApiService.class);
    debugCounterService = context.getServiceImpl(IDebugCounterService.class);
    deviceManagerService = context.getServiceImpl(IDeviceService.class);
    routingEngineService = context.getServiceImpl(IRoutingService.class);
    topologyService = context.getServiceImpl(ITopologyService.class);
    sfpService = context.getServiceImpl(IStaticFlowEntryPusherService.class);
    switchService = context.getServiceImpl(IOFSwitchService.class);

    vips = new HashMap<String, LBVip>();
    pools = new HashMap<String, LBPool>();
    members = new HashMap<String, LBMember>();
    vipIpToId = new HashMap<Integer, String>();
    vipIpToMac = new HashMap<Integer, MacAddress>();
    memberIpToId = new HashMap<Integer, String>();
}
 
开发者ID:zhenshengcai,项目名称:floodlight-hardware,代码行数:20,代码来源:LoadBalancer.java

示例9: getModuleDependencies

import net.floodlightcontroller.routing.IRoutingService; //导入依赖的package包/类
@Override
public Collection<Class<? extends IFloodlightService>> getModuleDependencies() {
	Collection<Class<? extends IFloodlightService>> l = new ArrayList<Class<? extends IFloodlightService>>();
	l.add(IFloodlightProviderService.class);
	l.add(IRestApiService.class);
	l.add(IRoutingService.class);
	return l;
}
 
开发者ID:hexec,项目名称:floodlight-simple-multicast,代码行数:9,代码来源:Multicast.java

示例10: init

import net.floodlightcontroller.routing.IRoutingService; //导入依赖的package包/类
@Override
public void init(FloodlightModuleContext context) throws FloodlightModuleException {
	floodlightProvider = context.getServiceImpl(IFloodlightProviderService.class);
	restApiService = context.getServiceImpl(IRestApiService.class);
	routingService = context.getServiceImpl(IRoutingService.class);
	// create an empty db
	groupDb = new MulticastDb();
	log.info("Startup MULTICAST module");
}
 
开发者ID:hexec,项目名称:floodlight-simple-multicast,代码行数:10,代码来源:Multicast.java

示例11: getModuleDependencies

import net.floodlightcontroller.routing.IRoutingService; //导入依赖的package包/类
@Override
public Collection<Class<? extends IFloodlightService>> getModuleDependencies() {
	Collection<Class<? extends IFloodlightService>> l =
			new ArrayList<Class<? extends IFloodlightService>>();
	l.add(IFloodlightProviderService.class);
	l.add(IDeviceService.class);
	l.add(IRoutingService.class);
	l.add(ITopologyService.class);
	l.add(IDebugCounterService.class);
	return l;
}
 
开发者ID:xuraylei,项目名称:fresco_floodlight,代码行数:12,代码来源:Forwarding.java

示例12: retrieve

import net.floodlightcontroller.routing.IRoutingService; //导入依赖的package包/类
@Get("json")
public List<NodePortTuple> retrieve() {
    IRoutingService routing = 
            (IRoutingService)getContext().getAttributes().
                get(IRoutingService.class.getCanonicalName());
    
    String srcDpid = (String) getRequestAttributes().get("src-dpid");
    String srcPort = (String) getRequestAttributes().get("src-port");
    String dstDpid = (String) getRequestAttributes().get("dst-dpid");
    String dstPort = (String) getRequestAttributes().get("dst-port");

    log.debug( srcDpid + "--" + srcPort + "--" + dstDpid + "--" + dstPort);

    DatapathId longSrcDpid = DatapathId.of(srcDpid);
    OFPort shortSrcPort = OFPort.of(Integer.parseInt(srcPort));
    DatapathId longDstDpid = DatapathId.of(dstDpid);
    OFPort shortDstPort = OFPort.of(Integer.parseInt(dstPort));
    
    Route result = routing.getRoute(longSrcDpid, shortSrcPort, longDstDpid, shortDstPort, U64.of(0));
    
    if (result != null) {
        return routing.getRoute(longSrcDpid, shortSrcPort, longDstDpid, shortDstPort, U64.of(0)).getPath();
    }
    else {
        log.debug("ERROR! no route found");
        return null;
    }
}
 
开发者ID:xuraylei,项目名称:fresco_floodlight,代码行数:29,代码来源:RouteResource.java

示例13: getModuleServices

import net.floodlightcontroller.routing.IRoutingService; //导入依赖的package包/类
@Override
public Collection<Class<? extends IFloodlightService>> getModuleServices() {
	Collection<Class<? extends IFloodlightService>> l =
			new ArrayList<Class<? extends IFloodlightService>>();
	l.add(ITopologyService.class);
	l.add(IRoutingService.class);
	return l;
}
 
开发者ID:xuraylei,项目名称:fresco_floodlight,代码行数:9,代码来源:TopologyManager.java


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