#include <partdec.h>
Public Member Functions | |
const char * | c_str () const |
const BDBuffer & | getEncRecord () const |
Get the encrypted password record. | |
const uint8_t * | getName () const |
Get the plain text name of the password record. | |
bool | operator< (const PartDec &pd) const |
const PartDec & | operator= (const PartDec &pd) |
PartDec (const PartDec &pd) | |
PartDec (Record< PasswordRecord > &pr, const Key &key) throw (YAPETException) | |
PartDec (BDBuffer &bd, const Key &key) throw (YAPETException) | |
PartDec () | |
void | setRecord (Record< PasswordRecord > &pr, const Key &key) throw (YAPETException) |
~PartDec () | |
Private Attributes | |
BDBuffer | enc_data |
The encrypted password record. | |
uint8_t | name [NAME_SIZE] |
The record name in plain text. |
The File
class uses this class when reading and returning the records stored in a file. It also expects a list of PartDec
object when writing password records to the file.
The encrypted data is also attached to this class as a BDBuffer
.
Definition at line 55 of file partdec.h.
PartDec::PartDec | ( | ) |
PartDec::PartDec | ( | BDBuffer & | bd, | |
const Key & | key | |||
) | throw (YAPETException) |
Definition at line 34 of file partdec.cc.
References YAPET::Crypt::decrypt(), name, and YAPET::NAME_SIZE.
PartDec::PartDec | ( | Record< PasswordRecord > & | pr, | |
const Key & | key | |||
) | throw (YAPETException) |
PartDec::PartDec | ( | const PartDec & | pd | ) |
PartDec::~PartDec | ( | ) |
const char* YAPET::PartDec::c_str | ( | ) | const [inline] |
This method has been added because YAPETUI::ListWidget
expects the object assigned to the list being displayed to have a public method called c_str()
.
Get the plain text name of the password record.
Returns the pointer to the plain text name of the password record.
Definition at line 113 of file partdec.h.
References name.
const BDBuffer& YAPET::PartDec::getEncRecord | ( | ) | const [inline] |
Gets the encrypted password record associated with this object.
BDBuffer
holding the encrypted data. Definition at line 94 of file partdec.h.
References enc_data.
Referenced by PasswordRecord::refresh().
const uint8_t* YAPET::PartDec::getName | ( | ) | const [inline] |
bool PartDec::operator< | ( | const PartDec & | pd | ) | const |
This is mainly used for sorting the entries...
Definition at line 85 of file partdec.cc.
References name.
void PartDec::setRecord | ( | Record< PasswordRecord > & | pr, | |
const Key & | key | |||
) | throw (YAPETException) |
Definition at line 58 of file partdec.cc.
References enc_data, YAPET::Crypt::encrypt(), YAPET::PasswordRecord::name, name, and YAPET::NAME_SIZE.
Referenced by PartDec().
BDBuffer YAPET::PartDec::enc_data [private] |
This is the encrypted password record.
Definition at line 68 of file partdec.h.
Referenced by getEncRecord(), operator=(), and setRecord().
uint8_t YAPET::PartDec::name[NAME_SIZE] [private] |
The password record name in plain text.
Definition at line 62 of file partdec.h.
Referenced by c_str(), getName(), operator<(), operator=(), PartDec(), setRecord(), and ~PartDec().