QtPositioning: refactor QGeoSatelliteInfo
The following changes were implemented for the class:
- Use QExplicitlySharedDataPointer for private d-ptr.
- Implement move-constructor and move-assignment operator.
The moved-from object is left in partially-formed state. Such
behavior is documented.
- Use Q_DECLARE_SHARED to declare the typeinfo as Q_RELOCATABLE_TYPE
and provide a free swap() overload.
- Provide a qHash() overload.
- Provide a QTest::toString() overload.
All these changes are common pattern for Qt value classes.
The benchmark shows that it results in slight performance drop while
constructing a brand new object (most probably because of the overhead
of QSharedData and QExplicitlySharedDataPointer), but also gives a
comparable performance boost for copy constructor and copy assignment.
And of course a significant performance boost on move-operations (which
were just copy-operations previously). Other API calls didn't have any
significant performance impact.
Task-number: QTBUG-90491
Change-Id: I51ed7041c4b9ecd763f045abbb80df5e0dcde8f6
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>