Contact Class Reference
The Contact class holds the data of an address book entry. More...
#include <contact.h>
Inheritance diagram for Contact:


Public Types | |
| enum | journal_action { ACTION_ADD, ACTION_REMOVE, ACTION_REPLACE } |
Public Member Functions | |
| Contact () | |
| Contact (const QMap< int, QString > &fromMap) | |
| virtual | ~Contact () |
| void | setTitle (const QString &v) |
| void | setFirstName (const QString &v) |
| void | setMiddleName (const QString &v) |
| void | setLastName (const QString &v) |
| void | setSuffix (const QString &v) |
| void | setFileAs (const QString &v) |
| void | setFileAs () |
| void | setDefaultEmail (const QString &v) |
| void | insertEmail (const QString &v) |
| void | removeEmail (const QString &v) |
| void | clearEmails () |
| void | insertEmails (const QStringList &v) |
| void | setHomeStreet (const QString &v) |
| void | setHomeCity (const QString &v) |
| void | setHomeState (const QString &v) |
| void | setHomeZip (const QString &v) |
| void | setHomeCountry (const QString &v) |
| void | setHomePhone (const QString &v) |
| void | setHomeFax (const QString &v) |
| void | setHomeMobile (const QString &v) |
| void | setHomeWebpage (const QString &v) |
| void | setCompany (const QString &v) |
| void | setBusinessStreet (const QString &v) |
| void | setBusinessCity (const QString &v) |
| void | setBusinessState (const QString &v) |
| void | setBusinessZip (const QString &v) |
| void | setBusinessCountry (const QString &v) |
| void | setBusinessWebpage (const QString &v) |
| void | setJobTitle (const QString &v) |
| void | setDepartment (const QString &v) |
| void | setOffice (const QString &v) |
| void | setBusinessPhone (const QString &v) |
| void | setBusinessFax (const QString &v) |
| void | setBusinessMobile (const QString &v) |
| void | setBusinessPager (const QString &v) |
| void | setProfession (const QString &v) |
| void | setAssistant (const QString &v) |
| void | setManager (const QString &v) |
| void | setSpouse (const QString &v) |
| void | setGender (const QString &v) |
| void | setBirthday (const QString &v) |
| void | setAnniversary (const QString &v) |
| void | setNickname (const QString &v) |
| void | setChildren (const QString &v) |
| void | setNotes (const QString &v) |
| bool | match (const QString ®exp) const |
| QString | fullName () const |
| QString | title () const |
| QString | firstName () const |
| QString | middleName () const |
| QString | lastName () const |
| QString | suffix () const |
| QString | fileAs () const |
| QString | defaultEmail () const |
| QStringList | emailList () const |
| QString | homeStreet () const |
| QString | homeCity () const |
| QString | homeState () const |
| QString | homeZip () const |
| QString | homeCountry () const |
| QString | homePhone () const |
| QString | homeFax () const |
| QString | homeMobile () const |
| QString | homeWebpage () const |
| QString | displayHomeAddress () const |
| Multi line string containing all non-empty address info in the form Street City, State Zip Country. | |
| QString | company () const |
| QString | businessStreet () const |
| QString | businessCity () const |
| QString | businessState () const |
| QString | businessZip () const |
| QString | businessCountry () const |
| QString | businessWebpage () const |
| QString | jobTitle () const |
| QString | department () const |
| QString | office () const |
| QString | businessPhone () const |
| QString | businessFax () const |
| QString | businessMobile () const |
| QString | businessPager () const |
| QString | profession () const |
| QString | assistant () const |
| QString | manager () const |
| QString | displayBusinessAddress () const |
| Multi line string containing all non-empty address info in the form Street City, State Zip Country. | |
| QString | spouse () const |
| QString | gender () const |
| QString | birthday () const |
| QString | anniversary () const |
| QString | nickname () const |
| QString | children () const |
| QStringList | childrenList () const |
| QString | notes () const |
| QString | groups () const |
| QStringList | groupList () const |
| QString | toRichText () const |
| QMap< int, QString > | toMap () const |
| QString | field (int key) const |
| void | saveJournal (journal_action action, const QString &key=QString::null) |
| void | save (QString &buf) const |
| void | setUid (int i) |
Static Public Member Functions | |
| void | writeVCard (const QString &filename, const QValueList< Contact > &contacts) |
| void | writeVCard (const QString &filename, const Contact &c) |
| QValueList< Contact > | readVCard (const QString &filename) |
| QStringList | fields () |
| QStringList | trfields () |
Friends | |
| class | DataSet |
| class | AbEditor |
| class | AbTable |
| class | AddressBookAccessPrivate |
| class | XMLIO |
Detailed Description
The Contact class holds the data of an address book entry.This data includes information the name of the person, contact information, and business information such as deparment and job title.
Definition at line 36 of file contact.h.
Constructor & Destructor Documentation
|
|
Creates a new, empty contact. Definition at line 53 of file contact.cpp. |
|
|
Destroys a contact. Definition at line 83 of file contact.cpp. |
Member Function Documentation
|
||||||||||||
|
Writes the list of contacts as a set of VCards to the file filename. Definition at line 1324 of file contact.cpp. References QValueList::begin(), QValueList::end(), and QString::utf8(). |
|
||||||||||||
|
writes contact as a VCard to the file filename. Definition at line 1344 of file contact.cpp. References QString::utf8(). |
|
|
Returns the set of contacts read as VCards from the file filename. Definition at line 1362 of file contact.cpp. References QValueList::append(), and QString::utf8(). |
|
|
Sets the title of the contact to str. |
|
|
Sets the first name of the contact to str. |
|
|
Sets the middle name of the contact to str. |
|
|
Sets the last name of the contact to str. |
|
|
Sets the suffix of the contact to str. |
|
|
Sets the contact to filed as str. |
|
|
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. Generates the string for the contact to be filed as from the first, middle and last name of the contact. Definition at line 780 of file contact.cpp. References firstName(), QString::isEmpty(), lastName(), and middleName(). |
|
|
Sets the default email of the contact to str. Definition at line 288 of file contact.h. References insertEmail(), and QString::isEmpty(). Referenced by insertEmail(), and removeEmail(). |
|
|
Insert email into the email list. Ensures email can only be added once. If there is no default email address set, it sets it to the email. Definition at line 234 of file contact.h. References QString::contains(), defaultEmail(), QString::isEmpty(), and setDefaultEmail(). Referenced by insertEmails(), and setDefaultEmail(). |
|
|
Removes the email from the email list. If the default email was email, then the default email address is assigned to the first email in the email list Definition at line 256 of file contact.h. References clearEmails(), QString::contains(), QValueList::count(), defaultEmail(), emailList(), QValueList::first(), QStringList::join(), QValueList::remove(), and setDefaultEmail(). |
|
|
Clears the email list. Definition at line 283 of file contact.h. References QMap< int, QString >::remove(). Referenced by removeEmail(). |
|
|
Appends the emailList to the exiting email list Definition at line 300 of file contact.h. References insertEmail(). |
|
|
Sets the home street address of the contact to str. |
|
|
Sets the home city of the contact to str. |
|
|
Sets the home state of the contact to str. |
|
|
Sets the home zip code of the contact to str. |
|
|
Sets the home country of the contact to str. |
|
|
Sets the home phone number of the contact to str. |
|
|
Sets the home fax number of the contact to str. |
|
|
Sets the home mobile phone number of the contact to str. |
|
|
Sets the home webpage of the contact to str. |
|
|
Sets the company for contact to str. |
|
|
Sets the business street address of the contact to str. |
|
|
Sets the business city of the contact to str. |
|
|
Sets the business state of the contact to str. |
|
|
Sets the business zip code of the contact to str. |
|
|
Sets the business country of the contact to str. |
|
|
Sets the business webpage of the contact to str. |
|
|
Sets the job title of the contact to str. |
|
|
Sets the department for contact to str. |
|
|
Sets the office for contact to str. |
|
|
Sets the business phone number of the contact to str. |
|
|
Sets the business fax number of the contact to str. |
|
|
Sets the business mobile phone number of the contact to str. |
|
|
Sets the business pager number of the contact to str. |
|
|
Sets the profession of the contact to str. |
|
|
Sets the assistant of the contact to str. |
|
|
Sets the manager of the contact to str. |
|
|
Sets the spouse of the contact to str. |
|
|
Sets the gender of the contact to str. |
|
|
Sets the birthday for the contact to str. |
|
|
Sets the anniversary of the contact to str. |
|
|
Sets the nickname of the contact to str. |
|
|
Sets the list of children for the contact to those contained in str. Definition at line 967 of file contact.cpp. |
|
|
Sets the notes about the contact to str. |
|
|
Returns TRUE if the contact matches the regular expression regexp. Otherwise returns FALSE. Definition at line 1386 of file contact.cpp. |
|
|
Returns the full name of the contact Definition at line 692 of file contact.cpp. References firstName(), QString::isEmpty(), lastName(), middleName(), QString::simplifyWhiteSpace(), suffix(), and title(). Referenced by toRichText(). |
|
|
Returns the title of the contact. Definition at line 120 of file contact.h. Referenced by fullName(). |
|
|
Returns the first name of the contact. Definition at line 121 of file contact.h. Referenced by fullName(), and setFileAs(). |
|
|
Returns the middle name of the contact. Definition at line 122 of file contact.h. Referenced by fullName(), and setFileAs(). |
|
|
Returns the last name of the contact. Definition at line 123 of file contact.h. Referenced by fullName(), and setFileAs(). |
|
|
Returns the suffix of the contact. Definition at line 124 of file contact.h. Referenced by fullName(). |
|
|
Returns the string the contact is filed as. |
|
|
Returns the default email address of the contact. Definition at line 128 of file contact.h. Referenced by insertEmail(), and removeEmail(). |
|
|
Returns a list of email addresses belonging to the contact, including the default email address. Definition at line 759 of file contact.cpp. References QString::isEmpty(), and QStringList::split(). Referenced by removeEmail(). |
|
|
Returns the home street address of the contact. Definition at line 132 of file contact.h. Referenced by displayHomeAddress(), and toRichText(). |
|
|
Returns the home city of the contact. Definition at line 133 of file contact.h. Referenced by displayHomeAddress(), and toRichText(). |
|
|
Returns the home state of the contact. Definition at line 134 of file contact.h. Referenced by displayHomeAddress(), and toRichText(). |
|
|
Returns the home zip of the contact. Definition at line 135 of file contact.h. Referenced by displayHomeAddress(), and toRichText(). |
|
|
Returns the home country of the contact. Definition at line 136 of file contact.h. Referenced by displayHomeAddress(), and toRichText(). |
|
|
Returns the home phone number of the contact. Definition at line 137 of file contact.h. Referenced by toRichText(). |
|
|
Returns the home fax number of the contact. Definition at line 138 of file contact.h. Referenced by toRichText(). |
|
|
Returns the home mobile number of the contact. Definition at line 139 of file contact.h. Referenced by toRichText(). |
|
|
Returns the home webpage of the contact. Definition at line 140 of file contact.h. Referenced by toRichText(). |
|
|
Multi line string containing all non-empty address info in the form Street City, State Zip Country.
Definition at line 682 of file contact.cpp. References homeCity(), homeCountry(), homeState(), homeStreet(), and homeZip(). |
|
|
Returns the company for the contact. Definition at line 149 of file contact.h. Referenced by toRichText(). |
|
|
Returns the business street address of the contact. Definition at line 150 of file contact.h. Referenced by displayBusinessAddress(), and toRichText(). |
|
|
Returns the business city of the contact. Definition at line 151 of file contact.h. Referenced by displayBusinessAddress(), and toRichText(). |
|
|
Returns the business state of the contact. Definition at line 152 of file contact.h. Referenced by displayBusinessAddress(), and toRichText(). |
|
|
Returns the business zip of the contact. Definition at line 153 of file contact.h. Referenced by displayBusinessAddress(), and toRichText(). |
|
|
Returns the business country of the contact. Definition at line 154 of file contact.h. Referenced by displayBusinessAddress(), and toRichText(). |
|
|
Returns the business webpage of the contact. Definition at line 155 of file contact.h. Referenced by toRichText(). |
|
|
Returns the job title of the contact. Definition at line 156 of file contact.h. Referenced by toRichText(). |
|
|
Returns the department for the contact. Definition at line 157 of file contact.h. Referenced by toRichText(). |
|
|
Returns the office for the contact. Definition at line 158 of file contact.h. Referenced by toRichText(). |
|
|
Returns the business phone number of the contact. Definition at line 159 of file contact.h. Referenced by toRichText(). |
|
|
Returns the business fax number of the contact. Definition at line 160 of file contact.h. Referenced by toRichText(). |
|
|
Returns the business mobile number of the contact. Definition at line 161 of file contact.h. Referenced by toRichText(). |
|
|
Returns the business pager number of the contact. Definition at line 162 of file contact.h. Referenced by toRichText(). |
|
|
Returns the profession of the contact. Definition at line 163 of file contact.h. Referenced by toRichText(). |
|
|
Returns the assistant of the contact. Definition at line 164 of file contact.h. Referenced by toRichText(). |
|
|
Returns the manager of the contact. Definition at line 165 of file contact.h. Referenced by toRichText(). |
|
|
Multi line string containing all non-empty address info in the form Street City, State Zip Country.
Definition at line 672 of file contact.cpp. References businessCity(), businessCountry(), businessState(), businessStreet(), and businessZip(). |
|
|
Returns the spouse of the contact. Definition at line 174 of file contact.h. Referenced by toRichText(). |
|
|
Returns the gender of the contact. Definition at line 175 of file contact.h. Referenced by toRichText(). |
|
|
Returns the birthday of the contact. Definition at line 176 of file contact.h. Referenced by toRichText(). |
|
|
Returns the anniversary of the contact. Definition at line 177 of file contact.h. Referenced by toRichText(). |
|
|
Returns the nickname of the contact. Definition at line 178 of file contact.h. Referenced by toRichText(). |
|
|
Returns the children of the contact. |
|
|
Returns a list of the names of the children of the contact. Definition at line 727 of file contact.cpp. References QStringList::split(). |
|
|
Returns the notes relating to the the contact. Definition at line 183 of file contact.h. Referenced by toRichText(). |
|
|
Returns a rich text formatted QString representing the contents the contact. Definition at line 449 of file contact.cpp. References anniversary(), assistant(), birthday(), businessCity(), businessCountry(), businessFax(), businessMobile(), businessPager(), businessPhone(), businessState(), businessStreet(), businessWebpage(), businessZip(), company(), QStyleSheet::convertFromPlainText(), department(), fullName(), gender(), homeCity(), homeCountry(), homeFax(), homeMobile(), homePhone(), homeState(), homeStreet(), homeWebpage(), homeZip(), QString::isEmpty(), jobTitle(), manager(), nickname(), notes(), office(), profession(), spouse(), QString::toInt(), and QObject::tr(). |
The documentation for this class was generated from the following files:
