Package org.onosproject.net
Class DeviceId
- java.lang.Object
-
- org.onosproject.net.ElementId
-
- org.onosproject.net.DeviceId
-
- All Implemented Interfaces:
NetworkResource
public final class DeviceId extends ElementId
Immutable representation of a device identity.
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
DeviceId()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static DeviceId
deviceId(String string)
Creates a device id using the supplied URI string.static DeviceId
deviceId(URI uri)
Creates a device id using the supplied URI.boolean
equals(Object obj)
int
hashCode()
String
toString()
URI
uri()
Returns the backing URI.
-
-
-
Field Detail
-
NONE
public static final DeviceId NONE
Represents either no device, or an unspecified device.
-
-
Method Detail
-
deviceId
public static DeviceId deviceId(URI uri)
Creates a device id using the supplied URI.- Parameters:
uri
- device URI- Returns:
- DeviceId
-
deviceId
public static DeviceId deviceId(String string)
Creates a device id using the supplied URI string.- Parameters:
string
- device URI string- Returns:
- DeviceId
-
uri
public URI uri()
Returns the backing URI.- Returns:
- backing URI
-
-