@Service public class InterfaceManager extends org.onosproject.event.ListenerRegistry<InterfaceEvent,InterfaceListener> implements InterfaceService, InterfaceAdminService
| Modifier and Type | Field and Description |
|---|---|
protected org.onosproject.net.config.NetworkConfigService |
configService |
| Constructor and Description |
|---|
InterfaceManager() |
| Modifier and Type | Method and Description |
|---|---|
void |
activate() |
void |
add(Interface intf)
Adds a new interface configuration to the system.
|
void |
deactivate() |
Interface |
getInterfaceByName(org.onosproject.net.ConnectPoint connectPoint,
java.lang.String name)
Returns the interface with the given name.
|
java.util.Set<Interface> |
getInterfaces()
Returns the set of all interfaces in the system.
|
java.util.Set<Interface> |
getInterfacesByIp(org.onlab.packet.IpAddress ip)
Returns the set of interfaces with the given IP address.
|
java.util.Set<Interface> |
getInterfacesByPort(org.onosproject.net.ConnectPoint port)
Returns the set of interfaces configured on the given port.
|
java.util.Set<Interface> |
getInterfacesByVlan(org.onlab.packet.VlanId vlan)
Returns the set of interfaces in the given VLAN.
|
Interface |
getMatchingInterface(org.onlab.packet.IpAddress ip)
Returns an interface that has an address that is in the same subnet as
the given IP address.
|
java.util.Set<Interface> |
getMatchingInterfaces(org.onlab.packet.IpAddress ip)
Returns all interfaces that have an address that is in the same
subnet as the given IP address.
|
boolean |
remove(org.onosproject.net.ConnectPoint connectPoint,
java.lang.String name)
Removes an interface configuration from the system.
|
addListener, onProcessLimit, process, removeListener, reportProblem@Reference(cardinality=MANDATORY_UNARY) protected org.onosproject.net.config.NetworkConfigService configService
@Activate public void activate()
@Deactivate public void deactivate()
public java.util.Set<Interface> getInterfaces()
InterfaceServicegetInterfaces in interface InterfaceServicepublic Interface getInterfaceByName(org.onosproject.net.ConnectPoint connectPoint, java.lang.String name)
InterfaceServicegetInterfaceByName in interface InterfaceServiceconnectPoint - connect point of the interfacename - name of the interfacepublic java.util.Set<Interface> getInterfacesByPort(org.onosproject.net.ConnectPoint port)
InterfaceServicegetInterfacesByPort in interface InterfaceServiceport - connect pointpublic java.util.Set<Interface> getInterfacesByIp(org.onlab.packet.IpAddress ip)
InterfaceServicegetInterfacesByIp in interface InterfaceServiceip - IP addresspublic Interface getMatchingInterface(org.onlab.packet.IpAddress ip)
InterfaceServicegetMatchingInterface in interface InterfaceServiceip - IP address to find matching subnet interface forpublic java.util.Set<Interface> getMatchingInterfaces(org.onlab.packet.IpAddress ip)
InterfaceServicegetMatchingInterfaces in interface InterfaceServiceip - IP address to find matching subnet interface forpublic java.util.Set<Interface> getInterfacesByVlan(org.onlab.packet.VlanId vlan)
InterfaceServicegetInterfacesByVlan in interface InterfaceServicevlan - VLAN ID of the interfacespublic void add(Interface intf)
InterfaceAdminServiceadd in interface InterfaceAdminServiceintf - interface to addpublic boolean remove(org.onosproject.net.ConnectPoint connectPoint,
java.lang.String name)
InterfaceAdminServiceremove in interface InterfaceAdminServiceconnectPoint - connect point of the interfacename - name of the interface