Qt model of the address book in the core.  
 More...
#include <addresstablemodel.h>
 | 
| void  | updateEntry (const QString &address, const QString &label, bool isMine, const QString &purpose, int status) | 
|   | 
 | 
|   | AddressTableModel (WalletModel *parent=0) | 
|   | 
|   | ~AddressTableModel () | 
|   | 
| QString  | addRow (const QString &type, const QString &label, const QString &address, const OutputType address_type) | 
|   | 
| QString  | labelForAddress (const QString &address) const | 
|   | Look up label for address in address book, if not found return empty string.  More...
  | 
|   | 
| QString  | purposeForAddress (const QString &address) const | 
|   | Look up purpose for address in address book, if not found return empty string.  More...
  | 
|   | 
| int  | lookupAddress (const QString &address) const | 
|   | 
| EditStatus  | getEditStatus () const | 
|   | 
| OutputType  | GetDefaultAddressType () const | 
|   | 
 | 
| int  | rowCount (const QModelIndex &parent) const | 
|   | 
| int  | columnCount (const QModelIndex &parent) const | 
|   | 
| QVariant  | data (const QModelIndex &index, int role) const | 
|   | 
| bool  | setData (const QModelIndex &index, const QVariant &value, int role) | 
|   | 
| QVariant  | headerData (int section, Qt::Orientation orientation, int role) const | 
|   | 
| QModelIndex  | index (int row, int column, const QModelIndex &parent) const | 
|   | 
| bool  | removeRows (int row, int count, const QModelIndex &parent=QModelIndex()) | 
|   | 
| Qt::ItemFlags  | flags (const QModelIndex &index) const | 
|   | 
 | 
| static const QString  | Send = "S" | 
|   | Specifies send address.  More...
  | 
|   | 
| static const QString  | Receive = "R" | 
|   | Specifies receive address.  More...
  | 
|   | 
Qt model of the address book in the core. 
This allows views to access and modify the address book. 
Definition at line 23 of file addresstablemodel.h.
 
◆ ColumnIndex
| Enumerator | 
|---|
| Label  | User specified label.  
 | 
| Address  | BSHA3 address.  
 | 
Definition at line 31 of file addresstablemodel.h.
 
 
◆ EditStatus
Return status of edit/insert operation. 
| Enumerator | 
|---|
| OK  | Everything ok.  
 | 
| NO_CHANGES  | No changes were made during edit operation.  
 | 
| INVALID_ADDRESS  | Unparseable address.  
 | 
| DUPLICATE_ADDRESS  | Address already in address book.  
 | 
| WALLET_UNLOCK_FAILURE  | Wallet could not be unlocked to create new receiving address.  
 | 
| KEY_GENERATION_FAILURE  | Generating a new public key for a receiving address failed.  
 | 
Definition at line 41 of file addresstablemodel.h.
 
 
◆ RoleIndex
◆ AddressTableModel()
  
  
      
        
          | AddressTableModel::AddressTableModel  | 
          ( | 
          WalletModel *  | 
          parent = 0 | ) | 
           | 
         
       
   | 
  
explicit   | 
  
 
 
◆ ~AddressTableModel()
      
        
          | AddressTableModel::~AddressTableModel  | 
          ( | 
           | ) | 
           | 
        
      
 
 
◆ addRow()
      
        
          | QString AddressTableModel::addRow  | 
          ( | 
          const QString &  | 
          type,  | 
        
        
           | 
           | 
          const QString &  | 
          label,  | 
        
        
           | 
           | 
          const QString &  | 
          address,  | 
        
        
           | 
           | 
          const OutputType  | 
          address_type  | 
        
        
           | 
          ) | 
           |  | 
        
      
 
 
◆ columnCount()
      
        
          | int AddressTableModel::columnCount  | 
          ( | 
          const QModelIndex &  | 
          parent | ) | 
           const | 
        
      
 
 
◆ data()
      
        
          | QVariant AddressTableModel::data  | 
          ( | 
          const QModelIndex &  | 
          index,  | 
        
        
           | 
           | 
          int  | 
          role  | 
        
        
           | 
          ) | 
           |  const | 
        
      
 
 
◆ emitDataChanged()
  
  
      
        
          | void AddressTableModel::emitDataChanged  | 
          ( | 
          int  | 
          index | ) | 
           | 
         
       
   | 
  
private   | 
  
 
 
◆ flags()
      
        
          | Qt::ItemFlags AddressTableModel::flags  | 
          ( | 
          const QModelIndex &  | 
          index | ) | 
           const | 
        
      
 
 
◆ getAddressData()
  
  
      
        
          | bool AddressTableModel::getAddressData  | 
          ( | 
          const QString &  | 
          address,  | 
         
        
           | 
           | 
          std::string *  | 
          name,  | 
         
        
           | 
           | 
          std::string *  | 
          purpose  | 
         
        
           | 
          ) | 
           |  const | 
         
       
   | 
  
private   | 
  
 
 
◆ GetDefaultAddressType()
      
        
          | OutputType AddressTableModel::GetDefaultAddressType  | 
          ( | 
           | ) | 
           const | 
        
      
 
 
◆ getEditStatus()
  
  
      
        
          | EditStatus AddressTableModel::getEditStatus  | 
          ( | 
           | ) | 
           const | 
         
       
   | 
  
inline   | 
  
 
 
◆ headerData()
      
        
          | QVariant AddressTableModel::headerData  | 
          ( | 
          int  | 
          section,  | 
        
        
           | 
           | 
          Qt::Orientation  | 
          orientation,  | 
        
        
           | 
           | 
          int  | 
          role  | 
        
        
           | 
          ) | 
           |  const | 
        
      
 
 
◆ index()
      
        
          | QModelIndex AddressTableModel::index  | 
          ( | 
          int  | 
          row,  | 
        
        
           | 
           | 
          int  | 
          column,  | 
        
        
           | 
           | 
          const QModelIndex &  | 
          parent  | 
        
        
           | 
          ) | 
           |  const | 
        
      
 
 
◆ labelForAddress()
      
        
          | QString AddressTableModel::labelForAddress  | 
          ( | 
          const QString &  | 
          address | ) | 
           const | 
        
      
 
Look up label for address in address book, if not found return empty string. 
Definition at line 410 of file addresstablemodel.cpp.
 
 
◆ lookupAddress()
      
        
          | int AddressTableModel::lookupAddress  | 
          ( | 
          const QString &  | 
          address | ) | 
           const | 
        
      
 
 
◆ purposeForAddress()
      
        
          | QString AddressTableModel::purposeForAddress  | 
          ( | 
          const QString &  | 
          address | ) | 
           const | 
        
      
 
Look up purpose for address in address book, if not found return empty string. 
Definition at line 419 of file addresstablemodel.cpp.
 
 
◆ removeRows()
      
        
          | bool AddressTableModel::removeRows  | 
          ( | 
          int  | 
          row,  | 
        
        
           | 
           | 
          int  | 
          count,  | 
        
        
           | 
           | 
          const QModelIndex &  | 
          parent = QModelIndex()  | 
        
        
           | 
          ) | 
           |  | 
        
      
 
 
◆ rowCount()
      
        
          | int AddressTableModel::rowCount  | 
          ( | 
          const QModelIndex &  | 
          parent | ) | 
           const | 
        
      
 
 
◆ setData()
      
        
          | bool AddressTableModel::setData  | 
          ( | 
          const QModelIndex &  | 
          index,  | 
        
        
           | 
           | 
          const QVariant &  | 
          value,  | 
        
        
           | 
           | 
          int  | 
          role  | 
        
        
           | 
          ) | 
           |  | 
        
      
 
 
◆ updateEntry
  
  
      
        
          | void AddressTableModel::updateEntry  | 
          ( | 
          const QString &  | 
          address,  | 
         
        
           | 
           | 
          const QString &  | 
          label,  | 
         
        
           | 
           | 
          bool  | 
          isMine,  | 
         
        
           | 
           | 
          const QString &  | 
          purpose,  | 
         
        
           | 
           | 
          int  | 
          status  | 
         
        
           | 
          ) | 
           |  | 
         
       
   | 
  
slot   | 
  
 
 
◆ AddressTablePriv
◆ columns
  
  
      
        
          | QStringList AddressTableModel::columns | 
         
       
   | 
  
private   | 
  
 
 
◆ editStatus
◆ priv
◆ Receive
  
  
      
        
          | const QString AddressTableModel::Receive = "R" | 
         
       
   | 
  
static   | 
  
 
 
◆ Send
  
  
      
        
          | const QString AddressTableModel::Send = "S" | 
         
       
   | 
  
static   | 
  
 
 
◆ walletModel
The documentation for this class was generated from the following files: