Package org.onosproject.net.behaviour
Interface L2SwitchVlanConfigBehaviour
-
- All Superinterfaces:
Behaviour
,HandlerBehaviour
@Beta public interface L2SwitchVlanConfigBehaviour extends HandlerBehaviour
Means to configure VLANs on legacy L2 switch devices.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description boolean
addVlan(java.util.Collection<VlanId> vlanIds)
Adds VLANs on a device.default boolean
addVlan(VlanId vlanId)
Adds a VLAN on a device.boolean
disableVlan(java.util.Collection<VlanId> vlanIds)
Disables VLANs on a device.default boolean
disableVlan(VlanId vlanId)
Disables a VLAN on a device.boolean
enableVlan(java.util.Collection<VlanId> vlanIds)
Enables VLANs on a device.default boolean
enableVlan(VlanId vlanId)
Enables a VLAN on a device.java.util.Collection<VlanId>
getVlans()
Provides the VLANs configured on a device.boolean
isEnabled(VlanId vlanId)
Obtains the status of a VLAN on a device.boolean
removeVlan(java.util.Collection<VlanId> vlanIds)
Removes VLANs from a device.default boolean
removeVlan(VlanId vlanId)
Removes a VLAN from a device.-
Methods inherited from interface org.onosproject.net.driver.HandlerBehaviour
handler, setHandler
-
-
-
-
Method Detail
-
getVlans
java.util.Collection<VlanId> getVlans()
Provides the VLANs configured on a device.- Returns:
- the configured VLANs on the device
-
addVlan
default boolean addVlan(VlanId vlanId)
Adds a VLAN on a device. Default enabled/disabled status of VLAN after depends on device.- Parameters:
vlanId
- the VLAN to add- Returns:
- true, if the VLAN was added successfully; false otherwise
-
addVlan
boolean addVlan(java.util.Collection<VlanId> vlanIds)
Adds VLANs on a device. Default enabled/disabled status of VLAN after depends on device.- Parameters:
vlanIds
- the VLANs to add- Returns:
- true, if the VLANs were added successfully; false otherwise
-
removeVlan
default boolean removeVlan(VlanId vlanId)
Removes a VLAN from a device.- Parameters:
vlanId
- the VLAN to remove- Returns:
- true, if the VLAN was removed successfully; false otherwise
-
removeVlan
boolean removeVlan(java.util.Collection<VlanId> vlanIds)
Removes VLANs from a device.- Parameters:
vlanIds
- the VLANs to remove- Returns:
- true, if the VLANs were removed successfully; false otherwise
-
isEnabled
boolean isEnabled(VlanId vlanId)
Obtains the status of a VLAN on a device.- Parameters:
vlanId
- the VLAN to check- Returns:
- true, if the VLAN is configured and enabled; false otherwise
-
enableVlan
default boolean enableVlan(VlanId vlanId)
Enables a VLAN on a device.- Parameters:
vlanId
- the VLAN to enable- Returns:
- true, if the VLAN was enabled successfully; false otherwise
-
enableVlan
boolean enableVlan(java.util.Collection<VlanId> vlanIds)
Enables VLANs on a device.- Parameters:
vlanIds
- the VLANs to enable- Returns:
- true, if the VLANs were enabled successfully; false otherwise
-
disableVlan
default boolean disableVlan(VlanId vlanId)
Disables a VLAN on a device.- Parameters:
vlanId
- the VLAN to disable- Returns:
- true, if the VLAN was disabled successfully; false otherwise
-
disableVlan
boolean disableVlan(java.util.Collection<VlanId> vlanIds)
Disables VLANs on a device.- Parameters:
vlanIds
- VLANs to disable- Returns:
- true, if the VLANs were disabled successfully; false otherwise
-
-