home *** CD-ROM | disk | FTP | other *** search
/ Personal Computer World 2009 February / PCWFEB09.iso / Software / Linux / SLAX 6.0.8 / slax-6.0.8.iso / slax / base / 006-devel.lzm / usr / include / ktnef / ktnefproperty.h < prev    next >
Encoding:
C/C++ Source or Header  |  2005-09-10  |  1.5 KB  |  64 lines

  1. /*
  2.     ktnefproperty.h
  3.  
  4.     Copyright (C) 2002 Michael Goffioul <kdeprint@swing.be>
  5.  
  6.     This file is part of KTNEF, the KDE TNEF support library/program.
  7.  
  8.     This program is free software; you can redistribute it and/or modify
  9.     it under the terms of the GNU General Public License as published by
  10.     the Free Software Foundation; either version 2 of the License, or
  11.     (at your option) any later version.
  12.  
  13.     You should have received a copy of the GNU General Public License
  14.     along with this program; if not, write to the Free Software Foundation,
  15.     Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
  16.  */
  17.  
  18. #ifndef KTNEFPROPERTY_H
  19. #define KTNEFPROPERTY_H
  20.  
  21. #include <qvariant.h>
  22. #include <qstring.h>
  23. #include <kdepimmacros.h>
  24.  
  25. class KDE_EXPORT KTNEFProperty
  26. {
  27. public:
  28.     enum MAPIType
  29.     {
  30.         UInt16  = 0x0002,
  31.         ULong   = 0x0003,
  32.         Float   = 0x0004,
  33.         Double  = 0x0005,
  34.         Boolean = 0x000B,
  35.         Object  = 0x000D,
  36.         Time    = 0x0040,
  37.         String8 = 0x001E,
  38.         UString = 0x001F,
  39.         Binary  = 0x0102
  40.     };
  41.  
  42.     KTNEFProperty();
  43.     KTNEFProperty( int key_, int type_, const QVariant& value_, const QVariant& name_ = QVariant() );
  44.     KTNEFProperty( const KTNEFProperty& p );
  45.  
  46.     QString keyString();
  47.     QString valueString();
  48.     static QString formatValue( const QVariant& v, bool beautify=true );
  49.  
  50.     int key() const;
  51.     int type() const;
  52.     QVariant value() const;
  53.     QVariant name() const;
  54.     bool isVector() const;
  55.  
  56. private:
  57.     int _key;
  58.     int _type;
  59.     QVariant _value;
  60.     QVariant _name;
  61. };
  62.  
  63. #endif /* KTNEFPROPERTY_H */
  64.