public class ProviderId extends Object
Provider
family.
It also carriers two designations of external characteristics, the URI
scheme and primary/ancillary indicator.
The device URI scheme is used to determine applicability of a provider to operations on a specific device. The ancillary indicator serves to designate a provider as a primary or ancillary.
A ProviderRegistry
uses this designation
to permit only one primary provider per device URI scheme. Multiple
ancillary providers can register with the same device URI scheme however.
Modifier and Type | Field and Description |
---|---|
static ProviderId |
NONE
Represents no provider ID.
|
Constructor and Description |
---|
ProviderId(String scheme,
String id)
Creates a new primary provider identifier from the specified string.
|
ProviderId(String scheme,
String id,
boolean ancillary)
Creates a new provider identifier from the specified string.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object obj) |
int |
hashCode() |
String |
id()
Returns the device URI scheme specific id portion.
|
boolean |
isAncillary()
Indicates whether this identifier designates an ancillary providers.
|
String |
scheme()
Returns the device URI scheme to which this provider is bound.
|
String |
toString() |
public static final ProviderId NONE
public ProviderId(String scheme, String id)
org.onosproject.provider.of.device
scheme
- device URI scheme to which this provider is bound, e.g. "of", "snmp"id
- string identifierpublic ProviderId(String scheme, String id, boolean ancillary)
org.onosproject.provider.of.device
scheme
- device URI scheme to which this provider is bound, e.g. "of", "snmp"id
- string identifierancillary
- ancillary provider indicatorpublic String scheme()
public String id()
public boolean isAncillary()