KTNEF Library
Go to the documentation of this file.
34 #include <QtCore/QDateTime>
38 using namespace KTnef;
40 class KTNEFProperty::Private
55 const QVariant &name_ )
77 if (
this != &other ) {
86 if ( d->_name.isValid() ) {
87 if ( d->_name.type() == QVariant::String ) {
88 return d->_name.toString();
99 if (
value.type() == QVariant::ByteArray ) {
102 QByteArray arr =
value.toByteArray();
103 bool printable =
true;
104 for (
int i=qMin( arr.size(), 8 )-1; i>=0 && printable; i-- ) {
105 printable = ( isprint( arr[ i ] ) != 0 );
110 int txtCount = beautify ? qMin( arr.size(), 32 ) : arr.size();
111 for ( i=0; i < txtCount; ++i ) {
112 s.append( QString().sprintf(
"%02X", ( uchar )arr[ i ] ) );
117 if ( i < arr.size() ) {
118 s.append(
"... (size=" + QString::number( arr.size() ) +
')' );
125 return value.toString();
155 return d->_value.type() == QVariant::List;
QVariant name() const
Returns the name of the property.
static QString formatValue(const QVariant &v, bool beautify=true)
Creates a formatted string from the value of the property.
QString mapiNamedTagString(int key, int tag)
Convert a keycode to a MAPI named tag string.
int key() const
Returns the integer key of the property.
QString keyString() const
Returns the key string of the property.
KTNEFProperty()
Constructs a TNEF property.
QVariant value() const
Returns the value of the property.
QString mapiTagString(int key)
Convert a keycode to a MAPI tag string.
~KTNEFProperty()
Destroys the property.
int type() const
Returns the integer type of the property.
QString valueString() const
Returns the value string of the property.
bool isVector() const
Determines if the property is a vector type.
Interface for setting MAPI properties.
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Tue Jul 28 2020 00:00:00 by
doxygen 1.8.18 written
by
Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.