Package org.onosproject.net
Class AnnotationKeys
- java.lang.Object
-
- org.onosproject.net.AnnotationKeys
-
public final class AnnotationKeys extends java.lang.Object
Collection of keys for annotation.Number of the annotation keys have been deprecated as the use of annotations is being phased out and instead network configuration subsystem is being phased-in for majority of model meta-data.
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
ADMIN_STATE
Annotation key for the admin state.static java.lang.String
BANDWIDTH
Annotation key for bandwidth.static java.lang.String
CHANNEL_ID
Annotation key for the channel id.static java.lang.String
DRIVER
Annotation key for the device driver name.static java.lang.String
DURABLE
Annotation key for durable links.static java.lang.String
GRID_X
Annotation key for grid-X (e.g.static java.lang.String
GRID_Y
Annotation key for grid-Y (e.g.static java.lang.String
LATENCY
Annotation key for latency.static java.lang.String
LATITUDE
Annotation key for latitude (e.g.static java.lang.String
LAYER
Annotation key for the protocol layer.static java.lang.String
LOC_TYPE
Annotation key for UI location type of device/host (either 'geo' or 'grid').static java.lang.String
LONGITUDE
Annotation key for longitude (e.g.static java.lang.String
MANAGEMENT_ADDRESS
Annotation key for the management address.static java.lang.String
METRIC
Annotation key for link metric; used byMetricLinkWeight
function.static java.lang.String
NAME
Annotation key for instance name.static java.lang.String
OPTICAL_WAVES
Annotation key for the number of optical waves.static java.lang.String
OWNER
Annotation key for device owner.static java.lang.String
PASSWORD
Annotation key for the password.static java.lang.String
PORT_IN
Annotation key for the optical channel receiving/in port (RX).static java.lang.String
PORT_MAC
Annotation key for the port mac.static java.lang.String
PORT_NAME
Annotation key for the port name.static java.lang.String
PORT_OUT
Annotation key for the optical channel port transmitting/out port (TX).static java.lang.String
PROTECTED
Link annotation key to express that a Link is backed by underlying protection mechanism.static java.lang.String
PROTOCOL
Annotation key for southbound protocol.static java.lang.String
RACK_ADDRESS
Annotation key for device location.static java.lang.String
REST_SERVER
Annotation key for REST server identifier.static java.lang.String
ROUTER_ID
Annotation key for the router ID.static java.lang.String
SSHKEY
Annotation key for the sshkey.static java.lang.String
STATIC_LAMBDA
Annotation key for the static lambda.static java.lang.String
STATIC_PORT
Annotation key for the static port.static java.lang.String
TYPE
Deprecated.since Cardinalstatic java.lang.String
UI_TYPE
Annotation key for UI type (the glyph ID for rendering).static java.lang.String
USERNAME
Annotation key for the username.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static double
getAnnotatedValue(Annotated annotated, java.lang.String key)
Returns the value annotated object for the specified annotation key.
-
-
-
Field Detail
-
NAME
public static final java.lang.String NAME
Annotation key for instance name.- See Also:
- Constant Field Values
-
TYPE
@Deprecated public static final java.lang.String TYPE
Deprecated.since CardinalAnnotation key for instance type (e.g. host type).- See Also:
- Constant Field Values
-
UI_TYPE
public static final java.lang.String UI_TYPE
Annotation key for UI type (the glyph ID for rendering).- See Also:
- Constant Field Values
-
LOC_TYPE
public static final java.lang.String LOC_TYPE
Annotation key for UI location type of device/host (either 'geo' or 'grid').- See Also:
- Constant Field Values
-
LATITUDE
public static final java.lang.String LATITUDE
Annotation key for latitude (e.g. latitude of device/host in a geo-layout).- See Also:
- Constant Field Values
-
LONGITUDE
public static final java.lang.String LONGITUDE
Annotation key for longitude (e.g. longitude of device/host in a geo-layout).- See Also:
- Constant Field Values
-
GRID_Y
public static final java.lang.String GRID_Y
Annotation key for grid-Y (e.g. y-coordinate of device/host in a grid-layout).- See Also:
- Constant Field Values
-
GRID_X
public static final java.lang.String GRID_X
Annotation key for grid-X (e.g. x-coordinate of device/host in a grid-layout).- See Also:
- Constant Field Values
-
PROTOCOL
public static final java.lang.String PROTOCOL
Annotation key for southbound protocol.- See Also:
- Constant Field Values
-
DRIVER
public static final java.lang.String DRIVER
Annotation key for the device driver name.- See Also:
- Constant Field Values
-
DURABLE
public static final java.lang.String DURABLE
Annotation key for durable links.- See Also:
- Constant Field Values
-
METRIC
public static final java.lang.String METRIC
Annotation key for link metric; used byMetricLinkWeight
function.- See Also:
- Constant Field Values
-
LATENCY
public static final java.lang.String LATENCY
Annotation key for latency. The value of this key is expected to be latency in nanosecond.- See Also:
- Constant Field Values
-
BANDWIDTH
public static final java.lang.String BANDWIDTH
Annotation key for bandwidth. The value for this key is interpreted as Mbps.- See Also:
- Constant Field Values
-
OPTICAL_WAVES
public static final java.lang.String OPTICAL_WAVES
Annotation key for the number of optical waves.- See Also:
- Constant Field Values
-
PORT_NAME
public static final java.lang.String PORT_NAME
Annotation key for the port name.- See Also:
- Constant Field Values
-
PORT_IN
public static final java.lang.String PORT_IN
Annotation key for the optical channel receiving/in port (RX).- See Also:
- Constant Field Values
-
PORT_OUT
public static final java.lang.String PORT_OUT
Annotation key for the optical channel port transmitting/out port (TX).- See Also:
- Constant Field Values
-
PORT_MAC
public static final java.lang.String PORT_MAC
Annotation key for the port mac.- See Also:
- Constant Field Values
-
ADMIN_STATE
public static final java.lang.String ADMIN_STATE
Annotation key for the admin state. The value of this key is expected to be "enabled" or "disabled"- See Also:
- Constant Field Values
-
ROUTER_ID
public static final java.lang.String ROUTER_ID
Annotation key for the router ID.- See Also:
- Constant Field Values
-
STATIC_LAMBDA
public static final java.lang.String STATIC_LAMBDA
Annotation key for the static lambda.- See Also:
- Constant Field Values
-
STATIC_PORT
public static final java.lang.String STATIC_PORT
Annotation key for the static port.- See Also:
- Constant Field Values
-
RACK_ADDRESS
public static final java.lang.String RACK_ADDRESS
Annotation key for device location.- See Also:
- Constant Field Values
-
OWNER
public static final java.lang.String OWNER
Annotation key for device owner.- See Also:
- Constant Field Values
-
CHANNEL_ID
public static final java.lang.String CHANNEL_ID
Annotation key for the channel id.- See Also:
- Constant Field Values
-
MANAGEMENT_ADDRESS
public static final java.lang.String MANAGEMENT_ADDRESS
Annotation key for the management address.- See Also:
- Constant Field Values
-
USERNAME
public static final java.lang.String USERNAME
Annotation key for the username.- See Also:
- Constant Field Values
-
PASSWORD
public static final java.lang.String PASSWORD
Annotation key for the password.- See Also:
- Constant Field Values
-
PROTECTED
public static final java.lang.String PROTECTED
Link annotation key to express that a Link is backed by underlying protection mechanism.- See Also:
- Constant Field Values
-
REST_SERVER
public static final java.lang.String REST_SERVER
Annotation key for REST server identifier.- See Also:
- Constant Field Values
-
SSHKEY
public static final java.lang.String SSHKEY
Annotation key for the sshkey.- See Also:
- Constant Field Values
-
LAYER
public static final java.lang.String LAYER
Annotation key for the protocol layer.- See Also:
- Constant Field Values
-
-
Method Detail
-
getAnnotatedValue
public static double getAnnotatedValue(Annotated annotated, java.lang.String key)
Returns the value annotated object for the specified annotation key. The annotated value is expected to be String that can be parsed as double. If parsing fails, the returned value will be 1.0.- Parameters:
annotated
- annotated object whose annotated value is obtainedkey
- key of annotation- Returns:
- double value of annotated object for the specified key
-
-