• Skip to content
  • Skip to link menu
Trinity API Reference
  • Trinity API Reference
  • tdewallet
 

tdewallet

  • tdewallet
  • client
tdewallet.cpp
1 /* This file is part of the KDE project
2  *
3  * Copyright (C) 2002-2004 George Staikos <staikos@kde.org>
4  *
5  * This library is free software; you can redistribute it and/or
6  * modify it under the terms of the GNU Library General Public
7  * License as published by the Free Software Foundation; either
8  * version 2 of the License, or (at your option) any later version.
9  *
10  * This library is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13  * Library General Public License for more details.
14  *
15  * You should have received a copy of the GNU Library General Public License
16  * along with this library; see the file COPYING.LIB. If not, write to
17  * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
18  * Boston, MA 02110-1301, USA.
19  */
20 
21 #include "tdewallettypes.h"
22 #include "tdewallet.h"
23 #include <tdeconfig.h>
24 #include <kdebug.h>
25 #include <tdeversion.h>
26 #include <dcopclient.h>
27 #include <dcopref.h>
28 #include <tqpopupmenu.h>
29 #include <tqapplication.h>
30 
31 #include <assert.h>
32 
33 using namespace TDEWallet;
34 
35 
36 const TQString Wallet::LocalWallet() {
37  TDEConfig cfg("tdewalletrc", true);
38  cfg.setGroup("Wallet");
39  if (!cfg.readBoolEntry("Use One Wallet", true)) {
40  TQString tmp = cfg.readEntry("Local Wallet", "localwallet");
41  if (tmp.isEmpty()) {
42  return "localwallet";
43  }
44  return tmp;
45  }
46 
47  TQString tmp = cfg.readEntry("Default Wallet", "kdewallet");
48  if (tmp.isEmpty()) {
49  return "kdewallet";
50  }
51  return tmp;
52 }
53 
54 const TQString Wallet::NetworkWallet() {
55  TDEConfig cfg("tdewalletrc", true);
56  cfg.setGroup("Wallet");
57 
58  TQString tmp = cfg.readEntry("Default Wallet", "kdewallet");
59  if (tmp.isEmpty()) {
60  return "kdewallet";
61  }
62  return tmp;
63 }
64 
65 const TQString Wallet::PasswordFolder() {
66  return "Passwords";
67 }
68 
69 const TQString Wallet::FormDataFolder() {
70  return "Form Data";
71 }
72 
73 
74 
75 Wallet::Wallet(int handle, const TQString& name)
76 : TQObject(0L), DCOPObject(), d(0L), _name(name), _handle(handle) {
77 
78  _dcopRef = new DCOPRef("kded", "tdewalletd");
79 
80  _dcopRef->dcopClient()->setNotifications(true);
81  connect(_dcopRef->dcopClient(),
82  TQ_SIGNAL(applicationRemoved(const TQCString&)),
83  this,
84  TQ_SLOT(slotAppUnregistered(const TQCString&)));
85 
86  connectDCOPSignal(_dcopRef->app(), _dcopRef->obj(), "walletClosed(int)", "slotWalletClosed(int)", false);
87  connectDCOPSignal(_dcopRef->app(), _dcopRef->obj(), "folderListUpdated(TQString)", "slotFolderListUpdated(TQString)", false);
88  connectDCOPSignal(_dcopRef->app(), _dcopRef->obj(), "folderUpdated(TQString, TQString)", "slotFolderUpdated(TQString, TQString)", false);
89  connectDCOPSignal(_dcopRef->app(), _dcopRef->obj(), "applicationDisconnected(TQString, TQCString)", "slotApplicationDisconnected(TQString, TQCString)", false);
90 
91  // Verify that the wallet is still open
92  if (_handle != -1) {
93  DCOPReply r = _dcopRef->call("isOpen", _handle);
94  if (r.isValid()) {
95  bool rc = false;
96  r.get(rc);
97  if (!rc) {
98  _handle = -1;
99  _name = TQString::null;
100  }
101  }
102  }
103 }
104 
105 
106 Wallet::~Wallet() {
107  if (_handle != -1) {
108  _dcopRef->call("close", _handle, false);
109  _handle = -1;
110  _folder = TQString::null;
111  _name = TQString::null;
112  }
113 
114  delete _dcopRef;
115  _dcopRef = 0L;
116 }
117 
118 
119 TQStringList Wallet::walletList() {
120  DCOPReply r = DCOPRef("kded", "tdewalletd").call("wallets");
121  TQStringList rc;
122  if (r.isValid()) {
123  r.get(rc);
124  }
125  return rc;
126 }
127 
128 
129 void Wallet::changePassword(const TQString& name, WId w) {
130  DCOPRef("kded", "tdewalletd").send("changePassword", name, uint(w));
131 }
132 
133 
134 bool Wallet::isEnabled() {
135  DCOPReply r = DCOPRef("kded", "tdewalletd").call("isEnabled");
136  bool rc = false;
137  if (r.isValid()) {
138  r.get(rc);
139  }
140  return rc;
141 }
142 
143 
144 bool Wallet::isOpen(const TQString& name) {
145  DCOPReply r = DCOPRef("kded", "tdewalletd").call("isOpen", name);
146  bool rc = false;
147  if (r.isValid()) {
148  r.get(rc);
149  }
150  return rc;
151 }
152 
153 
154 int Wallet::closeWallet(const TQString& name, bool force) {
155  DCOPReply r = DCOPRef("kded", "tdewalletd").call("close", name, force);
156  int rc = -1;
157  if (r.isValid()) {
158  r.get(rc);
159  }
160  return rc;
161 }
162 
163 
164 int Wallet::deleteWallet(const TQString& name) {
165  DCOPReply r = DCOPRef("kded", "tdewalletd").call("deleteWallet", name);
166  int rc = -1;
167  if (r.isValid()) {
168  r.get(rc);
169  }
170  return rc;
171 }
172 
173 
174 Wallet *Wallet::openWallet(const TQString& name, WId w, OpenType ot) {
175  if (ot == Asynchronous) {
176  Wallet *wallet = new Wallet(-1, name);
177  DCOPRef("kded", "tdewalletd").send("openAsynchronous", name, wallet->objId(), uint(w));
178  return wallet;
179  }
180 
181  // avoid deadlock if the app has some popup open (#65978/#71048)
182  while( TQWidget* widget = tqApp->activePopupWidget())
183  widget->close();
184 
185  bool isPath = ot == Path;
186  DCOPReply r;
187 
188  if (isPath) {
189  r = DCOPRef("kded", "tdewalletd").call("openPath", name, uint(w));
190  } else {
191  r = DCOPRef("kded", "tdewalletd").call("open", name, uint(w));
192  }
193 
194  if (r.isValid()) {
195  int drc = -1;
196  r.get(drc);
197  if (drc != -1) {
198  return new Wallet(drc, name);
199  }
200  }
201 
202  return 0;
203 }
204 
205 
206 bool Wallet::disconnectApplication(const TQString& wallet, const TQCString& app) {
207  DCOPReply r = DCOPRef("kded", "tdewalletd").call("disconnectApplication", wallet, app);
208  bool rc = false;
209  if (r.isValid()) {
210  r.get(rc);
211  }
212  return rc;
213 }
214 
215 
216 TQStringList Wallet::users(const TQString& name) {
217  DCOPReply r = DCOPRef("kded", "tdewalletd").call("users", name);
218  TQStringList drc;
219  if (r.isValid()) {
220  r.get(drc);
221  }
222  return drc;
223 }
224 
225 
226 int Wallet::sync() {
227  if (_handle == -1) {
228  return -1;
229  }
230 
231  _dcopRef->call("sync", _handle);
232  return 0;
233 }
234 
235 
236 int Wallet::lockWallet() {
237  if (_handle == -1) {
238  return -1;
239  }
240 
241  DCOPReply r = _dcopRef->call("close", _handle, true);
242  _handle = -1;
243  _folder = TQString::null;
244  _name = TQString::null;
245  if (r.isValid()) {
246  int drc = -1;
247  r.get(drc);
248  return drc;
249  }
250  return -1;
251 }
252 
253 
254 const TQString& Wallet::walletName() const {
255  return _name;
256 }
257 
258 
259 bool Wallet::isOpen() const {
260  return _handle != -1;
261 }
262 
263 
264 void Wallet::requestChangePassword(WId w) {
265  if (_handle == -1) {
266  return;
267  }
268 
269  _dcopRef->send("changePassword", _name, uint(w));
270 }
271 
272 
273 void Wallet::slotWalletClosed(int handle) {
274  if (_handle == handle) {
275  _handle = -1;
276  _folder = TQString::null;
277  _name = TQString::null;
278  emit walletClosed();
279  }
280 }
281 
282 
283 TQStringList Wallet::folderList() {
284  TQStringList rc;
285 
286  if (_handle == -1) {
287  return rc;
288  }
289 
290  DCOPReply r = _dcopRef->call("folderList", _handle);
291  if (r.isValid()) {
292  r.get(rc);
293  }
294 
295  return rc;
296 }
297 
298 
299 TQStringList Wallet::entryList() {
300  TQStringList rc;
301 
302  if (_handle == -1) {
303  return rc;
304  }
305 
306  DCOPReply r = _dcopRef->call("entryList", _handle, _folder);
307  if (r.isValid()) {
308  r.get(rc);
309  }
310 
311  return rc;
312 }
313 
314 
315 bool Wallet::hasFolder(const TQString& f) {
316  bool rc = false;
317 
318  if (_handle == -1) {
319  return rc;
320  }
321 
322  DCOPReply r = _dcopRef->call("hasFolder", _handle, f);
323  if (r.isValid()) {
324  r.get(rc);
325  }
326 
327  return rc;
328 }
329 
330 
331 bool Wallet::createFolder(const TQString& f) {
332  bool rc = true;
333 
334  if (_handle == -1) {
335  return false;
336  }
337 
338  if (!hasFolder(f)) {
339  DCOPReply r = _dcopRef->call("createFolder", _handle, f);
340  if (r.isValid()) {
341  r.get(rc);
342  }
343  }
344 
345  return rc;
346 }
347 
348 
349 bool Wallet::setFolder(const TQString& f) {
350  bool rc = false;
351 
352  if (_handle == -1) {
353  return rc;
354  }
355 
356  // Don't do this - the folder could have disappeared?
357 #if 0
358  if (f == _folder) {
359  return true;
360  }
361 #endif
362 
363  if (hasFolder(f)) {
364  _folder = f;
365  rc = true;
366  }
367 
368  return rc;
369 }
370 
371 
372 bool Wallet::removeFolder(const TQString& f) {
373  bool rc = false;
374 
375  if (_handle == -1) {
376  return rc;
377  }
378 
379  DCOPReply r = _dcopRef->call("removeFolder", _handle, f);
380  if (r.isValid()) {
381  r.get(rc);
382  }
383 
384  if (_folder == f) {
385  setFolder(TQString::null);
386  }
387 
388  return rc;
389 }
390 
391 
392 const TQString& Wallet::currentFolder() const {
393  return _folder;
394 }
395 
396 
397 int Wallet::readEntry(const TQString& key, TQByteArray& value) {
398  int rc = -1;
399 
400  if (_handle == -1) {
401  return rc;
402  }
403 
404  DCOPReply r = _dcopRef->call("readEntry", _handle, _folder, key);
405  if (r.isValid()) {
406  r.get(value);
407  rc = 0;
408  }
409 
410  return rc;
411 }
412 
413 
414 int Wallet::readEntryList(const TQString& key, TQMap<TQString, TQByteArray>& value) {
415  int rc = -1;
416 
417  if (_handle == -1) {
418  return rc;
419  }
420 
421  DCOPReply r = _dcopRef->call("readEntryList", _handle, _folder, key);
422  if (r.isValid()) {
423  r.get(value);
424  rc = 0;
425  }
426 
427  return rc;
428 }
429 
430 
431 int Wallet::renameEntry(const TQString& oldName, const TQString& newName) {
432  int rc = -1;
433 
434  if (_handle == -1) {
435  return rc;
436  }
437 
438  DCOPReply r = _dcopRef->call("renameEntry", _handle, _folder, oldName, newName);
439  if (r.isValid()) {
440  r.get(rc);
441  }
442 
443  return rc;
444 }
445 
446 
447 int Wallet::readMap(const TQString& key, TQMap<TQString,TQString>& value) {
448  int rc = -1;
449 
450  if (_handle == -1) {
451  return rc;
452  }
453 
454  DCOPReply r = _dcopRef->call("readMap", _handle, _folder, key);
455  if (r.isValid()) {
456  TQByteArray v;
457  r.get(v);
458  if (!v.isEmpty()) {
459  TQDataStream ds(v, IO_ReadOnly);
460  ds >> value;
461  }
462  rc = 0;
463  }
464 
465  return rc;
466 }
467 
468 
469 int Wallet::readMapList(const TQString& key, TQMap<TQString, TQMap<TQString, TQString> >& value) {
470  int rc = -1;
471 
472  if (_handle == -1) {
473  return rc;
474  }
475 
476  DCOPReply r = _dcopRef->call("readMapList", _handle, _folder, key);
477  if (r.isValid()) {
478  TQMap<TQString,TQByteArray> unparsed;
479  r.get(unparsed);
480  for (TQMap<TQString,TQByteArray>::ConstIterator i = unparsed.begin(); i != unparsed.end(); ++i) {
481  if (!i.data().isEmpty()) {
482  TQDataStream ds(i.data(), IO_ReadOnly);
483  TQMap<TQString,TQString> v;
484  ds >> v;
485  value.insert(i.key(), v);
486  }
487  }
488  rc = 0;
489  }
490 
491  return rc;
492 }
493 
494 
495 int Wallet::readPassword(const TQString& key, TQString& value) {
496  int rc = -1;
497 
498  if (_handle == -1) {
499  return rc;
500  }
501 
502  DCOPReply r = _dcopRef->call("readPassword", _handle, _folder, key);
503  if (r.isValid()) {
504  r.get(value);
505  rc = 0;
506  }
507 
508  return rc;
509 }
510 
511 
512 int Wallet::readPasswordList(const TQString& key, TQMap<TQString, TQString>& value) {
513  int rc = -1;
514 
515  if (_handle == -1) {
516  return rc;
517  }
518 
519  DCOPReply r = _dcopRef->call("readPasswordList", _handle, _folder, key);
520  if (r.isValid()) {
521  r.get(value);
522  rc = 0;
523  }
524 
525  return rc;
526 }
527 
528 
529 int Wallet::writeEntry(const TQString& key, const TQByteArray& value, EntryType entryType) {
530  int rc = -1;
531 
532  if (_handle == -1) {
533  return rc;
534  }
535 
536  DCOPReply r = _dcopRef->call("writeEntry", _handle, _folder, key, value, int(entryType));
537  if (r.isValid()) {
538  r.get(rc);
539  }
540 
541  return rc;
542 }
543 
544 
545 int Wallet::writeEntry(const TQString& key, const TQByteArray& value) {
546  int rc = -1;
547 
548  if (_handle == -1) {
549  return rc;
550  }
551 
552  DCOPReply r = _dcopRef->call("writeEntry", _handle, _folder, key, value);
553  if (r.isValid()) {
554  r.get(rc);
555  }
556 
557  return rc;
558 }
559 
560 
561 int Wallet::writeMap(const TQString& key, const TQMap<TQString,TQString>& value) {
562  int rc = -1;
563 
564  if (_handle == -1) {
565  return rc;
566  }
567 
568  TQByteArray a;
569  TQDataStream ds(a, IO_WriteOnly);
570  ds << value;
571  DCOPReply r = _dcopRef->call("writeMap", _handle, _folder, key, a);
572  if (r.isValid()) {
573  r.get(rc);
574  }
575 
576  return rc;
577 }
578 
579 
580 int Wallet::writePassword(const TQString& key, const TQString& value) {
581  int rc = -1;
582 
583  if (_handle == -1) {
584  return rc;
585  }
586 
587  DCOPReply r = _dcopRef->call("writePassword", _handle, _folder, key, value);
588  if (r.isValid()) {
589  r.get(rc);
590  }
591 
592  return rc;
593 }
594 
595 
596 bool Wallet::hasEntry(const TQString& key) {
597  bool rc = false;
598 
599  if (_handle == -1) {
600  return rc;
601  }
602 
603  DCOPReply r = _dcopRef->call("hasEntry", _handle, _folder, key);
604  if (r.isValid()) {
605  r.get(rc);
606  }
607 
608  return rc;
609 }
610 
611 
612 int Wallet::removeEntry(const TQString& key) {
613  int rc = -1;
614 
615  if (_handle == -1) {
616  return rc;
617  }
618 
619  DCOPReply r = _dcopRef->call("removeEntry", _handle, _folder, key);
620  if (r.isValid()) {
621  r.get(rc);
622  }
623 
624  return rc;
625 }
626 
627 
628 Wallet::EntryType Wallet::entryType(const TQString& key) {
629  int rc = 0;
630 
631  if (_handle == -1) {
632  return Wallet::Unknown;
633  }
634 
635  DCOPReply r = _dcopRef->call("entryType", _handle, _folder, key);
636  if (r.isValid()) {
637  r.get(rc);
638  }
639 
640  return static_cast<EntryType>(rc);
641 }
642 
643 
644 void Wallet::slotAppUnregistered(const TQCString& app) {
645  if (_handle >= 0 && app == "kded") {
646  slotWalletClosed(_handle);
647  }
648 }
649 
650 
651 void Wallet::slotFolderUpdated(const TQString& wallet, const TQString& folder) {
652  if (_name == wallet) {
653  emit folderUpdated(folder);
654  }
655 }
656 
657 
658 void Wallet::slotFolderListUpdated(const TQString& wallet) {
659  if (_name == wallet) {
660  emit folderListUpdated();
661  }
662 }
663 
664 
665 void Wallet::slotApplicationDisconnected(const TQString& wallet, const TQCString& application) {
666  if (_handle >= 0
667  && _name == wallet
668  && application == _dcopRef->dcopClient()->appId()) {
669  slotWalletClosed(_handle);
670  }
671 }
672 
673 
674 void Wallet::walletOpenResult(int id) {
675  if (_handle != -1) {
676  // This is BAD.
677  return;
678  }
679 
680  if (id > 0) {
681  _handle = id;
682  emit walletOpened(true);
683  } else if (id < 0) {
684  emit walletOpened(false);
685  } // id == 0 => wait
686 }
687 
688 
689 bool Wallet::folderDoesNotExist(const TQString& wallet, const TQString& folder) {
690 DCOPReply r = DCOPRef("kded", "tdewalletd").call("folderDoesNotExist", wallet, folder);
691 bool rc = true;
692  if (r.isValid()) {
693  r.get(rc);
694  }
695 return rc;
696 }
697 
698 
699 bool Wallet::keyDoesNotExist(const TQString& wallet, const TQString& folder, const TQString& key) {
700 DCOPReply r = DCOPRef("kded", "tdewalletd").call("keyDoesNotExist", wallet, folder, key);
701 bool rc = true;
702  if (r.isValid()) {
703  r.get(rc);
704  }
705 return rc;
706 }
707 
708 
709 void Wallet::virtual_hook(int, void*) {
710  //BASE::virtual_hook( id, data );
711 }
712 
713 #include "tdewallet.moc"
DCOPClient::appId
TQCString appId() const
DCOPClient::setNotifications
void setNotifications(bool enabled)
DCOPObject
DCOPObject::connectDCOPSignal
bool connectDCOPSignal(const TQCString &sender, const TQCString &senderObj, const TQCString &signal, const TQCString &slot, bool Volatile)
DCOPObject::objId
TQCString objId() const
DCOPRef
DCOPRef::dcopClient
DCOPClient * dcopClient() const
DCOPRef::obj
TQCString obj() const
DCOPRef::app
TQCString app() const
DCOPRef::call
DCOPReply call(const TQCString &fun)
DCOPRef::send
bool send(const TQCString &fun)
DCOPReply
DCOPReply::get
bool get(T &t, const char *tname)
DCOPReply::isValid
bool isValid() const
TDEWallet::Wallet
KDE Wallet.
Definition: tdewallet.h:49
TDEWallet::Wallet::readMapList
int readMapList(const TQString &key, TQMap< TQString, TQMap< TQString, TQString > > &value)
Read the map entry key from the current folder.
Definition: tdewallet.cpp:469
TDEWallet::Wallet::Wallet
Wallet(int handle, const TQString &name)
Construct a TDEWallet object.
Definition: tdewallet.cpp:75
TDEWallet::Wallet::walletClosed
void walletClosed()
Emitted when this wallet is closed.
TDEWallet::Wallet::sync
virtual int sync()
This syncs the wallet file on disk with what is in memory.
Definition: tdewallet.cpp:226
TDEWallet::Wallet::lockWallet
virtual int lockWallet()
This closes and locks the current wallet.
Definition: tdewallet.cpp:236
TDEWallet::Wallet::folderListUpdated
void folderListUpdated()
Emitted when the folder list is changed in this wallet.
TDEWallet::Wallet::folderUpdated
void folderUpdated(const TQString &folder)
Emitted when a folder in this wallet is updated.
TDEWallet::Wallet::deleteWallet
static int deleteWallet(const TQString &name)
Delete the wallet name.
Definition: tdewallet.cpp:164
TDEWallet::Wallet::entryType
virtual EntryType entryType(const TQString &key)
Determine the type of the entry key in this folder.
Definition: tdewallet.cpp:628
TDEWallet::Wallet::openWallet
static Wallet * openWallet(const TQString &name, WId w=0, OpenType ot=Synchronous)
Open the wallet name.
Definition: tdewallet.cpp:174
TDEWallet::Wallet::readPasswordList
int readPasswordList(const TQString &key, TQMap< TQString, TQString > &value)
Read the password entry key from the current folder.
Definition: tdewallet.cpp:512
TDEWallet::Wallet::currentFolder
virtual const TQString & currentFolder() const
Determine the current working folder in the wallet.
Definition: tdewallet.cpp:392
TDEWallet::Wallet::~Wallet
virtual ~Wallet()
Destroy a TDEWallet object.
Definition: tdewallet.cpp:106
TDEWallet::Wallet::isOpen
virtual bool isOpen() const
Determine if the current wallet is open, and is a valid wallet handle.
Definition: tdewallet.cpp:259
TDEWallet::Wallet::writeMap
virtual int writeMap(const TQString &key, const TQMap< TQString, TQString > &value)
Write key = value as a map to the current folder.
Definition: tdewallet.cpp:561
TDEWallet::Wallet::keyDoesNotExist
static bool keyDoesNotExist(const TQString &wallet, const TQString &folder, const TQString &key)
Determine if an entry in a folder does not exist in a wallet.
Definition: tdewallet.cpp:699
TDEWallet::Wallet::folderDoesNotExist
static bool folderDoesNotExist(const TQString &wallet, const TQString &folder)
Determine if a folder does not exist in a wallet.
Definition: tdewallet.cpp:689
TDEWallet::Wallet::writeEntry
virtual int writeEntry(const TQString &key, const TQByteArray &value, EntryType entryType)
Write key = value as a binary entry to the current folder.
Definition: tdewallet.cpp:529
TDEWallet::Wallet::folderList
virtual TQStringList folderList()
Obtain the list of all folders contained in the wallet.
Definition: tdewallet.cpp:283
TDEWallet::Wallet::closeWallet
static int closeWallet(const TQString &name, bool force)
Close the wallet name.
Definition: tdewallet.cpp:154
TDEWallet::Wallet::writePassword
virtual int writePassword(const TQString &key, const TQString &value)
Write key = value as a password to the current folder.
Definition: tdewallet.cpp:580
TDEWallet::Wallet::renameEntry
virtual int renameEntry(const TQString &oldName, const TQString &newName)
Rename the entry oldName to newName.
Definition: tdewallet.cpp:431
TDEWallet::Wallet::hasEntry
virtual bool hasEntry(const TQString &key)
Determine if the current folder has they entry key.
Definition: tdewallet.cpp:596
TDEWallet::Wallet::LocalWallet
static const TQString LocalWallet()
The name of the wallet used to store local passwords.
Definition: tdewallet.cpp:36
TDEWallet::Wallet::createFolder
virtual bool createFolder(const TQString &f)
Created the folder f.
Definition: tdewallet.cpp:331
TDEWallet::Wallet::setFolder
virtual bool setFolder(const TQString &f)
Set the current working folder to f.
Definition: tdewallet.cpp:349
TDEWallet::Wallet::disconnectApplication
static bool disconnectApplication(const TQString &wallet, const TQCString &app)
Disconnect the application app from wallet.
Definition: tdewallet.cpp:206
TDEWallet::Wallet::removeEntry
virtual int removeEntry(const TQString &key)
Remove the entry key from the current folder.
Definition: tdewallet.cpp:612
TDEWallet::Wallet::readPassword
virtual int readPassword(const TQString &key, TQString &value)
Read the password entry key from the current folder.
Definition: tdewallet.cpp:495
TDEWallet::Wallet::isEnabled
static bool isEnabled()
Determine if the KDE wallet is enabled.
Definition: tdewallet.cpp:134
TDEWallet::Wallet::PasswordFolder
static const TQString PasswordFolder()
The standardized name of the password folder.
Definition: tdewallet.cpp:65
TDEWallet::Wallet::FormDataFolder
static const TQString FormDataFolder()
The standardized name of the form data folder.
Definition: tdewallet.cpp:69
TDEWallet::Wallet::walletName
virtual const TQString & walletName() const
The name of the current wallet.
Definition: tdewallet.cpp:254
TDEWallet::Wallet::users
static TQStringList users(const TQString &wallet)
List the applications that are using the wallet wallet.
Definition: tdewallet.cpp:216
TDEWallet::Wallet::changePassword
static void changePassword(const TQString &name, WId w=0)
Request to the wallet service to change the password of the wallet name.
Definition: tdewallet.cpp:129
TDEWallet::Wallet::walletList
static TQStringList walletList()
List all the wallets available.
Definition: tdewallet.cpp:119
TDEWallet::Wallet::readMap
virtual int readMap(const TQString &key, TQMap< TQString, TQString > &value)
Read the map entry key from the current folder.
Definition: tdewallet.cpp:447
TDEWallet::Wallet::NetworkWallet
static const TQString NetworkWallet()
The name of the wallet used to store network passwords.
Definition: tdewallet.cpp:54
TDEWallet::Wallet::removeFolder
virtual bool removeFolder(const TQString &f)
Remove the folder f and all its entries from the wallet.
Definition: tdewallet.cpp:372
TDEWallet::Wallet::readEntryList
int readEntryList(const TQString &key, TQMap< TQString, TQByteArray > &value)
Read the entries matching key from the current folder.
Definition: tdewallet.cpp:414
TDEWallet::Wallet::entryList
virtual TQStringList entryList()
Return the list of keys of all entries in this folder.
Definition: tdewallet.cpp:299
TDEWallet::Wallet::hasFolder
virtual bool hasFolder(const TQString &f)
Determine if the folder f exists in the wallet.
Definition: tdewallet.cpp:315
TDEWallet::Wallet::walletOpened
void walletOpened(bool success)
Emitted when a wallet is opened in asynchronous mode.
TDEWallet::Wallet::readEntry
virtual int readEntry(const TQString &key, TQByteArray &value)
Read the entry key from the current folder.
Definition: tdewallet.cpp:397
TDEWallet::Wallet::requestChangePassword
virtual void requestChangePassword(WId w=0)
Request to the wallet service to change the password of the current wallet.
Definition: tdewallet.cpp:264
TDEWallet
Namespace collecting all the Wallet-related classes.
Definition: tdewallet.h:37

tdewallet

Skip menu "tdewallet"
  • Main Page
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Class Members

tdewallet

Skip menu "tdewallet"
  • arts
  • dcop
  • dnssd
  • interfaces
  •   kspeech
  •     interface
  •     library
  •   tdetexteditor
  • kate
  • kded
  • kdoctools
  • kimgio
  • kjs
  • libtdemid
  • libtdescreensaver
  • tdeabc
  • tdecmshell
  • tdecore
  • tdefx
  • tdehtml
  • tdeinit
  • tdeio
  •   bookmarks
  •   httpfilter
  •   kpasswdserver
  •   kssl
  •   tdefile
  •   tdeio
  •   tdeioexec
  • tdeioslave
  •   http
  • tdemdi
  •   tdemdi
  • tdenewstuff
  • tdeparts
  • tdeprint
  • tderandr
  • tderesources
  • tdespell2
  • tdesu
  • tdeui
  • tdeunittest
  • tdeutils
  • tdewallet
Generated for tdewallet by doxygen 1.9.1
This website is maintained by Timothy Pearson.