KABC::Field Class ReferenceList of all members.
Detailed Description
Definition at line 33 of file field.h.
|
Public Types |
enum | FieldCategory {
All = 0x0,
Frequent = 0x01,
Address = 0x02,
Email = 0x04,
Personal = 0x08,
Organization = 0x10,
CustomCategory = 0x20
} |
typedef QValueList< Field * > | List |
Public Member Functions |
virtual QString | label () |
virtual int | category () |
virtual QString | value (const KABC::Addressee &) |
virtual bool | setValue (KABC::Addressee &, const QString &) |
QString | sortKey (const KABC::Addressee &) |
virtual bool | isCustom () |
virtual bool | equals (Field *field) |
Static Public Member Functions |
static QString | categoryLabel (int category) |
static Field::List | allFields () |
static Field::List | defaultFields () |
static Field * | createCustomField (const QString &label, int category, const QString &key, const QString &app) |
static void | deleteFields () |
static void | saveFields (KConfig *cfg, const QString &identifier, const Field::List &fields) |
static void | saveFields (const QString &identifier, const Field::List &fields) |
static Field::List | restoreFields (KConfig *cfg, const QString &identifier) |
static Field::List | restoreFields (const QString &identifier) |
Static Protected Member Functions |
static void | createField (int id, int category=0) |
static void | createDefaultField (int id, int category=0) |
Friends |
class | FieldImpl |
Member Enumeration Documentation
Frequent -
Address -
Email -
Personal -
Organization -
CustomCategory -
Definition at line 50 of file field.h.
Member Function Documentation
Returns the translated label for this field.
Definition at line 112 of file field.cpp.
int Field::category |
( |
|
) |
[virtual] |
Returns the ored categories the field belongs to.
Definition at line 192 of file field.cpp.
QString Field::categoryLabel |
( |
int |
category |
) |
[static] |
Returns the translated label for field category.
Definition at line 197 of file field.cpp.
Returns a string representation of the value the field has in the given Addressee.
Returns QString::null, if it is not possible to convert the value to a string.
Definition at line 219 of file field.cpp.
Sets the value of the field in the given Addressee.
Returns true on success or false, if the given string couldn't be converted to a valid value.
Definition at line 338 of file field.cpp.
Returns a string, that can be used for sorting.
Definition at line 386 of file field.cpp.
bool Field::isCustom |
( |
|
) |
[virtual] |
Returns, if the field is a user-defined field.
Definition at line 426 of file field.cpp.
bool Field::equals |
( |
Field * |
field |
) |
[virtual] |
Returns, if the field is equal with field.
Definition at line 578 of file field.cpp.
Returns a list of all fields.
Definition at line 431 of file field.cpp.
Returns a list of the default fields.
Definition at line 474 of file field.cpp.
Creates a custom field.
- Parameters:
-
| label | The label for this field |
| category | The category of this field |
| key | Unique key for this field |
| app | Unique app name for this field |
Definition at line 589 of file field.cpp.
void Field::deleteFields |
( |
|
) |
[static] |
Delete all fields from list.
Definition at line 494 of file field.cpp.
Save the field settings to a config file.
- Parameters:
-
| cfg | The config file object |
| identifier | The unique identifier |
| fields | The list of the fields |
Definition at line 523 of file field.cpp.
void Field::saveFields |
( |
const QString & |
identifier, |
|
|
const Field::List & |
fields | |
|
) |
| | [static] |
This is the same as above, with the difference, that the list is stored in KGlobal::config() in group "KABCFields".
Definition at line 514 of file field.cpp.
Load the field settings from a config file.
- Parameters:
-
| cfg | The config file object |
| identifier | The unique identifier |
Definition at line 553 of file field.cpp.
This is the same as above, with the difference, that the list is loaded from KGlobal::config() from group "KABCFields".
Definition at line 545 of file field.cpp.
The documentation for this class was generated from the following files:
|