Re: [Development] Proposal for an efficient and robust (de)serialization mechanism working with Qt-supported data

2019-08-29 Thread Terry Williams
Please remove me from your mailing list

Thanks.

On Tue, Aug 27, 2019 at 5:46 AM Arnaud Clere 
wrote:

> Hi all,
>
>
>
> Qt handles a broad spectrum of data both in and out of RAM and Qt users
> routinely need to read/write such data from/to their domain-specific C++
> types.
>
> But doing so can feel much more complicated than it should be: e.g.
> unexpected QVariant conversions, unknown QDataStream versions, complex
> QAbstractItemModel requirements, specific QCborStreamReader protocol, ...
>
> Moreover, writing such boilerplate code is time-consuming, error-prone,
> and boring.
>
>
>
> JSON demonstrates that having a simple data model can simplify exchanging
> data between software components. But it cannot meet all the technical
> requirements that data must meet here and there.
>
>
>
> I am proposing to add to Qt a simple-to-use (de)serialization mechanism
> that can achieve better write performance and read robustness than current
> alternatives.
>
> It does not define a new generic data type: QVariant/List/Map,
> Q*ItemModel, QJsonValue, ... are here to meet various sets of requirements.
>
> It just defines a generic, efficient and robust templated function to
> ‘bind’ such data with any C++ type:
>
>QBind ::bind(Value&& v, T& t)
>
>
>
> It is not unit-tested but a sample and benchmark shows it can be made to
> work efficiently with:
>
> - Qt containers (read/write)
>
> - QMetaObject (read/write)
>
> - QVariant* (read/write)
>
> - QJsonValue (read/write) + ad-hoc JSON reader/writer
>
> - QCborValue (read/write), QCborStreamReader + ad-hoc CBOR writer
>
> - QSettings (read/write)
>
> - QXmlStreamWriter
>
> - QAbstractItemModel (write)
>
> - QDataStream (write)
>
>
>
> The simplest way to enable it for a C++ type is to use QMetaObject when
> available through a macro (QBIND_*_WITH_METAOBJECT).
>
> Best performance can only be attained by defining simple bind(Value&& v)
> methods that usually work for both read and write:
>
>
> https://gricad-gitlab.univ-grenoble-alpes.fr/modmed/modmedLog/blob/master/tests/QBind/README.md#extending-qbind-to-c-types
>
>
>
> Finally, since a single QBind function cannot fulfill all the needs,
> its fluent interface allows writing custom binds akin to Python list
> comprehensions…
>
>
>
> I would be happy to hear if you feel like this would be a useful
> contribution to Qt, or to answer your technical questions and arguments.
>
>
>
> Arnaud
> ___
> Development mailing list
> Development@qt-project.org
> https://lists.qt-project.org/listinfo/development
>
___
Development mailing list
Development@qt-project.org
https://lists.qt-project.org/listinfo/development


Re: [Development] Nominating Kirill Burtsev as Approver

2019-08-29 Thread Alexandru Croitor
+1

> On 29. Aug 2019, at 15:29, Allan Sandfeld Jensen  wrote:
> 
> On Thursday, 29 August 2019 14:54:45 CEST Michael Bruning wrote:
>> Hi all,
>> 
>> I would like to nominate Kirill Burtsev as approver for the Qt Project.
>> Kirill joined the Qt WebEngine team about a year ago and has been mainly
>> contributing to the web engine module, but also to qtbase and
>> qtdeclarative. I trust that he will follow Qt guidelines and will use the
>> approver rights responsibly.
>> 
>> Here is his list of changes:
>> https://codereview.qt-project.org/q/owner:kirill.burtsev%2540qt.io> odereview.qt-project.org/q/owner:kirill.burtsev%40qt.io>
>> 
>> and reviews:
>> https://codereview.qt-project.org/q/reviewer:kirill.burtsev%2540qt.io> //codereview.qt-project.org/q/reviewer:kirill.burtsev%40qt.io>
>> 
>> Disclaimer: we are working in the same company and the same team.
>> 
> 
> +1 :)
> 
> 'Allan
> 
> 
> ___
> Development mailing list
> Development@qt-project.org
> https://lists.qt-project.org/listinfo/development

___
Development mailing list
Development@qt-project.org
https://lists.qt-project.org/listinfo/development


Re: [Development] Proposal for an efficient and robust (de)serialization mechanism working with Qt-supported data

2019-08-29 Thread Arnaud Clere
Hi all,

I only received feedback from users in private, so I guess this is not the 
right mailing list to ask for feedback on new features... Would 
inter...@qt-project.org be a better place?

I thought about the developers mailing list because my proposal may allow 
answering some needs expressed in the past on the mailing list:

1. "Is it possible to increase the max. document size for the JSON parser?"
https://lists.qt-project.org/pipermail/development/2019-August/036994.html

Not exactly on-topic but QBind being a function is not limited by RAM size and 
can read/write potentially infinite Json/Xml/... streams

2. "Maybe add some kind of accessible pipeline for QSettings serialization in 
Qt6?"
https://lists.qt-project.org/pipermail/development/2019-July/036894.html

QBind provides a lot of flexibility to read/write some C++ type to QSettings, 
Json, Cbor, Xml, and it could support databases through QSqlTableModel. It 
would also allow users to define less-used or even ad-hoc formats: YAML, HDF5...
Alternatively, IBind could be used internally by QSettings to enable more 
flexibility in the future while still supporting UserScope, etc.

3. "QVariant container API"
https://lists.qt-project.org/pipermail/development/2019-April/035535.html

QBind is able to convert numeric values that fit in the type presented by the 
user as well as convert to a string representation.
But it will not change numbers into bool or QChar as QVariant::convert does, 
and values that do not fit in the user type will be reported as ignored
~~
QVariantList vs; vs.append(123); vs.append(321);
QVector ds; QStringList ls; QList cs;
QVariantVisitor(&variantContainer).bind(ds); // ds == { 123.0, 321.0 }
QVariantVisitor(&variantContainer).bind(ls); // ls == { "123", "321" }
QVariantVisitor(&variantContainer) v; v.bind(cs); v.errors().size()==2; // cs = 
{}
~~

Please tell me how to proceed.
Cheers,
Arnaud
___
Development mailing list
Development@qt-project.org
https://lists.qt-project.org/listinfo/development


Re: [Development] Nominating Kirill Burtsev as Approver

2019-08-29 Thread Allan Sandfeld Jensen
On Thursday, 29 August 2019 14:54:45 CEST Michael Bruning wrote:
> Hi all,
> 
> I would like to nominate Kirill Burtsev as approver for the Qt Project.
> Kirill joined the Qt WebEngine team about a year ago and has been mainly
> contributing to the web engine module, but also to qtbase and
> qtdeclarative. I trust that he will follow Qt guidelines and will use the
> approver rights responsibly.
> 
> Here is his list of changes:
> https://codereview.qt-project.org/q/owner:kirill.burtsev%2540qt.io odereview.qt-project.org/q/owner:kirill.burtsev%40qt.io>
> 
> and reviews:
> https://codereview.qt-project.org/q/reviewer:kirill.burtsev%2540qt.io //codereview.qt-project.org/q/reviewer:kirill.burtsev%40qt.io>
> 
> Disclaimer: we are working in the same company and the same team.
> 

+1 :)

'Allan


___
Development mailing list
Development@qt-project.org
https://lists.qt-project.org/listinfo/development


[Development] Nominating Kirill Burtsev as Approver

2019-08-29 Thread Michael Bruning
Hi all,

I would like to nominate Kirill Burtsev as approver for the Qt Project.
Kirill joined the Qt WebEngine team about a year ago and has been mainly 
contributing to the web engine module, but also to qtbase and qtdeclarative.
I trust that he will follow Qt guidelines and will use the approver rights 
responsibly.

Here is his list of changes:
https://codereview.qt-project.org/q/owner:kirill.burtsev%2540qt.io

and reviews:
https://codereview.qt-project.org/q/reviewer:kirill.burtsev%2540qt.io

Disclaimer: we are working in the same company and the same team.

--
Best regards,
Michael

___
Development mailing list
Development@qt-project.org
https://lists.qt-project.org/listinfo/development


Re: [Development] Nominating Sona Kurazyan as approver

2019-08-29 Thread Alex Blasche
Congratulations to Sona. Approver rights have been granted.

--
Alex


From: Alex Blasche
Sent: Friday, 9 August 2019 12:42
To: development@qt-project.org
Subject: Nominating Sona Kurazyan as approver

Hi all,

I'd like to nominate Sona Kurazyan as approver for the Qt Project. Sona ensured 
the release of QtCoap by bringing it to a releasable state and lately, she has 
been all over Qt doing major cleanups related to deprecated Qt APIs and Qt 6.

Here is his list of contributions:
https://codereview.qt-project.org/q/owner:sona.kurazyan%2540qt.io
And reviews:
https://codereview.qt-project.org/q/reviewer:sona.kurazyan%2540qt.io

Cheers,
--
Alex
___
Development mailing list
Development@qt-project.org
https://lists.qt-project.org/listinfo/development