public class MappingService extends Object implements OdlMappingserviceService, IMappingService, org.opendaylight.controller.sal.binding.api.BindingAwareProvider, AutoCloseable
| Modifier and Type | Field and Description |
|---|---|
protected static org.slf4j.Logger |
LOG |
| Constructor and Description |
|---|
MappingService() |
| Modifier and Type | Method and Description |
|---|---|
void |
addAuthenticationKey(Eid key,
MappingAuthkey authKey)
Add authentication key
|
void |
addData(MappingOrigin origin,
Eid key,
String subKey,
Object data)
Generic addition of data.
|
Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> |
addKey(AddKeyInput input) |
Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> |
addKeys(AddKeysInput input) |
Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> |
addMapping(AddMappingInput input) |
void |
addMapping(MappingOrigin origin,
Eid key,
SiteId siteId,
Object data)
Add mapping
|
Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> |
addMappings(AddMappingsInput input) |
void |
cleanCachedMappings()
Cleans all cached mappings.Used for testing.
|
void |
close() |
Future<org.opendaylight.yangtools.yang.common.RpcResult<GetAllKeysOutput>> |
getAllKeys() |
Future<org.opendaylight.yangtools.yang.common.RpcResult<GetAllMappingsOutput>> |
getAllMappings() |
MappingAuthkey |
getAuthenticationKey(Eid key)
Retrieve authentication key
|
Object |
getData(MappingOrigin origin,
Eid key,
String subKey)
Generic retrieval of data
|
Future<org.opendaylight.yangtools.yang.common.RpcResult<GetKeyOutput>> |
getKey(GetKeyInput input) |
Future<org.opendaylight.yangtools.yang.common.RpcResult<GetKeysOutput>> |
getKeys(GetKeysInput input) |
Object |
getMapping(Eid key)
Retrieves mapping for given key.The lookup policy for the key is defined in the Mapping
System
|
Object |
getMapping(Eid srcKey,
Eid dstKey)
Retrieves mapping with a Source/Dest policy.
|
Future<org.opendaylight.yangtools.yang.common.RpcResult<GetMappingOutput>> |
getMapping(GetMappingInput input) |
Object |
getMapping(MappingOrigin origin,
Eid key)
Retrieves mapping with given origin for the provided key.
|
Future<org.opendaylight.yangtools.yang.common.RpcResult<GetMappingsOutput>> |
getMappings(GetMappingsInput input) |
void |
initialize() |
void |
onSessionInitiated(org.opendaylight.controller.sal.binding.api.BindingAwareBroker.ProviderContext session) |
String |
printMappings()
Print all mappings.
|
Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> |
removeAllKeys() |
Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> |
removeAllMappings() |
void |
removeAuthenticationKey(Eid key)
Remove authentication key
|
void |
removeData(MappingOrigin origin,
Eid key,
String subKey)
Generic removal of data
|
Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> |
removeKey(RemoveKeyInput input) |
Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> |
removeKeys(RemoveKeysInput input) |
void |
removeMapping(MappingOrigin origin,
Eid key)
Remove mapping
|
Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> |
removeMapping(RemoveMappingInput input) |
Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> |
removeMappings(RemoveMappingsInput input) |
void |
setBindingAwareBroker(org.opendaylight.controller.sal.binding.api.BindingAwareBroker broker) |
void |
setDaoService(ILispDAO dao) |
void |
setDataBroker(org.opendaylight.controller.md.sal.binding.api.DataBroker dataBroker) |
void |
setMappingOverwrite(boolean overwrite)
Configures Mapping Service mapping overwrite option.
|
void |
setNotificationPublishService(org.opendaylight.controller.md.sal.binding.api.NotificationPublishService nps) |
void |
setRpcProviderRegistry(org.opendaylight.controller.sal.binding.api.RpcProviderRegistry rpc) |
Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> |
updateKey(UpdateKeyInput input) |
Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> |
updateKeys(UpdateKeysInput input) |
Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> |
updateMapping(UpdateMappingInput input) |
Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> |
updateMappings(UpdateMappingsInput input) |
public void setDataBroker(org.opendaylight.controller.md.sal.binding.api.DataBroker dataBroker)
public void setRpcProviderRegistry(org.opendaylight.controller.sal.binding.api.RpcProviderRegistry rpc)
public void setBindingAwareBroker(org.opendaylight.controller.sal.binding.api.BindingAwareBroker broker)
public void setNotificationPublishService(org.opendaylight.controller.md.sal.binding.api.NotificationPublishService nps)
public void setDaoService(ILispDAO dao)
public void setMappingOverwrite(boolean overwrite)
IMappingServicesetMappingOverwrite in interface IMappingServiceoverwrite - enables or disables mapping overwritepublic void initialize()
public Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> addKey(AddKeyInput input)
addKey in interface OdlMappingserviceServicepublic Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> addMapping(AddMappingInput input)
addMapping in interface OdlMappingserviceServicepublic Future<org.opendaylight.yangtools.yang.common.RpcResult<GetKeyOutput>> getKey(GetKeyInput input)
getKey in interface OdlMappingserviceServicepublic Future<org.opendaylight.yangtools.yang.common.RpcResult<GetMappingOutput>> getMapping(GetMappingInput input)
getMapping in interface OdlMappingserviceServicepublic Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> removeKey(RemoveKeyInput input)
removeKey in interface OdlMappingserviceServicepublic Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> removeMapping(RemoveMappingInput input)
removeMapping in interface OdlMappingserviceServicepublic Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> updateKey(UpdateKeyInput input)
updateKey in interface OdlMappingserviceServicepublic Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> updateMapping(UpdateMappingInput input)
updateMapping in interface OdlMappingserviceServicepublic Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> removeKeys(RemoveKeysInput input)
removeKeys in interface OdlMappingserviceServicepublic Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> removeMappings(RemoveMappingsInput input)
removeMappings in interface OdlMappingserviceServicepublic Future<org.opendaylight.yangtools.yang.common.RpcResult<GetKeysOutput>> getKeys(GetKeysInput input)
getKeys in interface OdlMappingserviceServicepublic Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> addMappings(AddMappingsInput input)
addMappings in interface OdlMappingserviceServicepublic Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> updateKeys(UpdateKeysInput input)
updateKeys in interface OdlMappingserviceServicepublic Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> removeAllMappings()
removeAllMappings in interface OdlMappingserviceServicepublic Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> removeAllKeys()
removeAllKeys in interface OdlMappingserviceServicepublic Future<org.opendaylight.yangtools.yang.common.RpcResult<GetAllKeysOutput>> getAllKeys()
getAllKeys in interface OdlMappingserviceServicepublic Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> updateMappings(UpdateMappingsInput input)
updateMappings in interface OdlMappingserviceServicepublic Future<org.opendaylight.yangtools.yang.common.RpcResult<Void>> addKeys(AddKeysInput input)
addKeys in interface OdlMappingserviceServicepublic Future<org.opendaylight.yangtools.yang.common.RpcResult<GetAllMappingsOutput>> getAllMappings()
getAllMappings in interface OdlMappingserviceServicepublic Future<org.opendaylight.yangtools.yang.common.RpcResult<GetMappingsOutput>> getMappings(GetMappingsInput input)
getMappings in interface OdlMappingserviceServicepublic void addMapping(MappingOrigin origin, Eid key, SiteId siteId, Object data)
IMappingServiceaddMapping in interface IMappingServiceorigin - Table where mapping should be addedkey - Key of the mappingsiteId - Site that stores the mappingdata - Value to be storedpublic Object getMapping(MappingOrigin origin, Eid key)
IMappingServicegetMapping in interface IMappingServiceorigin - Table where the mapping should be looked up.key - Key to be looked uppublic Object getMapping(Eid key)
IMappingServicegetMapping in interface IMappingServicekey - Key to be looked uppublic Object getMapping(Eid srcKey, Eid dstKey)
IMappingServicegetMapping in interface IMappingServicesrcKey - Source key being looked updstKey - Destination key being looked uppublic void removeMapping(MappingOrigin origin, Eid key)
IMappingServiceremoveMapping in interface IMappingServiceorigin - Table from where the mapping should be removedkey - Key to be removedpublic void addAuthenticationKey(Eid key, MappingAuthkey authKey)
IMappingServiceaddAuthenticationKey in interface IMappingServicekey - The key for which the authentication key is addedauthKey - The authentication keypublic MappingAuthkey getAuthenticationKey(Eid key)
IMappingServicegetAuthenticationKey in interface IMappingServicekey - The key for which the authentication key is being looked up.public void removeAuthenticationKey(Eid key)
IMappingServiceremoveAuthenticationKey in interface IMappingServicekey - Key for which the authentication key should be removed.public void addData(MappingOrigin origin, Eid key, String subKey, Object data)
IMappingServiceaddData in interface IMappingServiceorigin - Table where data should be insertedkey - The key where data should be insertedsubKey - The subKey where data should be inserteddata - The data to be storedpublic Object getData(MappingOrigin origin, Eid key, String subKey)
IMappingServicegetData in interface IMappingServiceorigin - Table from where the data should be readkey - The key where the data is storedsubKey - The subKey where data is storedpublic void removeData(MappingOrigin origin, Eid key, String subKey)
IMappingServiceremoveData in interface IMappingServiceorigin - The table from where the data should be removedkey - The key of the data to be removedsubKey - The subKey of the data to be removedpublic String printMappings()
IMappingServiceprintMappings in interface IMappingServicepublic void onSessionInitiated(org.opendaylight.controller.sal.binding.api.BindingAwareBroker.ProviderContext session)
onSessionInitiated in interface org.opendaylight.controller.sal.binding.api.BindingAwareProviderpublic void close()
throws Exception
close in interface AutoCloseableExceptionpublic void cleanCachedMappings()
IMappingServicecleanCachedMappings in interface IMappingServiceCopyright © 2017 OpenDaylight. All rights reserved.