QKDConnectionRegister is a class used to keep details about distant QKD links and applications. More...
#include "qkd-connection-register.h"
Inheritance diagram for ns3::QKDConnectionRegister:
Collaboration diagram for ns3::QKDConnectionRegister:Public Member Functions | |
| QKDConnectionRegister () | |
| Constructor. More... | |
| bool | AddApplicationEntry (QKDApplicationEntry &r) |
| Add the QKD application entry if it doesn't yet exist in the table. More... | |
| bool | AddKeyAssociationEntry (QKDKeyAssociationLinkEntry &r) |
| Add the key association entry if it doesn't yet exist in the table. More... | |
| bool | AssignKeyAssociation (UUID srcSaeId, UUID dstSaeId, std::string type, uint32_t priority, QKDKeyAssociationLinkEntry &rt) |
| Assign the key association. More... | |
| bool | DeleteApplicationEntry (UUID dst) |
| Delete the application entry, if it exists. More... | |
| bool | DeleteKeyAssociationLinkEntry (uint32_t dst) |
| Delete the key association table entry with a given destination, if it exists. More... | |
| virtual TypeId | GetInstanceTypeId (void) const |
| Get the type ID for the instance. More... | |
| uint32_t | GetNumberOfApplications () |
| Get the number of the applications present in the applications table. More... | |
| uint32_t | GetNumberOfKeyAssociations () |
| \briet Get the number of the key associations present in the associations table. More... | |
| bool | LookupApplication (UUID dstSaeId, QKDApplicationEntry &rt) |
| Lookup the application entry with the destination (receiver) application identifier (UUID). More... | |
| bool | LookupApplicationBySaeIDsAndType (UUID srcSaeId, UUID dstSaeId, QKDApplicationEntry::ConnectionType type, QKDApplicationEntry &rt) |
| Lookup the application entry with the application identifiers and the connection type. More... | |
| bool | LookupKeyAssociationByApplicationId (UUID saeId, QKDKeyAssociationLinkEntry &rt) |
| Lookup the key association entry with the application identifier (UUID). More... | |
| bool | LookupKeyAssociationByDestinationNodeId (uint32_t srcNodeId, uint32_t dstNodeId, QKDKeyAssociationLinkEntry &rt) |
| Lookup the key association entry with the source and destination identifiers. More... | |
| bool | LookupKeyAssociationById (UUID keyAssociationId, QKDKeyAssociationLinkEntry &rt) |
| Lookup the key association entry with destination node identifier. More... | |
| bool | LookupKeyAssociationBySaeId (UUID id, QKDKeyAssociationLinkEntry &rt) |
| Lookup the key association entry with the application identifier (UUID). More... | |
| void | Print (Ptr< OutputStreamWrapper > stream) const |
| Print the location table. More... | |
| void | PrintListOfAllKeyAssociations () |
| Print the key association list. More... | |
| bool | SaveKeyAssociation (QKDKeyAssociationLinkEntry &rt) |
| Store the key association entry. More... | |
| void | UpdateQKDApplications (UUID keyAssociationId, UUID saeId) |
| Update the key association list of QKD applications. More... | |
Public Member Functions inherited from ns3::Object | |
| Object () | |
| Constructor. More... | |
| ~Object () override | |
| Destructor. More... | |
| void | AggregateObject (Ptr< Object > other) |
| Aggregate two Objects together. More... | |
| void | Dispose () |
| Dispose of this Object. More... | |
| AggregateIterator | GetAggregateIterator () const |
| Get an iterator to the Objects aggregated to this one. More... | |
| template<typename T > | |
| Ptr< T > | GetObject () const |
| Get a pointer to the requested aggregated Object. More... | |
| template<> | |
| Ptr< Object > | GetObject () const |
| Specialization of () for objects of type ns3::Object. More... | |
| template<typename T > | |
| Ptr< T > | GetObject (TypeId tid) const |
| Get a pointer to the requested aggregated Object by TypeId. More... | |
| template<> | |
| Ptr< Object > | GetObject (TypeId tid) const |
| Specialization of (TypeId tid) for objects of type ns3::Object. More... | |
| void | Initialize () |
| Invoke DoInitialize on all Objects aggregated to this one. More... | |
| bool | IsInitialized () const |
| Check if the object has been initialized. More... | |
Public Member Functions inherited from ns3::SimpleRefCount< Object, ObjectBase, ObjectDeleter > | |
| SimpleRefCount () | |
| Default constructor. More... | |
| SimpleRefCount (const SimpleRefCount &o[[maybe_unused]]) | |
| Copy constructor. More... | |
| uint32_t | GetReferenceCount () const |
| Get the reference count of the object. More... | |
| SimpleRefCount & | operator= (const SimpleRefCount &o[[maybe_unused]]) |
| Assignment operator. More... | |
| void | Ref () const |
| Increment the reference count. More... | |
| void | Unref () const |
| Decrement the reference count. More... | |
Public Member Functions inherited from ns3::ObjectBase | |
| virtual | ~ObjectBase () |
| Virtual destructor. More... | |
| void | GetAttribute (std::string name, AttributeValue &value) const |
| Get the value of an attribute, raising fatal errors if unsuccessful. More... | |
| bool | GetAttributeFailSafe (std::string name, AttributeValue &value) const |
| Get the value of an attribute without raising errors. More... | |
| void | SetAttribute (std::string name, const AttributeValue &value) |
| Set a single attribute, raising fatal errors if unsuccessful. More... | |
| bool | SetAttributeFailSafe (std::string name, const AttributeValue &value) |
| Set a single attribute without raising errors. More... | |
| bool | TraceConnect (std::string name, std::string context, const CallbackBase &cb) |
| Connect a TraceSource to a Callback with a context. More... | |
| bool | TraceConnectWithoutContext (std::string name, const CallbackBase &cb) |
| Connect a TraceSource to a Callback without a context. More... | |
| bool | TraceDisconnect (std::string name, std::string context, const CallbackBase &cb) |
| Disconnect from a TraceSource a Callback previously connected with a context. More... | |
| bool | TraceDisconnectWithoutContext (std::string name, const CallbackBase &cb) |
| Disconnect from a TraceSource a Callback previously connected without a context. More... | |
Static Public Member Functions | |
| static TypeId | GetTypeId (void) |
| Get the type ID. More... | |
Static Public Member Functions inherited from ns3::Object | |
| static TypeId | GetTypeId () |
| Register this type. More... | |
Static Public Member Functions inherited from ns3::ObjectBase | |
| static TypeId | GetTypeId () |
| Get the type ID. More... | |
Private Attributes | |
| std::map< UUID, QKDApplicationEntry > | m_applications |
| The list of applications. More... | |
| std::map< uint32_t, QKDKeyAssociationLinkEntry > | m_keyAssociations |
| The list of key associations. More... | |
Additional Inherited Members | |
Protected Member Functions inherited from ns3::Object | |
| Object (const Object &o) | |
| Copy an Object. More... | |
| virtual void | DoDispose () |
| Destructor implementation. More... | |
| virtual void | DoInitialize () |
| Initialize() implementation. More... | |
| virtual void | NotifyNewAggregate () |
| Notify all Objects aggregated to this one of a new Object being aggregated. More... | |
Protected Member Functions inherited from ns3::ObjectBase | |
| void | ConstructSelf (const AttributeConstructionList &attributes) |
| Complete construction of ObjectBase; invoked by derived classes. More... | |
| virtual void | NotifyConstructionCompleted () |
| Notifier called once the ObjectBase is fully constructed. More... | |
Related Functions inherited from ns3::ObjectBase | |
| static TypeId | GetObjectIid () |
| Ensure the TypeId for ObjectBase gets fully configured to anchor the inheritance tree properly. More... | |
QKDConnectionRegister is a class used to keep details about distant QKD links and applications.
Definition at line 60 of file qkd-connection-register.h.
| ns3::QKDConnectionRegister::QKDConnectionRegister | ( | ) |
Constructor.
Definition at line 57 of file qkd-connection-register.cc.
| bool ns3::QKDConnectionRegister::AddApplicationEntry | ( | QKDApplicationEntry & | r | ) |
Add the QKD application entry if it doesn't yet exist in the table.
| r | The location table entry. |
Definition at line 60 of file qkd-connection-register.cc.
References ns3::QKDApplicationEntry::GetId(), m_applications, and NS_LOG_FUNCTION.
Here is the call graph for this function:| bool ns3::QKDConnectionRegister::AddKeyAssociationEntry | ( | QKDKeyAssociationLinkEntry & | r | ) |
Add the key association entry if it doesn't yet exist in the table.
| r | The location table entry. |
Definition at line 84 of file qkd-connection-register.cc.
References ns3::QKDKeyAssociationLinkEntry::GetDestinationNodeId(), ns3::QKDKeyAssociationLinkEntry::GetId(), m_keyAssociations, NS_LOG_FUNCTION, and ns3::UUID::string().
Here is the call graph for this function:| bool ns3::QKDConnectionRegister::AssignKeyAssociation | ( | UUID | srcSaeId, |
| UUID | dstSaeId, | ||
| std::string | type, | ||
| uint32_t | priority, | ||
| QKDKeyAssociationLinkEntry & | rt | ||
| ) |
Assign the key association.
| srdSaeId | The soruce (sender) application identifier (UUID). |
| dstSaeId | The destination (receiver) application identifier (UUID). |
| type | The key association type. |
| priority | The key association priority. |
| rt | The entry with the application dstId, if exists. |
Definition at line 257 of file qkd-connection-register.cc.
References m_keyAssociations, NS_LOG_FUNCTION, PrintListOfAllKeyAssociations(), and check-style-clang-format::type.
Here is the call graph for this function:| bool ns3::QKDConnectionRegister::DeleteApplicationEntry | ( | UUID | dst | ) |
Delete the application entry, if it exists.
| dst | The destination (receiver) application identifier (UUID). |
Definition at line 94 of file qkd-connection-register.cc.
References m_applications.
| bool ns3::QKDConnectionRegister::DeleteKeyAssociationLinkEntry | ( | uint32_t | dst | ) |
Delete the key association table entry with a given destination, if it exists.
| dst | The destination node identifier |
Definition at line 101 of file qkd-connection-register.cc.
References m_keyAssociations.
|
virtual |
Get the type ID for the instance.
Reimplemented from ns3::Object.
Definition at line 52 of file qkd-connection-register.cc.
References GetTypeId().
Here is the call graph for this function:
|
inline |
Get the number of the applications present in the applications table.
Definition at line 225 of file qkd-connection-register.h.
References m_applications.
|
inline |
\briet Get the number of the key associations present in the associations table.
Definition at line 216 of file qkd-connection-register.h.
References m_keyAssociations.
|
static |
Get the type ID.
Definition at line 41 of file qkd-connection-register.cc.
References ns3::TypeId::SetParent().
Referenced by GetInstanceTypeId().
Here is the call graph for this function:
Here is the caller graph for this function:| bool ns3::QKDConnectionRegister::LookupApplication | ( | UUID | dstSaeId, |
| QKDApplicationEntry & | rt | ||
| ) |
Lookup the application entry with the destination (receiver) application identifier (UUID).
| dst | The destination (receiver) application identifier (UUID). |
| rt | The entry with the destination address dst, if exists. |
Definition at line 108 of file qkd-connection-register.cc.
References m_applications, and NS_LOG_FUNCTION.
| bool ns3::QKDConnectionRegister::LookupApplicationBySaeIDsAndType | ( | UUID | srcSaeId, |
| UUID | dstSaeId, | ||
| QKDApplicationEntry::ConnectionType | type, | ||
| QKDApplicationEntry & | rt | ||
| ) |
Lookup the application entry with the application identifiers and the connection type.
| src | The source (sender) application identifier (UUID). |
| dst | The destination (receiver) application identifier (UUID). |
| type | The conncetion type. |
| rt | The entry with the destination address dst, if exists. |
Definition at line 144 of file qkd-connection-register.cc.
References m_applications, NS_LOG_FUNCTION, and check-style-clang-format::type.
| bool ns3::QKDConnectionRegister::LookupKeyAssociationByApplicationId | ( | UUID | saeId, |
| QKDKeyAssociationLinkEntry & | rt | ||
| ) |
Lookup the key association entry with the application identifier (UUID).
| saeId | The application identifier (UUID). |
| rt | The entry with the application saeId, if exists. |
Definition at line 221 of file qkd-connection-register.cc.
References m_keyAssociations, NS_LOG_FUNCTION, and PrintListOfAllKeyAssociations().
Here is the call graph for this function:| bool ns3::QKDConnectionRegister::LookupKeyAssociationByDestinationNodeId | ( | uint32_t | srcNodeId, |
| uint32_t | dstNodeId, | ||
| QKDKeyAssociationLinkEntry & | rt | ||
| ) |
Lookup the key association entry with the source and destination identifiers.
| srcNodeId | The source node identifier. |
| dstNodeId | The destination node identifier. |
| rt | The entry with either the source or destination node identifier, if exists. |
Definition at line 198 of file qkd-connection-register.cc.
References m_keyAssociations, and NS_LOG_FUNCTION.
| bool ns3::QKDConnectionRegister::LookupKeyAssociationById | ( | UUID | keyAssociationId, |
| QKDKeyAssociationLinkEntry & | rt | ||
| ) |
Lookup the key association entry with destination node identifier.
| dst | The destination node identifier. |
| rt | The entry with the destination address dst, if exists. |
Definition at line 180 of file qkd-connection-register.cc.
References m_keyAssociations, and NS_LOG_FUNCTION.
| bool ns3::QKDConnectionRegister::LookupKeyAssociationBySaeId | ( | UUID | id, |
| QKDKeyAssociationLinkEntry & | rt | ||
| ) |
| void ns3::QKDConnectionRegister::Print | ( | Ptr< OutputStreamWrapper > | stream | ) | const |
Print the location table.
| stream | The output stream. |
| void ns3::QKDConnectionRegister::PrintListOfAllKeyAssociations | ( | ) |
Print the key association list.
Definition at line 297 of file qkd-connection-register.cc.
References m_keyAssociations, and NS_LOG_FUNCTION.
Referenced by AssignKeyAssociation(), LookupKeyAssociationByApplicationId(), and SaveKeyAssociation().
Here is the caller graph for this function:| bool ns3::QKDConnectionRegister::SaveKeyAssociation | ( | QKDKeyAssociationLinkEntry & | rt | ) |
Store the key association entry.
| The | key association entry. |
Definition at line 279 of file qkd-connection-register.cc.
References ns3::QKDKeyAssociationLinkEntry::GetId(), m_keyAssociations, NS_LOG_FUNCTION, and PrintListOfAllKeyAssociations().
Here is the call graph for this function:Update the key association list of QKD applications.
| keyAssociationId | The key association identifier. |
| saeId | The application identifier (UUID). |
Definition at line 308 of file qkd-connection-register.cc.
References m_keyAssociations, and NS_LOG_FUNCTION.
|
private |
The list of applications.
Definition at line 248 of file qkd-connection-register.h.
Referenced by AddApplicationEntry(), DeleteApplicationEntry(), GetNumberOfApplications(), LookupApplication(), and LookupApplicationBySaeIDsAndType().
|
private |
The list of key associations.
Definition at line 247 of file qkd-connection-register.h.
Referenced by AddKeyAssociationEntry(), AssignKeyAssociation(), DeleteKeyAssociationLinkEntry(), GetNumberOfKeyAssociations(), LookupKeyAssociationByApplicationId(), LookupKeyAssociationByDestinationNodeId(), LookupKeyAssociationById(), PrintListOfAllKeyAssociations(), SaveKeyAssociation(), and UpdateQKDApplications().