kabc Library API Documentation

vcardformatimpl.h

00001 /* 00002 This file is part of libkabc. 00003 Copyright (c) 2001 Cornelius Schumacher <schumacher@kde.org> 00004 00005 This library is free software; you can redistribute it and/or 00006 modify it under the terms of the GNU Library General Public 00007 License as published by the Free Software Foundation; either 00008 version 2 of the License, or (at your option) any later version. 00009 00010 This library is distributed in the hope that it will be useful, 00011 but WITHOUT ANY WARRANTY; without even the implied warranty of 00012 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00013 Library General Public License for more details. 00014 00015 You should have received a copy of the GNU Library General Public License 00016 along with this library; see the file COPYING.LIB. If not, write to 00017 the Free Software Foundation, Inc., 59 Temple Place - Suite 330, 00018 Boston, MA 02111-1307, USA. 00019 */ 00020 00021 #ifndef KABC_VCARDFORMATIMPL_H 00022 #define KABC_VCARDFORMATIMPL_H 00023 00024 #include <qstring.h> 00025 #include <qfile.h> 00026 00027 #include "address.h" 00028 #include "addressee.h" 00029 00030 #include <VCard.h> 00031 00032 namespace KABC { 00033 00034 class AddressBook; 00035 00039 class KDE_DEPRECATED VCardFormatImpl 00040 { 00041 public: 00042 bool load( Addressee &, QFile *file ); 00043 bool loadAll( AddressBook *, Resource *, QFile *file ); 00044 void save( const Addressee &, QFile *file ); 00045 void saveAll( AddressBook *, Resource *, QFile *file ); 00046 00047 bool readFromString( const QString &vcard, Addressee &addr ); 00048 bool writeToString( const Addressee &addressee, QString &vcard ); 00049 00050 protected: 00051 bool loadAddressee( Addressee &, VCARD::VCard & ); 00052 void saveAddressee( const Addressee &, VCARD::VCard *, bool intern ); 00053 00054 void addTextValue (VCARD::VCard *, VCARD::EntityType, const QString & ); 00055 QString readTextValue( VCARD::ContentLine * ); 00056 00057 void addDateValue( VCARD::VCard *, VCARD::EntityType, const QDate & ); 00058 QDate readDateValue( VCARD::ContentLine * ); 00059 00060 void addDateTimeValue( VCARD::VCard *, VCARD::EntityType, const QDateTime & ); 00061 QDateTime readDateTimeValue( VCARD::ContentLine * ); 00062 00063 void addAddressValue( VCARD::VCard *, const Address & ); 00064 Address readAddressValue( VCARD::ContentLine * ); 00065 00066 void addLabelValue( VCARD::VCard *, const Address & ); 00067 00068 void addTelephoneValue( VCARD::VCard *, const PhoneNumber & ); 00069 PhoneNumber readTelephoneValue( VCARD::ContentLine * ); 00070 00071 void addNValue( VCARD::VCard *, const Addressee & ); 00072 void readNValue( VCARD::ContentLine *, Addressee & ); 00073 00074 void addCustomValue( VCARD::VCard *, const QString & ); 00075 00076 void addAddressParam( VCARD::ContentLine *, int ); 00077 int readAddressParam( VCARD::ContentLine * ); 00078 00079 void addGeoValue( VCARD::VCard *, const Geo & ); 00080 Geo readGeoValue( VCARD::ContentLine * ); 00081 00082 void addUTCValue( VCARD::VCard *, const TimeZone & ); 00083 TimeZone readUTCValue( VCARD::ContentLine * ); 00084 00085 void addClassValue( VCARD::VCard *, const Secrecy & ); 00086 Secrecy readClassValue( VCARD::ContentLine * ); 00087 00088 void addKeyValue( VCARD::VCard *, const Key & ); 00089 Key readKeyValue( VCARD::ContentLine * ); 00090 00091 void addPictureValue( VCARD::VCard *, VCARD::EntityType, const Picture &, const Addressee &, bool ); 00092 Picture readPictureValue( VCARD::ContentLine *, VCARD::EntityType, const Addressee &addr ); 00093 00094 void addSoundValue( VCARD::VCard *, const Sound &, const Addressee &, bool ); 00095 Sound readSoundValue( VCARD::ContentLine *, const Addressee &addr ); 00096 00097 void addAgentValue( VCARD::VCard *, const Agent & ); 00098 Agent readAgentValue( VCARD::ContentLine * ); 00099 }; 00100 00101 } 00102 #endif
KDE Logo
This file is part of the documentation for kabc Library Version 3.3.1.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Sun Oct 17 11:33:01 2004 by doxygen 1.3.8 written by Dimitri van Heesch, © 1997-2003