X-Git-Url: http://Server1/repobrowser/?a=blobdiff_plain;f=source%2Fcontacteditor%2FContactDataObject.h;h=6a9d90fa35be9d4fd81cab316de87a171d5e2f1c;hb=64e5af606c4f78b992c820414044a6ad8fef29f2;hp=050bd530b069c7ca28e0046b94d64e672993144c;hpb=d0aff1878b93bd25d923176e4e18829b7040da1c;p=xestiaab%2F.git diff --git a/source/contacteditor/ContactDataObject.h b/source/contacteditor/ContactDataObject.h index 050bd53..6a9d90f 100644 --- a/source/contacteditor/ContactDataObject.h +++ b/source/contacteditor/ContactDataObject.h @@ -25,6 +25,7 @@ #include #include "../vcard/vcard.h" +#include "../common/textprocessing.h" enum ContactLoadStatus{ CONTACTLOAD_UNITTESTFAIL = -1, @@ -35,10 +36,26 @@ enum ContactLoadStatus{ CONTACTLOAD_FILEBASESPECFAIL }; +enum ContactKindType{ + CONTACTKIND_NONE, + CONTACTKIND_INDIVIDUAL, + CONTACTKIND_GROUP, + CONTACTKIND_ORGANISATION, + CONTACTKIND_LOCATION +}; + +enum PropertyType{ + PROPERTY_NONE, + PROPERTY_HOME, + PROPERTY_WORK +}; + class ContactDataObject{ public: + ContactKindType ContactKind = CONTACTKIND_NONE; + /* Items on General Tab */ wxString NameTitle; @@ -457,6 +474,7 @@ class ContactDataObject{ std::map GroupsListAltID; std::map GroupsListPID; std::map GroupsListType; + std::map GroupsListMediaType; std::map GroupsListTokens; std::map GroupsListPref; @@ -546,7 +564,29 @@ class ContactDataObject{ // Subroutines. ContactLoadStatus LoadFile(wxString Filename); + void ProcessKind(wxString KindData); + void ProcessMember(wxString PropertySeg1, wxString PropertySeg2, int *GroupCount); + void ProcessFN(wxString PropertySeg1, wxString PropertySeg2, int *FNCount); + void ProcessN(wxString PropertySeg1, wxString PropertySeg2); + void ProcessNickname(wxString PropertySeg1, wxString PropertySeg2, int *NicknameCount); + void ProcessGender(wxString PropertySeg1, wxString PropertySeg2); + void ProcessBirthday(wxString PropertySeg1, wxString PropertySeg2); + void ProcessAnniversary(wxString PropertySeg1, wxString PropertySeg2); + void ProcessTimeZone(wxString PropertySeg1, wxString PropertySeg2, int *TimeZoneCount); + void ProcessAddress(wxString PropertySeg1, wxString PropertySeg2, int *AddressCount); + void ProcessEmail(wxString PropertySeg1, wxString PropertySeg2, int *EmailCount); }; +void SplitValues(wxString *PropertyLine, + std::map *SplitPoints, + std::map *SplitLength, + int intSize); + +void CheckType(wxString *PropertySeg1, + std::map *SplitPoints, + std::map *SplitLength, + int *intPrevValue, + PropertyType *intType); + #endif \ No newline at end of file