Usages of

org.onosproject.net.host.HostService.stopMonitoringIp(?)
@Reference(cardinality = ReferenceCardinality.MANDATORY_UNARY) protected HostService hostService; // code omitted ... private void stopMonitoringIps(DhcpServerInfo serverInfo) { serverInfo.getDhcpGatewayIp4().ifPresent(gatewayIp -> { hostService.stopMonitoringIp(gatewayIp); }); serverInfo.getDhcpServerIp4().ifPresent(serverIp -> { hostService.stopMonitoringIp(serverIp); }); }
@Reference(cardinality = ReferenceCardinality.MANDATORY_UNARY) protected HostService hostService; // code omitted ... private void stopMonitoringIps(DhcpServerInfo serverInfo) { serverInfo.getDhcpGatewayIp6().ifPresent(gatewayIp -> { hostService.stopMonitoringIp(gatewayIp); }); serverInfo.getDhcpServerIp6().ifPresent(serverIp -> { hostService.stopMonitoringIp(serverIp); }); }
@Reference(cardinality = ReferenceCardinality.MANDATORY_UNARY) protected HostService hostService; // code omitted ... @Deactivate protected void deactivate() { cfgService.removeListener(cfgListener); factories.forEach(cfgService::unregisterConfigFactory); packetService.removeProcessor(dhcpRelayPacketProcessor); hostService.removeListener(hostListener); cancelDhcpPackets(); cancelArpPackets(); if (dhcpGatewayIp != null) { hostService.stopMonitoringIp(dhcpGatewayIp); } else { hostService.stopMonitoringIp(dhcpServerIp); } log.info("DHCP-RELAY Stopped"); }
@Reference(cardinality = ReferenceCardinality.MANDATORY_UNARY) protected HostService hostService; // code omitted ... @Deactivate protected void deactivate() { log.info("Stopping"); // Cancel any running timers deletedHostTimeout.cancel(); // Remove listeners cfgService.removeListener(cfgListener); hostService.removeListener(hostListener); deviceService.removeListener(deviceListener); factories.forEach(cfgService::unregisterConfigFactory); // Stop monitoring any default gateways defaultGateways.keySet().forEach(ip -> hostService.stopMonitoringIp(ip)); // Drop all flows on all APs accessPoints.values().forEach(ap -> ap.onShutdown()); log.info("Stopped"); }
@Reference(cardinality = ReferenceCardinality.MANDATORY_UNARY) protected HostService hostService; // code omitted ... @Deactivate protected void deactivate() { cfgService.removeListener(cfgListener); factories.forEach(cfgService::unregisterConfigFactory); packetService.removeProcessor(dhcpRelayPacketProcessor); hostService.removeListener(hostListener); cancelDhcpPackets(); cancelArpPackets(); if (dhcpGatewayIp != null) { hostService.stopMonitoringIp(dhcpGatewayIp); } else { hostService.stopMonitoringIp(dhcpServerIp); } compCfgService.unregisterProperties(getClass(), true); log.info("DHCP-RELAY Stopped"); }
Usage snippet has been bookmarked! Review your bookmarks
Thank you! Review your likes