Package org.onosproject.net.behaviour
Class DefaultTunnelDescription
- java.lang.Object
-
- org.onosproject.net.AbstractDescription
-
- org.onosproject.net.behaviour.DefaultTunnelDescription
-
- All Implemented Interfaces:
Annotated
,TunnelDescription
,Description
public final class DefaultTunnelDescription extends AbstractDescription implements TunnelDescription
Default implementation of immutable tunnel interface description entity.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
DefaultTunnelDescription.Builder
-
Nested classes/interfaces inherited from interface org.onosproject.net.behaviour.TunnelDescription
TunnelDescription.Type
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static DefaultTunnelDescription.Builder
builder()
Creates and returns a new builder instance.java.util.Optional<java.lang.String>
deviceId()
Returns the identifier of the device where the interface is.java.lang.String
ifaceName()
Return the name of the tunnel interface.java.util.Optional<TunnelKey>
key()
Returns the tunnel key.java.util.Optional<TunnelEndPoint>
local()
Returns the local connection point.java.util.Optional<TunnelEndPoint>
remote()
Returns the remote connection point.java.lang.String
toString()
TunnelDescription.Type
type()
Returns the tunnel type.-
Methods inherited from class org.onosproject.net.AbstractDescription
annotations, equals, hashCode
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.onosproject.net.Description
annotations
-
-
-
-
Method Detail
-
deviceId
public java.util.Optional<java.lang.String> deviceId()
Description copied from interface:TunnelDescription
Returns the identifier of the device where the interface is.- Specified by:
deviceId
in interfaceTunnelDescription
- Returns:
- device identifier
-
ifaceName
public java.lang.String ifaceName()
Description copied from interface:TunnelDescription
Return the name of the tunnel interface.- Specified by:
ifaceName
in interfaceTunnelDescription
- Returns:
- tunnel interface name
-
type
public TunnelDescription.Type type()
Description copied from interface:TunnelDescription
Returns the tunnel type.- Specified by:
type
in interfaceTunnelDescription
- Returns:
- tunnel type
-
local
public java.util.Optional<TunnelEndPoint> local()
Description copied from interface:TunnelDescription
Returns the local connection point.- Specified by:
local
in interfaceTunnelDescription
- Returns:
- tunnel source ConnectionPoint
-
remote
public java.util.Optional<TunnelEndPoint> remote()
Description copied from interface:TunnelDescription
Returns the remote connection point.- Specified by:
remote
in interfaceTunnelDescription
- Returns:
- tunnel destination
-
key
public java.util.Optional<TunnelKey> key()
Description copied from interface:TunnelDescription
Returns the tunnel key.- Specified by:
key
in interfaceTunnelDescription
- Returns:
- tunnel key
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
builder
public static DefaultTunnelDescription.Builder builder()
Creates and returns a new builder instance.- Returns:
- default tunnel description builder
-
-