QVariant

#include <QtCore/QVariant>

More information will be added here shortly. For now, you'll find more extensive information about this class in the Qt reference for QVariant


Overview

Public Types Index

PrivateDataPtr
bool(*f_canConvert
void(*f_clear
bool(*f_compare
void(*f_construct
bool(*f_convert
void(*f_debugStream
void(*f_load
bool(*f_null
void(*f_save

enum Type

Invalid 0, Bool 1, Int 2, UInt 3, LongLong 4, ULongLong 5, Double 6, Char 7, Map 8, List 9, String 10, StringList 11, ByteArray 12, BitArray 13, Date 14, Time 15, DateTime 16, Url 17, Locale 18, Rect 19, RectF 20, Size 21, SizeF 22, Line 23, LineF 24, Point 25, PointF 26, RegExp 27, Hash 28, EasingCurve 29, LastCoreType EasingCurve, Font 64, Pixmap 65, Brush 66, Color 67, Palette 68, Icon 69, Image 70, Polygon 71, Region 72, Bitmap 73, Cursor 74, SizePolicy 75, KeySequence 76, Pen 77, TextLength 78, TextFormat 79, Matrix 80, Transform 81, Matrix4x4 82, Vector2D 83, Vector3D 84, Vector4D 85, Quaternion 86, LastGuiType Quaternion, UserType 127, LastType 0xffffffff

Protected Attributes Index

Privated

Public Functions Index

QVariant ()
QVariant (Type type)
QVariant (int typeOrUserType, const void *copy)
QVariant (int typeOrUserType, const void *copy, uint flags)
QVariant (const QVariant &other)
QVariant (QDataStream &s)
QVariant (int i)
QVariant (uint ui)
QVariant (qlonglong ll)
QVariant (qulonglong ull)
QVariant (bool b)
QVariant (double d)
QVariant (float f)
QT_ASCII_CAST_WARN_CONSTRUCTORQVariant (const char *str)
QVariant (const QByteArray &bytearray)
QVariant (const QBitArray &bitarray)
QVariant (const QString &string)
QVariant (const QLatin1String &string)
QVariant (const QStringList &stringlist)
QVariant (const QChar &qchar)
QVariant (const QDate &date)
QVariant (const QTime &time)
QVariant (const QDateTime &datetime)
QVariant (const QList< QVariant > &list)
QVariant (const QMap< QString, QVariant > &map)
QVariant (const QHash< QString, QVariant > &hash)
QVariant (const QSize &size)
QVariant (const QSizeF &size)
QVariant (const QPoint &pt)
QVariant (const QPointF &pt)
QVariant (const QLine &line)
QVariant (const QLineF &line)
QVariant (const QRect &rect)
QVariant (const QRectF &rect)
QVariant (const QUrl &url)
QVariant (const QLocale &locale)
QVariant (const QRegExp &regExp)
QVariant (const QEasingCurve &easing)
QVariant (Qt::GlobalColor color)
~QVariant ()
boolcanConvert (Type t) const
boolcanConvert () const
voidclear ()
const void *constData () const
boolconvert (Type t)
void *data ()
const void *data () const
DataPtr &data_ptr ()
voiddetach ()
boolisDetached () const
boolisNull () const
boolisValid () const
voidload (QDataStream &ds)
booloperator!= (const QVariant &v) const
QVariant &operator= (const QVariant &other)
booloperator== (const QVariant &v) const
voidsave (QDataStream &ds) const
voidsetValue (const T &value)
voidswap (QVariant &other)
QBitArraytoBitArray () const
booltoBool () const
QByteArraytoByteArray () const
QChartoChar () const
QDatetoDate () const
QDateTimetoDateTime () const
doubletoDouble (bool *ok=0) const
QEasingCurvetoEasingCurve () const
floattoFloat (bool *ok=0) const
QHash< QString, QVariant >toHash () const
inttoInt (bool *ok=0) const
QLinetoLine () const
QLineFtoLineF () const
QList< QVariant >toList () const
QLocaletoLocale () const
qlonglongtoLongLong (bool *ok=0) const
QMap< QString, QVariant >toMap () const
QPointtoPoint () const
QPointFtoPointF () const
qrealtoReal (bool *ok=0) const
QRecttoRect () const
QRectFtoRectF () const
QRegExptoRegExp () const
QSizetoSize () const
QSizeFtoSizeF () const
QStringtoString () const
QStringListtoStringList () const
QTimetoTime () const
uinttoUInt (bool *ok=0) const
qulonglongtoULongLong (bool *ok=0) const
QUrltoUrl () const
Typetype () const
const char *typeName () const
intuserType () const
Tvalue () const

Static Public Functions Index

QVariantfromValue (const T &value)
TypenameToType (const char *name)
const char *typeToName (Type type)

Protected Functions Index

boolcmp (const QVariant &other) const
voidcreate (int type, const void *copy)

Public Types

typedef Private DataPtr

typedef bool(* f_canConvert

typedef void(* f_clear

typedef bool(* f_compare

typedef void(* f_construct

typedef bool(* f_convert

typedef void(* f_debugStream

typedef void(* f_load

typedef bool(* f_null

typedef void(* f_save

Type

Invalid 0
Bool 1
Int 2
UInt 3
LongLong 4
ULongLong 5
Double 6
Char 7
Map 8
List 9
String 10
StringList 11
ByteArray 12
BitArray 13
Date 14
Time 15
DateTime 16
Url 17
Locale 18
Rect 19
RectF 20
Size 21
SizeF 22
Line 23
LineF 24
Point 25
PointF 26
RegExp 27
Hash 28
EasingCurve 29
LastCoreType EasingCurve
Font 64
Pixmap 65
Brush 66
Color 67
Palette 68
Icon 69
Image 70
Polygon 71
Region 72
Bitmap 73
Cursor 74
SizePolicy 75
KeySequence 76
Pen 77
TextLength 78
TextFormat 79
Matrix 80
Transform 81
Matrix4x4 82
Vector2D 83
Vector3D 84
Vector4D 85
Quaternion 86
LastGuiType Quaternion
UserType 127
LastType 0xffffffff

Protected Attributes

Private d ()

Public Functions

QVariant ()

QVariant (
  • Typetype)

QVariant (
  • inttypeOrUserType,
  • const void *copy )

QVariant (
  • inttypeOrUserType,
  • const void *copy,
  • uintflags )

QVariant (

QVariant (

QVariant (
  • inti)

QVariant (
  • uintui)

QVariant (
  • qlonglongll)

QVariant (
  • qulonglongull)

QVariant (
  • boolb)

QVariant (
  • doubled)

QVariant (
  • floatf)

QT_ASCII_CAST_WARN_CONSTRUCTOR QVariant (
  • const char *str)

QVariant (

QVariant (

QVariant (

QVariant (

QVariant (

QVariant (

QVariant (

QVariant (

QVariant (

QVariant (

QVariant (

QVariant (

QVariant (

QVariant (

QVariant (

QVariant (

QVariant (

QVariant (

QVariant (

QVariant (

QVariant (

QVariant (

QVariant (

QVariant (

QVariant (
  • Qt::GlobalColorcolor)

~QVariant ()

Destructor.

bool canConvert (
  • Typet)

bool canConvert (
  • typename T)

void clear ()

const void * constData ()

bool convert (
  • Typet)

void * data ()

const void * data ()

DataPtr & data_ptr ()

void detach ()

bool isDetached ()

bool isNull ()

bool isValid ()

void load (

bool operator!= (

QVariant & operator= (

bool operator== (

void save (

void setValue (
  • typename T,
  • const T &value )

void swap (

QBitArray toBitArray ()

bool toBool ()

QByteArray toByteArray ()

QChar toChar ()

QDate toDate ()

QDateTime toDateTime ()

double toDouble (
  • bool *ok)

QEasingCurve toEasingCurve ()

float toFloat (
  • bool *ok)

QHash< QString, QVariant > toHash ()

int toInt (
  • bool *ok)

QLine toLine ()

QLineF toLineF ()

QList< QVariant > toList ()

QLocale toLocale ()

qlonglong toLongLong (
  • bool *ok)

QMap< QString, QVariant > toMap ()

QPoint toPoint ()

QPointF toPointF ()

qreal toReal (
  • bool *ok)

QRect toRect ()

QRectF toRectF ()

QRegExp toRegExp ()

QSize toSize ()

QSizeF toSizeF ()

QString toString ()

QStringList toStringList ()

QTime toTime ()

uint toUInt (
  • bool *ok)

qulonglong toULongLong (
  • bool *ok)

QUrl toUrl ()

Type type ()

const char * typeName ()

int userType ()

T value (
  • typename T)

Static Public Functions

QVariant fromValue (
  • typename T,
  • const T &value )

Type nameToType (
  • const char *name)

const char * typeToName (
  • Typetype)

Protected Functions

bool cmp (

void create (
  • inttype,
  • const void *copy )

Last modified: 2015-07-24



Got questions about leaving a comment? Get answers from our Disqus FAQ.

comments powered by Disqus