ndn::security::pib::CertificateContainer Class Reference

Container of certificates of a key. More...

#include <ndn-cxx/security/pib/certificate-container.hpp>

+ Inheritance diagram for ndn::security::pib::CertificateContainer:
+ Collaboration diagram for ndn::security::pib::CertificateContainer:

Classes

class  const_iterator
 

Public Types

typedef const_iterator iterator
 

Public Member Functions

void add (const v2::Certificate &certificate)
 Add certificate into the container. More...
 
const_iterator begin () const
 
const_iterator end () const
 
const_iterator find (const Name &certName) const
 
v2::Certificate get (const Name &certName) const
 Get a certificate with certName from the container. More...
 
bool isConsistent () const
 Check if the container is consistent with the backend storage. More...
 
void remove (const Name &certName)
 Remove a certificate with certName from the container. More...
 
size_t size () const
 

Friends

class detail::KeyImpl
 

Detailed Description

Container of certificates of a key.

The container is used to search/enumerate certificates of a key. The container can be created only by detail::KeyImpl.

Definition at line 47 of file certificate-container.hpp.

Member Typedef Documentation

Member Function Documentation

void ndn::security::pib::CertificateContainer::add ( const v2::Certificate certificate)

Add certificate into the container.

Exceptions
std::invalid_argumentthe name of certificate does not match the key name

Definition at line 116 of file certificate-container.cpp.

CertificateContainer::const_iterator ndn::security::pib::CertificateContainer::begin ( ) const

Definition at line 92 of file certificate-container.cpp.

CertificateContainer::const_iterator ndn::security::pib::CertificateContainer::end ( ) const

Definition at line 98 of file certificate-container.cpp.

CertificateContainer::const_iterator ndn::security::pib::CertificateContainer::find ( const Name certName) const

Definition at line 104 of file certificate-container.cpp.

v2::Certificate ndn::security::pib::CertificateContainer::get ( const Name certName) const

Get a certificate with certName from the container.

Exceptions
std::invalid_argumentcertName does not match the key name
Pib::Errorthe certificate does not exist

Definition at line 143 of file certificate-container.cpp.

bool ndn::security::pib::CertificateContainer::isConsistent ( ) const

Check if the container is consistent with the backend storage.

Note
this method is heavyweight and should be used in debugging mode only.

Definition at line 161 of file certificate-container.cpp.

void ndn::security::pib::CertificateContainer::remove ( const Name certName)

Remove a certificate with certName from the container.

Exceptions
std::invalid_argumentcertName does not match the key name

Definition at line 129 of file certificate-container.cpp.

size_t ndn::security::pib::CertificateContainer::size ( ) const

Definition at line 110 of file certificate-container.cpp.

Friends And Related Function Documentation

friend class detail::KeyImpl
friend

Definition at line 157 of file certificate-container.hpp.