Class TestInterfaceManager
- java.lang.Object
-
- org.opendaylight.genius.testutils.TestInterfaceManager
-
- All Implemented Interfaces:
IInterfaceManager
public abstract class TestInterfaceManager extends java.lang.Object implements IInterfaceManager
IInterfaceManager implementation for tests.- Author:
- Michael Vorburger
-
-
Constructor Summary
Constructors Constructor Description TestInterfaceManager()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description void
addInterface(org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev140508.interfaces.Interface iface)
void
addInterfaceInfo(InterfaceInfo interfaceInfo)
void
addTunnelInterface(TunnelInterfaceDetails tunnelInterfaceDetails)
org.opendaylight.yangtools.yang.common.Uint64
getDpnForInterface(java.lang.String interfaceName)
org.opendaylight.yangtools.yang.common.Uint64
getDpnForInterface(org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev140508.interfaces.Interface intrface)
InterfaceInfo
getInterfaceInfo(java.lang.String interfaceName)
org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev140508.interfaces.Interface
getInterfaceInfoFromConfigDataStore(java.lang.String interfaceName)
Retrieve the interface information from the configuration datastore.InterfaceInfo
getInterfaceInfoFromOperationalDataStore(java.lang.String interfaceName)
InterfaceInfo
getInterfaceInfoFromOperationalDataStore(java.lang.String interfaceName, InterfaceInfo.InterfaceType interfaceType)
InterfaceInfo
getInterfaceInfoFromOperationalDSCache(java.lang.String interfaceName)
This API is currently used only for CLI usage.boolean
isExternalInterface(java.lang.String interfaceName)
Determine whether an interface is external.boolean
isItmDirectTunnelsEnabled()
static TestInterfaceManager
newInstance()
Deprecated.UsenewInstance(DataBroker)
instead now.static TestInterfaceManager
newInstance(org.opendaylight.controller.md.sal.binding.api.DataBroker dataBroker)
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.opendaylight.genius.interfacemanager.interfaces.IInterfaceManager
bindService, bindService, createVLANInterface, createVLANInterface, createVLANInterface, createVLANInterface, getBfdStateCache, getBridgeRefEntryMap, getChildInterfaces, getChildInterfaces, getEndpointIpForDpn, getInterfaceEgressActions, getInterfaceInfoFromConfigDataStore, getLogicalTunnelSelectGroupId, getOvsdbBridgeForInterface, getOvsdbBridgeForNodeIid, getParentRefNameForInterface, getPortForInterface, getPortForInterface, getPortNameForInterface, getPortNameForInterface, getPortsOnBridge, getPortsOnBridgeByType, getTerminationPointCache, getTerminationPointForInterface, getTunnelPortsOnBridge, getVlanInterfaces, getVxlanInterfaces, isExternalInterface, isServiceBoundOnInterfaceForEgress, isServiceBoundOnInterfaceForIngress, unbindService, updateInterfaceParentRef, updateInterfaceParentRef
-
-
-
-
Method Detail
-
newInstance
@Deprecated public static TestInterfaceManager newInstance()
Deprecated.UsenewInstance(DataBroker)
instead now.Deprecated factory method.
-
newInstance
public static TestInterfaceManager newInstance(org.opendaylight.controller.md.sal.binding.api.DataBroker dataBroker)
-
addInterfaceInfo
public void addInterfaceInfo(InterfaceInfo interfaceInfo) throws org.opendaylight.controller.md.sal.common.api.data.TransactionCommitFailedException
- Throws:
org.opendaylight.controller.md.sal.common.api.data.TransactionCommitFailedException
-
addInterface
public void addInterface(org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev140508.interfaces.Interface iface)
-
addTunnelInterface
public void addTunnelInterface(TunnelInterfaceDetails tunnelInterfaceDetails) throws org.opendaylight.controller.md.sal.common.api.data.TransactionCommitFailedException
- Throws:
org.opendaylight.controller.md.sal.common.api.data.TransactionCommitFailedException
-
getInterfaceInfo
public InterfaceInfo getInterfaceInfo(java.lang.String interfaceName)
- Specified by:
getInterfaceInfo
in interfaceIInterfaceManager
-
getInterfaceInfoFromOperationalDataStore
public InterfaceInfo getInterfaceInfoFromOperationalDataStore(java.lang.String interfaceName)
- Specified by:
getInterfaceInfoFromOperationalDataStore
in interfaceIInterfaceManager
-
getInterfaceInfoFromOperationalDataStore
public InterfaceInfo getInterfaceInfoFromOperationalDataStore(java.lang.String interfaceName, InterfaceInfo.InterfaceType interfaceType)
- Specified by:
getInterfaceInfoFromOperationalDataStore
in interfaceIInterfaceManager
-
getInterfaceInfoFromOperationalDSCache
public InterfaceInfo getInterfaceInfoFromOperationalDSCache(java.lang.String interfaceName)
Description copied from interface:IInterfaceManager
This API is currently used only for CLI usage. Please be careful that this API can return stale entries since it is just a cache read.- Specified by:
getInterfaceInfoFromOperationalDSCache
in interfaceIInterfaceManager
-
getInterfaceInfoFromConfigDataStore
public org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev140508.interfaces.Interface getInterfaceInfoFromConfigDataStore(java.lang.String interfaceName)
Description copied from interface:IInterfaceManager
Retrieve the interface information from the configuration datastore.- Specified by:
getInterfaceInfoFromConfigDataStore
in interfaceIInterfaceManager
- Parameters:
interfaceName
- The interface name.- Returns:
- The interface information.
-
getDpnForInterface
public org.opendaylight.yangtools.yang.common.Uint64 getDpnForInterface(java.lang.String interfaceName)
- Specified by:
getDpnForInterface
in interfaceIInterfaceManager
-
getDpnForInterface
public org.opendaylight.yangtools.yang.common.Uint64 getDpnForInterface(org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.interfaces.rev140508.interfaces.Interface intrface)
- Specified by:
getDpnForInterface
in interfaceIInterfaceManager
-
isExternalInterface
public boolean isExternalInterface(java.lang.String interfaceName)
Description copied from interface:IInterfaceManager
Determine whether an interface is external.- Specified by:
isExternalInterface
in interfaceIInterfaceManager
- Parameters:
interfaceName
- The interface name.- Returns:
true
if the interface is external,false
if it isn't.
-
isItmDirectTunnelsEnabled
public boolean isItmDirectTunnelsEnabled()
- Specified by:
isItmDirectTunnelsEnabled
in interfaceIInterfaceManager
-
-