|
|
This class represents an entry in the address book.
The data of this class is implicitly shared. You can pass this class by value.
If you need the name of a field for presenting it to the user you should use the functions ending in Label(). They return a translated string which can be used as label for the corresponding field.
About the name fields:
givenName() is the first name and familyName() the last name. In some countries the family name comes first, that's the reason for the naming. formattedName() is the full name with the correct formatting. It is used as an override, when the correct formatting can't be generated from the other name fields automatically.
realName() returns a fully formatted name(). It uses formattedName, if set, otherwise it constucts the name from the name fields. As fallback, if nothing else is set it uses name().
name() is the NAME type of RFC2426. It can be used as internal name for the data enty, but shouldn't be used for displaying the data to the user.
typedef QValueList | List |
Addressee ()
| Addressee |
Construct an empty address book entry.
~Addressee ()
| ~Addressee |
Addressee ( const Addressee & )
| Addressee |
Addressee & operator= ( const Addressee & )
| operator= |
bool operator== ( const Addressee & )
| operator== |
[const]
bool operator!= ( const Addressee & )
| operator!= |
[const]
bool isEmpty ()
| isEmpty |
[const]
Return, if the address book entry is empty.
void setUid ( const QString &uid )
| setUid |
Set unique identifier.
QString uid ()
| uid |
[const]
Return unique identifier.
QString uidLabel ()
| uidLabel |
[static]
Return translated label for uid field.
void setName ( const QString &name )
| setName |
Set name.
QString name ()
| name |
[const]
Return name.
QString nameLabel ()
| nameLabel |
[static]
Return translated label for name field.
void setFormattedName ( const QString &formattedName )
| setFormattedName |
Set formatted name.
QString formattedName ()
| formattedName |
[const]
Return formatted name.
QString formattedNameLabel ()
| formattedNameLabel |
[static]
Return translated label for formattedName field.
void setFamilyName ( const QString &familyName )
| setFamilyName |
Set family name.
QString familyName ()
| familyName |
[const]
Return family name.
QString familyNameLabel ()
| familyNameLabel |
[static]
Return translated label for familyName field.
void setGivenName ( const QString &givenName )
| setGivenName |
Set given name.
QString givenName ()
| givenName |
[const]
Return given name.
QString givenNameLabel ()
| givenNameLabel |
[static]
Return translated label for givenName field.
void setAdditionalName ( const QString &additionalName )
| setAdditionalName |
Set additional names.
QString additionalName ()
| additionalName |
[const]
Return additional names.
QString additionalNameLabel ()
| additionalNameLabel |
[static]
Return translated label for additionalName field.
void setPrefix ( const QString &prefix )
| setPrefix |
Set honorific prefixes.
QString prefix ()
| prefix |
[const]
Return honorific prefixes.
QString prefixLabel ()
| prefixLabel |
[static]
Return translated label for prefix field.
void setSuffix ( const QString &suffix )
| setSuffix |
Set honorific suffixes.
QString suffix ()
| suffix |
[const]
Return honorific suffixes.
QString suffixLabel ()
| suffixLabel |
[static]
Return translated label for suffix field.
void setNickName ( const QString &nickName )
| setNickName |
Set nick name.
QString nickName ()
| nickName |
[const]
Return nick name.
QString nickNameLabel ()
| nickNameLabel |
[static]
Return translated label for nickName field.
void setBirthday ( const QDateTime &birthday )
| setBirthday |
Set birthday.
QDateTime birthday ()
| birthday |
[const]
Return birthday.
QString birthdayLabel ()
| birthdayLabel |
[static]
Return translated label for birthday field.
QString homeAddressStreetLabel ()
| homeAddressStreetLabel |
[static]
Return translated label for homeAddressStreet field.
QString homeAddressLocalityLabel ()
| homeAddressLocalityLabel |
[static]
Return translated label for homeAddressLocality field.
QString homeAddressRegionLabel ()
| homeAddressRegionLabel |
[static]
Return translated label for homeAddressRegion field.
QString homeAddressPostalCodeLabel ()
| homeAddressPostalCodeLabel |
[static]
Return translated label for homeAddressPostalCode field.
QString homeAddressCountryLabel ()
| homeAddressCountryLabel |
[static]
Return translated label for homeAddressCountry field.
QString homeAddressLabelLabel ()
| homeAddressLabelLabel |
[static]
Return translated label for homeAddressLabel field.
QString businessAddressStreetLabel ()
| businessAddressStreetLabel |
[static]
Return translated label for businessAddressStreet field.
QString businessAddressLocalityLabel ()
| businessAddressLocalityLabel |
[static]
Return translated label for businessAddressLocality field.
QString businessAddressRegionLabel ()
| businessAddressRegionLabel |
[static]
Return translated label for businessAddressRegion field.
QString businessAddressPostalCodeLabel ()
| businessAddressPostalCodeLabel |
[static]
Return translated label for businessAddressPostalCode field.
QString businessAddressCountryLabel ()
| businessAddressCountryLabel |
[static]
Return translated label for businessAddressCountry field.
QString businessAddressLabelLabel ()
| businessAddressLabelLabel |
[static]
Return translated label for businessAddressLabel field.
QString homePhoneLabel ()
| homePhoneLabel |
[static]
Return translated label for homePhone field.
QString businessPhoneLabel ()
| businessPhoneLabel |
[static]
Return translated label for businessPhone field.
QString mobilePhoneLabel ()
| mobilePhoneLabel |
[static]
Return translated label for mobilePhone field.
QString homeFaxLabel ()
| homeFaxLabel |
[static]
Return translated label for homeFax field.
QString businessFaxLabel ()
| businessFaxLabel |
[static]
Return translated label for businessFax field.
QString carPhoneLabel ()
| carPhoneLabel |
[static]
Return translated label for carPhone field.
QString isdnLabel ()
| isdnLabel |
[static]
Return translated label for isdn field.
QString pagerLabel ()
| pagerLabel |
[static]
Return translated label for pager field.
QString emailLabel ()
| emailLabel |
[static]
Return translated label for email field.
void setMailer ( const QString &mailer )
| setMailer |
Set mail client.
QString mailer ()
| mailer |
[const]
Return mail client.
QString mailerLabel ()
| mailerLabel |
[static]
Return translated label for mailer field.
void setTimeZone ( const TimeZone &timeZone )
| setTimeZone |
Set time zone.
TimeZone timeZone ()
| timeZone |
[const]
Return time zone.
QString timeZoneLabel ()
| timeZoneLabel |
[static]
Return translated label for timeZone field.
void setGeo ( const Geo &geo )
| setGeo |
Set geographic position.
Geo geo ()
| geo |
[const]
Return geographic position.
QString geoLabel ()
| geoLabel |
[static]
Return translated label for geo field.
void setTitle ( const QString &title )
| setTitle |
Set title.
QString title ()
| title |
[const]
Return title.
QString titleLabel ()
| titleLabel |
[static]
Return translated label for title field.
void setRole ( const QString &role )
| setRole |
Set role.
QString role ()
| role |
[const]
Return role.
QString roleLabel ()
| roleLabel |
[static]
Return translated label for role field.
void setOrganization ( const QString &organization )
| setOrganization |
Set organization.
QString organization ()
| organization |
[const]
Return organization.
QString organizationLabel ()
| organizationLabel |
[static]
Return translated label for organization field.
void setNote ( const QString ¬e )
| setNote |
Set note.
QString note ()
| note |
[const]
Return note.
QString noteLabel ()
| noteLabel |
[static]
Return translated label for note field.
void setProductId ( const QString &productId )
| setProductId |
Set product identifier.
QString productId ()
| productId |
[const]
Return product identifier.
QString productIdLabel ()
| productIdLabel |
[static]
Return translated label for productId field.
void setRevision ( const QDateTime &revision )
| setRevision |
Set revision date.
QDateTime revision ()
| revision |
[const]
Return revision date.
QString revisionLabel ()
| revisionLabel |
[static]
Return translated label for revision field.
void setSortString ( const QString &sortString )
| setSortString |
Set sort string.
QString sortString ()
| sortString |
[const]
Return sort string.
QString sortStringLabel ()
| sortStringLabel |
[static]
Return translated label for sortString field.
void setUrl ( const KURL &url )
| setUrl |
Set URL.
KURL url ()
| url |
[const]
Return URL.
QString urlLabel ()
| urlLabel |
[static]
Return translated label for url field.
void setSecrecy ( const Secrecy &secrecy )
| setSecrecy |
Set security class.
Secrecy secrecy ()
| secrecy |
[const]
Return security class.
QString secrecyLabel ()
| secrecyLabel |
[static]
Return translated label for secrecy field.
void setLogo ( const Picture &logo )
| setLogo |
Set logo.
Picture logo ()
| logo |
[const]
Return logo.
QString logoLabel ()
| logoLabel |
[static]
Return translated label for logo field.
void setPhoto ( const Picture &photo )
| setPhoto |
Set photo.
Picture photo ()
| photo |
[const]
Return photo.
QString photoLabel ()
| photoLabel |
[static]
Return translated label for photo field.
void setSound ( const Sound &sound )
| setSound |
Set sound.
Sound sound ()
| sound |
[const]
Return sound.
QString soundLabel ()
| soundLabel |
[static]
Return translated label for sound field.
void setAgent ( const Agent &agent )
| setAgent |
Set agent.
Agent agent ()
| agent |
[const]
Return agent.
QString agentLabel ()
| agentLabel |
[static]
Return translated label for agent field.
void setNameFromString ( const QString & )
| setNameFromString |
Set name fields by parsing the given string and trying to associate the parts of the string with according fields. This function should probably be a bit more clever.
QString realName ()
| realName |
[const]
Return the name of the addressee. This is calculated from all the name fields.
QString assembledName ()
| assembledName |
[const]
Return the name that consists of all name parts.
QString fullEmail ( const QString &email=QString::null )
| fullEmail |
[const]
Return email address including real name.
Parameters:
Email address to be used to construct the full email string. If this is QString::null the preferred email address is used. |
void insertEmail ( const QString &email, bool preferred=false )
| insertEmail |
Insert an email address. If the email address already exists in this addressee it is not duplicated.
Parameters:
Email address | |
preferred | Set to true, if this is the preferred email address of the addressee. |
void removeEmail ( const QString &email )
| removeEmail |
Remove email address. If the email address doesn't exist, nothing happens.
QString preferredEmail ()
| preferredEmail |
[const]
Return preferred email address. This is the first email address or the last one added with isnertEmail() with a set preferred parameter.
QStringList emails ()
| emails |
[const]
Return list of all email addresses.
void insertPhoneNumber ( const PhoneNumber &phoneNumber )
| insertPhoneNumber |
Insert a phone number. If a phoen number with the same id already exists in this addressee it is not duplicated.
void removePhoneNumber ( const PhoneNumber &phoneNumber )
| removePhoneNumber |
Remove phone number. If no phone number with the given id exists for this addresse nothing happens.
PhoneNumber phoneNumber ( int type )
| phoneNumber |
[const]
Return phone number, which matches the given type.
PhoneNumber::List phoneNumbers ()
| phoneNumbers |
[const]
Return list of all phone numbers.
PhoneNumber::List phoneNumbers ( int type )
| phoneNumbers |
[const]
Return list of phone numbers with a special type.
PhoneNumber findPhoneNumber ( const QString &id )
| findPhoneNumber |
[const]
Return phone number with the given id.
void insertKey ( const Key &key )
| insertKey |
Insert a key. If a key with the same id already exists in this addressee it is not duplicated.
void removeKey ( const Key &key )
| removeKey |
Remove a key. If no key with the given id exists for this addresse nothing happens.
Key key ( int type, QString customTypeString = QString::null )
| key |
[const]
Return key, which matches the given type.
If type
== Key::Custom you can specify a string
that should match. If you leave the string empty, the first
key with a custom value is returned.
Key::List keys ()
| keys |
[const]
Return list of all keys.
Key::List keys ( int type, QString customTypeString = QString::null )
| keys |
[const]
Return list of keys with a special type.
If type
== Key::Custom you can specify a string
that should match. If you leave the string empty, all custom
keys will be returned.
Key findKey ( const QString &id )
| findKey |
[const]
Return key with the given id.
void insertAddress ( const Address &address )
| insertAddress |
Insert an address. If an address with the same id already exists in this addressee it is not duplicated.
void removeAddress ( const Address &address )
| removeAddress |
Remove address. If no address with the given id exists for this addresse nothing happens.
Address address ( int type )
| address |
[const]
Return address, which matches the given type.
Address::List addresses ()
| addresses |
[const]
Return list of all addresses.
Address::List addresses ( int type )
| addresses |
[const]
Return list of addresses with a special type.
Address findAddress ( const QString &id )
| findAddress |
[const]
Return address with the given id.
void insertCategory ( const QString & )
| insertCategory |
Insert category. If the category already exists it is not duplicated.
void removeCategory ( const QString & )
| removeCategory |
Remove category.
bool hasCategory ( const QString & )
| hasCategory |
[const]
Return, if addressee has the given category.
void setCategories ( const QStringList & )
| setCategories |
Set categories to given value.
QStringList categories ()
| categories |
[const]
Return list of all set categories.
void insertCustom ( const QString &app, const QString &name,
const QString &value )
| insertCustom |
Insert custom entry. The entry is identified by the name of the inserting application and a unique name. If an entry with the given app and name already exists its value is replaced with the new given value.
void removeCustom ( const QString &app, const QString &name )
| removeCustom |
Remove custom entry.
QString custom ( const QString &app, const QString &name )
| custom |
[const]
Return value of custom entry, identified by app and entry name.
void setCustoms ( const QStringList & )
| setCustoms |
Set all custom entries.
QStringList customs ()
| customs |
[const]
Return list of all custom entries.
void parseEmailAddress ( const QString &rawEmail, QString &fullName,
QString &email )
| parseEmailAddress |
[static]
Parse full email address. The result is given back in fullName and email.
void dump ()
| dump |
[const]
Debug output.
QString asString ()
| asString |
[const]
Returns string representation of the addressee.
void setResource ( Resource *resource )
| setResource |
Set resource where the addressee is from.
Resource * resource ()
| resource |
[const]
Return pointer to resource.
void setChanged ( bool value )
| setChanged |
Mark addressee as changed.
bool changed ()
| changed |
[const]
Return whether the addressee is changed.
Generated by: caleb on tcdevel on Tue Jan 28 12:54:33 2003, using kdoc $. |