#include #include #include #include #include #include #include #include //#include //#include //#include //#include //#include //#include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include //#include int main(int argc, char* argv[]) { QCoreApplication a(argc, argv); QString pickle = "my_pickle"; QVariant tomato = "my_tomato"; QStringList ingredients = { "my_onions", "my_mayo", "my_bun" }; QVector vints = { 1, 2, 3, 4 }; QList lints = { 1, 2, 3, 4 }; QList vars = { 'a', "b", 3.0 }; QHash hints = { {1, 'a'}, {2, 'b'}, {3, 'c'} }; QCache dints; double dints_1 = 1., dints_2 = 2., dints_3 = 3.; dints.insert(1, &dints_1, 1); dints.insert(2, &dints_2, 2); dints.insert(3, &dints_3, 3); QUuid uuid(1,2,3,'1','2','3','4','5','6','7','8'); QPoint pt( 1,2 ); QRect rect(1, 2, 3, 4); QRectF rectf(1., 2., 3., 4.); QSize sz(1, 2); QLine line(1, 2, 3, 4); //QVector2D v2d(1, 2); //QVector3D v3d(1, 2, 3); //QVector4D v4d(1, 2, 3, 4); //QMatrix mat; //QMatrix4x4 mat4; QStringRef sref(&pickle); QByteArray barr("qbytearray", 10); QUrl url("http:://pickle.com"); QBitArray ba(7, true); QVarLengthArray vla = { 1, 2, 3, 4, 5 }; QDate date(12, 1, 1967); QTime time(1,2,3,4); QRegularExpression re(QString("*pickle*"), QRegularExpression::NoPatternOption); QSharedPointer sp = QSharedPointer::create(1234); struct SD : QSharedData { int m_ = 1234; } sd;; QSharedDataPointer sdp(&sd); QExplicitlySharedDataPointer esdp(&sd); QObject obj; QPointer p(&obj); QSharedPointer sip = QSharedPointer::create(1234); QWeakPointer wp(sip); QScopedPointer scp(new int(1234)); QScopedArrayPointer scqp(new int[4] {1, 2, 4, 4}); QPair pair(1234, 1234.0); QLinkedList ll({ 1, 2, 3, 4 }); QMap map({ {1,1.0}, {2, 2.0}, {3, 3.0}, {4, 4.0} }); QSet s({ 1, 2, 3, 4 }); int i = 1; return a.exec(); }