@Beta public interface LabelResourceService extends org.onosproject.event.ListenerService<LabelResourceEvent,LabelResourceListener>
| Modifier and Type | Method and Description |
|---|---|
Collection<LabelResource> |
applyFromDevicePool(org.onosproject.net.DeviceId deviceId,
long applyNum)
Returns labels from resource pool by a specific device id.
|
Collection<LabelResource> |
applyFromGlobalPool(long applyNum)
Returns labels from the global label resource pool.
|
LabelResourcePool |
getDeviceLabelResourcePool(org.onosproject.net.DeviceId deviceId)
Returns the label resource pool of a label resource by a specific device
id.
|
long |
getFreeNumOfDevicePool(org.onosproject.net.DeviceId deviceId)
Returns the unused label number of a label resource pool by a specific device
id.
|
long |
getFreeNumOfGlobalPool()
Returns the unused label number of a global label resource pool.
|
LabelResourcePool |
getGlobalLabelResourcePool()
Returns the global label resource pool.
|
boolean |
isDevicePoolFull(org.onosproject.net.DeviceId deviceId)
Judges if the pool of a specific device id is full.
|
boolean |
isGlobalPoolFull()
Judges if the global resource pool is full.
|
boolean |
releaseToDevicePool(com.google.common.collect.Multimap<org.onosproject.net.DeviceId,LabelResource> release)
Releases unused labels to device pools .
|
boolean |
releaseToGlobalPool(Set<LabelResourceId> release)
Releases unused labels to the global resource pool.
|
Collection<LabelResource> applyFromDevicePool(org.onosproject.net.DeviceId deviceId, long applyNum)
deviceId - device identifierapplyNum - the applying numberCollection<LabelResource> applyFromGlobalPool(long applyNum)
applyNum - the applying numberboolean releaseToDevicePool(com.google.common.collect.Multimap<org.onosproject.net.DeviceId,LabelResource> release)
release - the collection of releasing labelsboolean releaseToGlobalPool(Set<LabelResourceId> release)
release - release the collection of releasing labelsboolean isDevicePoolFull(org.onosproject.net.DeviceId deviceId)
deviceId - device identifierboolean isGlobalPoolFull()
long getFreeNumOfDevicePool(org.onosproject.net.DeviceId deviceId)
deviceId - device identifierlong getFreeNumOfGlobalPool()
LabelResourcePool getDeviceLabelResourcePool(org.onosproject.net.DeviceId deviceId)
deviceId - device identifierLabelResourcePool getGlobalLabelResourcePool()