Explicit template instantiations for mixins for containers

This commit is contained in:
Mat Sutcliffe
2021-10-06 18:11:05 +01:00
parent 2b72600937
commit a185c7aae7
122 changed files with 340 additions and 5 deletions

View File

@@ -18,6 +18,7 @@ using namespace BlackMisc::Network;
using namespace BlackMisc::PhysicalQuantities;
BLACK_DEFINE_VALUEOBJECT_MIXINS(BlackCore::Db, CDatabaseReaderConfig)
BLACK_DEFINE_SEQUENCE_MIXINS(BlackCore::Db, CDatabaseReaderConfig, CDatabaseReaderConfigList)
namespace BlackCore::Db
{

View File

@@ -87,7 +87,12 @@ namespace BlackCore::Db
BLACK_METAMEMBER(retrievalMode),
BLACK_METAMEMBER(cacheLifetime));
};
}
BLACK_DECLARE_SEQUENCE_MIXINS(BlackCore::Db, CDatabaseReaderConfig, CDatabaseReaderConfigList)
namespace BlackCore::Db
{
//! Value object encapsulating a list of reader configs.
class BLACKCORE_EXPORT CDatabaseReaderConfigList :
public BlackMisc::CSequence<CDatabaseReaderConfig>,

View File

@@ -14,6 +14,8 @@
using namespace BlackConfig;
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc, CApplicationInfo, CApplicationInfoList)
namespace BlackMisc
{
CApplicationInfoList::CApplicationInfoList() {}

View File

@@ -15,6 +15,8 @@
#include "blackmisc/sequence.h"
#include "blackmisc/collection.h"
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc, CApplicationInfo, CApplicationInfoList)
namespace BlackMisc
{
/*!

View File

@@ -17,6 +17,8 @@
#include <algorithm>
#include <tuple>
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Audio, CAudioDeviceInfo, CAudioDeviceInfoList)
namespace BlackMisc::Audio
{
CAudioDeviceInfoList::CAudioDeviceInfoList() { }

View File

@@ -21,6 +21,8 @@
#include <QAudioDeviceInfo>
#include <QStringList>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Audio, CAudioDeviceInfo, CAudioDeviceInfoList)
namespace BlackMisc::Audio
{
//! Value object encapsulating a list of audio devices.

View File

@@ -15,6 +15,8 @@
#include <Qt>
#include <QMap>
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Aviation, CAircraftCategory, CAircraftCategoryList)
namespace BlackMisc::Aviation
{
CAircraftCategoryList::CAircraftCategoryList()

View File

@@ -23,6 +23,8 @@
#include <QList>
#include <tuple>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Aviation, CAircraftCategory, CAircraftCategoryList)
namespace BlackMisc::Aviation
{
//! Value object encapsulating a list of ICAO codes.

View File

@@ -13,6 +13,8 @@
#include <QString>
#include <QtGlobal>
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Aviation, CAircraftEngine, CAircraftEngineList)
namespace BlackMisc::Aviation
{
CAircraftEngineList::CAircraftEngineList(std::initializer_list<bool> enginesOnOff)

View File

@@ -23,6 +23,8 @@
#include <initializer_list>
#include <tuple>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Aviation, CAircraftEngine, CAircraftEngineList)
namespace BlackMisc::Aviation
{
//! Value object encapsulating a list of aircraft engines.

View File

@@ -15,6 +15,8 @@
#include <QJsonValue>
#include <Qt>
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Aviation, CAircraftIcaoCode, CAircraftIcaoCodeList)
namespace BlackMisc::Aviation
{
CAircraftIcaoCodeList::CAircraftIcaoCodeList()

View File

@@ -22,6 +22,8 @@
#include <QStringList>
#include <tuple>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Aviation, CAircraftIcaoCode, CAircraftIcaoCodeList)
namespace BlackMisc::Aviation
{
class CAircraftCategoryList;

View File

@@ -11,6 +11,8 @@
#include <tuple>
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Aviation, CAircraftParts, CAircraftPartsList)
namespace BlackMisc::Aviation
{
CAircraftPartsList::CAircraftPartsList() { }

View File

@@ -20,6 +20,8 @@
#include <QHash>
#include <QMetaType>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Aviation, CAircraftParts, CAircraftPartsList)
namespace BlackMisc::Aviation
{
//! Value object encapsulating a list of aircraft parts.

View File

@@ -9,6 +9,8 @@
#include "blackmisc/aviation/aircraftsituationchangelist.h"
#include <tuple>
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Aviation, CAircraftSituationChange, CAircraftSituationChangeList)
namespace BlackMisc::Aviation
{
CAircraftSituationChangeList::CAircraftSituationChangeList() { }

View File

@@ -17,6 +17,8 @@
#include "blackmisc/aviation/aircraftsituationchange.h"
#include "blackmisc/timestampobjectlist.h"
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Aviation, CAircraftSituationChange, CAircraftSituationChangeList)
namespace BlackMisc::Aviation
{
//! Value object encapsulating a list of aircraft parts.

View File

@@ -19,6 +19,8 @@ using namespace BlackMisc::Geo;
using namespace BlackMisc::PhysicalQuantities;
using namespace BlackMisc::Math;
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Aviation, CAircraftSituation, CAircraftSituationList)
namespace BlackMisc::Aviation
{
CAircraftSituationList::CAircraftSituationList()

View File

@@ -25,6 +25,8 @@
#include <QPair>
#include <QHash>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Aviation, CAircraftSituation, CAircraftSituationList)
namespace BlackMisc
{
namespace Geo { class CElevationPlane; }

View File

@@ -16,6 +16,8 @@
#include <QJsonValue>
#include <QStringBuilder>
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Aviation, CAirlineIcaoCode, CAirlineIcaoCodeList)
namespace BlackMisc::Aviation
{
const QStringList &CAirlineIcaoCodeList::getLogCategories()

View File

@@ -24,6 +24,8 @@
#include <QStringList>
#include <tuple>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Aviation, CAirlineIcaoCode, CAirlineIcaoCodeList)
namespace BlackMisc::Aviation
{
//! Value object encapsulating a list of ICAO codes.

View File

@@ -16,6 +16,8 @@
using namespace BlackMisc::PhysicalQuantities;
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Aviation, CAirport, CAirportList)
namespace BlackMisc::Aviation
{
CAirportList::CAirportList() { }

View File

@@ -21,6 +21,8 @@
#include <QMetaType>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Aviation, CAirport, CAirportList)
namespace BlackMisc::Aviation
{
//! Value object for a list of airports.

View File

@@ -21,6 +21,8 @@
using namespace BlackMisc::PhysicalQuantities;
using namespace BlackMisc::Network;
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Aviation, CAtcStation, CAtcStationList)
namespace BlackMisc::Aviation
{
CAtcStationList::CAtcStationList() { }

View File

@@ -24,6 +24,8 @@
#include <QMetaType>
#include <QHash>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Aviation, CAtcStation, CAtcStationList)
namespace BlackMisc::Aviation
{
//! Value object for a list of ATC stations.

View File

@@ -14,6 +14,8 @@
#include <QJsonObject>
#include <QString>
BLACK_DEFINE_COLLECTION_MIXINS(BlackMisc::Aviation, CCallsign, CCallsignSet)
namespace BlackMisc::Aviation
{
CCallsignSet::CCallsignSet() { }

View File

@@ -21,12 +21,17 @@
#include <QStringList>
#include <tuple>
BLACK_DECLARE_COLLECTION_MIXINS(BlackMisc::Aviation, CCallsign, CCallsignSet)
namespace BlackMisc::Aviation
{
//! Value object for a set of callsigns.
class BLACKMISC_EXPORT CCallsignSet : public CCollection<CCallsign>
class BLACKMISC_EXPORT CCallsignSet :
public CCollection<CCallsign>,
public Mixin::MetaType<CCallsignSet>
{
using CCollection::CCollection;
BLACKMISC_DECLARE_USING_MIXIN_METATYPE(CCallsignSet)
public:
//! Default constructor

View File

@@ -15,6 +15,8 @@
#include <QString>
#include <QtGlobal>
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Aviation, CFlightPlan, CFlightPlanList)
namespace BlackMisc::Aviation
{
CFlightPlanList::CFlightPlanList() { }

View File

@@ -18,6 +18,8 @@
#include "blackmisc/sequence.h"
#include <QMetaType>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Aviation, CFlightPlan, CFlightPlanList)
namespace BlackMisc::Aviation
{
//! Value object for a list of flight plans.

View File

@@ -15,6 +15,8 @@
using namespace BlackMisc::Aviation;
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Aviation, CLivery, CLiveryList)
namespace BlackMisc::Aviation
{
CLiveryList::CLiveryList() { }

View File

@@ -22,6 +22,8 @@
#include <QString>
#include <QStringList>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Aviation, CLivery, CLiveryList)
namespace BlackMisc::Aviation
{
//! Value object for a list of airports.

View File

@@ -22,6 +22,46 @@
#include <utility>
#include <initializer_list>
//! \cond
#define BLACK_TEMPLATE_COLLECTION_MIXINS(NS, T, Set, Extern) \
namespace NS { class Set; } \
namespace BlackMisc::Private \
{ \
Extern template struct CValueObjectMetaInfo<NS::Set>; \
Extern template struct CValueObjectMetaInfo<CCollection<NS::T>>; \
Extern template struct MetaTypeHelper<NS::Set>; \
Extern template struct MetaTypeHelper<CCollection<NS::T>>; \
} \
namespace BlackMisc::Mixin \
{ \
Extern template class MetaType<NS::Set>; \
Extern template class MetaType<CCollection<NS::T>>; \
Extern template class DBusOperators<CCollection<NS::T>>; \
Extern template class JsonOperators<CCollection<NS::T>>; \
Extern template class String<CCollection<NS::T>>; \
Extern template class DataStreamOperators<CCollection<NS::T>>; \
Extern template class Icon<CCollection<NS::T>>; \
}
//! \endcond
/*!
* \def BLACK_DECLARE_COLLECTION_MIXINS
* Explicit template declaration of mixins for a CCollection subclass
* to be placed near the top of the header that defines the class
*/
/*!
* \def BLACK_DEFINE_COLLECTION_MIXINS
* Explicit template definition of mixins for a CCollection subclass
*/
#if defined(Q_OS_WIN) && defined(Q_CC_GNU)
# define BLACK_DECLARE_COLLECTION_MIXINS(Namespace, T, Set)
# define BLACK_DEFINE_COLLECTION_MIXINS(Namespace, T, Set)
#else
# define BLACK_DECLARE_COLLECTION_MIXINS(Namespace, T, Set) BLACK_TEMPLATE_COLLECTION_MIXINS(Namespace, T, Set, extern)
# define BLACK_DEFINE_COLLECTION_MIXINS(Namespace, T, Set) BLACK_TEMPLATE_COLLECTION_MIXINS(Namespace, T, Set, )
#endif
namespace BlackMisc
{

View File

@@ -14,6 +14,8 @@
#include <QRegularExpression>
#include <Qt>
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc, CCountry, CCountryList)
namespace BlackMisc
{
CCountryList::CCountryList() {}

View File

@@ -23,6 +23,8 @@
#include <QStringList>
#include <tuple>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc, CCountry, CCountryList)
namespace BlackMisc
{
//! Value object encapsulating a list of countries.

View File

@@ -11,6 +11,8 @@
using namespace BlackMisc::Network;
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Db, CArtifact, CArtifactList)
namespace BlackMisc::Db
{
CArtifactList::CArtifactList() { }

View File

@@ -22,6 +22,8 @@
#include <QSet>
#include <QString>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Db, CArtifact, CArtifactList)
namespace BlackMisc::Db
{
//! Multiple artifacts

View File

@@ -10,6 +10,8 @@
using namespace BlackMisc::Network;
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Db, CDbInfo, CDbInfoList)
namespace BlackMisc::Db
{
CDbInfoList::CDbInfoList() { }

View File

@@ -20,6 +20,8 @@
#include <initializer_list>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Db, CDbInfo, CDbInfoList)
namespace BlackMisc::Db
{
//! Value object encapsulating a list of info objects.

View File

@@ -9,6 +9,8 @@
#include "blackmisc/db/distributionlist.h"
#include "blackmisc/stringutils.h"
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Db, CDistribution, CDistributionList)
namespace BlackMisc::Db
{
CDistributionList::CDistributionList() { }

View File

@@ -20,6 +20,8 @@
#include <QSet>
#include <QString>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Db, CDistribution, CDistributionList)
namespace BlackMisc::Db
{
//! Multiple distributions for different channels:

View File

@@ -16,6 +16,8 @@
using namespace BlackMisc::Math;
using namespace BlackMisc::PhysicalQuantities;
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Geo, CCoordinateGeodetic, CCoordinateGeodeticList)
namespace BlackMisc::Geo
{
CCoordinateGeodeticList::CCoordinateGeodeticList()

View File

@@ -24,6 +24,8 @@
#include <QMetaType>
#include <initializer_list>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Geo, CCoordinateGeodetic, CCoordinateGeodeticList)
namespace BlackMisc::Geo
{
//! Value object encapsulating a list of coordinates.

View File

@@ -12,6 +12,8 @@
#include "blackmisc/range.h"
#include <QDBusMetaType>
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc, CIcon, CIconList)
namespace BlackMisc
{
CIconList::CIconList(const CSequence<CIcon> &other) :

View File

@@ -24,14 +24,19 @@
#include <QtGlobal>
#include <tuple>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc, CIcon, CIconList)
namespace BlackMisc
{
/*!
* Icon list (swift standard icons)
*/
class BLACKMISC_EXPORT CIconList : public CSequence<CIcon>
class BLACKMISC_EXPORT CIconList :
public CSequence<CIcon>,
public Mixin::MetaType<CIconList>
{
using CSequence::CSequence;
BLACKMISC_DECLARE_USING_MIXIN_METATYPE(CIconList)
public:
//! Constructor

View File

@@ -12,6 +12,8 @@
#include <QString>
#include <tuple>
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc, CIdentifier, CIdentifierList)
namespace BlackMisc
{
CIdentifierList::CIdentifierList() { }

View File

@@ -17,6 +17,8 @@
#include "blackmisc/blackmiscexport.h"
#include <QMetaType>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc, CIdentifier, CIdentifierList)
namespace BlackMisc
{
/*!

View File

@@ -11,6 +11,8 @@
#include <QString>
#include <tuple>
BLACK_DEFINE_COLLECTION_MIXINS(BlackMisc, CIdentifier, CIdentifierSet)
namespace BlackMisc
{
CIdentifierSet::CIdentifierSet() { }

View File

@@ -16,14 +16,19 @@
#include "blackmisc/blackmiscexport.h"
#include <QMetaType>
BLACK_DECLARE_COLLECTION_MIXINS(BlackMisc, CIdentifier, CIdentifierSet)
namespace BlackMisc
{
/*!
* Value object encapsulating a set of object identifiers
*/
class BLACKMISC_EXPORT CIdentifierSet : public CCollection<CIdentifier>
class BLACKMISC_EXPORT CIdentifierSet :
public CCollection<CIdentifier>,
public Mixin::MetaType<CIdentifierSet>
{
using CCollection::CCollection;
BLACKMISC_DECLARE_USING_MIXIN_METATYPE(CIdentifierSet)
public:
//! Default constructor.

View File

@@ -9,6 +9,8 @@
#include "blackmisc/input/actionhotkeylist.h"
#include "blackmisc/input/hotkeycombination.h"
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Input, CActionHotkey, CActionHotkeyList)
namespace BlackMisc::Input
{
CActionHotkeyList::CActionHotkeyList(const CSequence<CActionHotkey> &baseClass) :

View File

@@ -21,6 +21,8 @@
#include <initializer_list>
#include <tuple>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Input, CActionHotkey, CActionHotkeyList)
namespace BlackMisc::Input
{
//! Value object encapsulating a list of hotkeys

View File

@@ -8,6 +8,8 @@
#include "blackmisc/input/joystickbuttonlist.h"
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Input, CJoystickButton, CJoystickButtonList)
namespace BlackMisc::Input
{
CJoystickButtonList::CJoystickButtonList(const CSequence<CJoystickButton> &baseClass) :

View File

@@ -20,6 +20,8 @@
#include <initializer_list>
#include <tuple>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Input, CJoystickButton, CJoystickButtonList)
namespace BlackMisc::Input
{
//! Value object encapsulating a list of joystick buttons.

View File

@@ -9,6 +9,8 @@
#include "blackmisc/input/keyboardkeylist.h"
#include "blackmisc/input/keycodes.h"
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Input, CKeyboardKey, CKeyboardKeyList)
namespace BlackMisc::Input
{
CKeyboardKeyList::CKeyboardKeyList() { }

View File

@@ -21,6 +21,8 @@
#include <initializer_list>
#include <tuple>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Input, CKeyboardKey, CKeyboardKeyList)
namespace BlackMisc::Input
{
//! Value object encapsulating a list of keyboard keys.

View File

@@ -18,6 +18,8 @@
struct QMetaObject;
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc, CLogCategory, CLogCategoryList)
namespace BlackMisc
{
void CLogCategoryList::appendCategoriesFromMetaObject(const QMetaObject &metaObject, const QMetaObject &super)

View File

@@ -29,14 +29,19 @@
#include <tuple>
#include <type_traits>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc, CLogCategory, CLogCategoryList)
namespace BlackMisc
{
/*!
* A sequence of log categories.
*/
class BLACKMISC_EXPORT CLogCategoryList : public CSequence<CLogCategory>
class BLACKMISC_EXPORT CLogCategoryList :
public CSequence<CLogCategory>,
public Mixin::MetaType<CLogCategoryList>
{
using CSequence::CSequence;
BLACKMISC_DECLARE_USING_MIXIN_METATYPE(CLogCategoryList)
public:
//! Empty constructor.

View File

@@ -11,6 +11,8 @@
#include <tuple>
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc, CNameVariantPair, CNameVariantPairList)
namespace BlackMisc
{
CNameVariantPairList::CNameVariantPairList() { }

View File

@@ -20,6 +20,8 @@
#include <QMetaType>
#include <QString>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc, CNameVariantPair, CNameVariantPairList)
namespace BlackMisc
{
//! Value object encapsulating a list of name/variant pairs

View File

@@ -10,6 +10,8 @@
using namespace BlackMisc::Aviation;
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Network, CClient, CClientList)
namespace BlackMisc::Network
{
CClientList::CClientList() { }

View File

@@ -19,6 +19,8 @@
#include <QMap>
#include <QMetaType>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Network, CClient, CClientList)
namespace BlackMisc::Network
{
//! Value object encapsulating a list of voice rooms.

View File

@@ -8,6 +8,8 @@
#include "blackmisc/network/ecosystemlist.h"
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Network, CEcosystem, CEcosystemList)
namespace BlackMisc::Network
{
CEcosystemList::CEcosystemList() { }

View File

@@ -18,6 +18,8 @@
#include <QStringList>
#include <QMetaType>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Network, CEcosystem, CEcosystemList)
namespace BlackMisc::Network
{
//! Value object encapsulating a list of voice rooms.

View File

@@ -8,6 +8,8 @@
#include "blackmisc/network/rawfsdmessagelist.h"
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Network, CRawFsdMessage, CRawFsdMessageList)
namespace BlackMisc::Network
{
CRawFsdMessageList::CRawFsdMessageList() { }

View File

@@ -20,6 +20,8 @@
#include <QMetaType>
#include <initializer_list>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Network, CRawFsdMessage, CRawFsdMessageList)
namespace BlackMisc::Network
{
//! Value object encapsulating a list raw FSD messages.

View File

@@ -14,6 +14,8 @@
#include <QJsonValue>
#include <tuple>
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Network, CRemoteFile, CRemoteFileList)
namespace BlackMisc::Network
{
CRemoteFileList::CRemoteFileList() { }

View File

@@ -21,6 +21,8 @@
#include <QString>
#include <QStringList>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Network, CRemoteFile, CRemoteFileList)
namespace BlackMisc::Network
{
//! Value object encapsulating a list of remote files.

View File

@@ -13,6 +13,8 @@
#include <QJsonValue>
#include <tuple>
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Network, CRole, CRoleList)
namespace BlackMisc::Network
{
CRoleList::CRoleList() { }

View File

@@ -21,6 +21,8 @@
#include <QString>
#include <QStringList>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Network, CRole, CRoleList)
namespace BlackMisc::Network
{
class CRole;

View File

@@ -9,6 +9,8 @@
#include "blackmisc/network/serverlist.h"
#include <tuple>
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Network, CServer, CServerList)
namespace BlackMisc::Network
{
CServerList::CServerList() { }

View File

@@ -19,6 +19,8 @@
#include <QMetaType>
#include <QString>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Network, CServer, CServerList)
namespace BlackMisc::Network
{
//! Value object encapsulating a list of servers.

View File

@@ -18,6 +18,8 @@
using namespace BlackMisc::PhysicalQuantities;
using namespace BlackMisc::Aviation;
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Network, CTextMessage, CTextMessageList)
namespace BlackMisc::Network
{

View File

@@ -23,6 +23,8 @@
#include <QMetaType>
#include <QString>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Network, CTextMessage, CTextMessageList)
namespace BlackMisc::Network
{
class CTextMessage;

View File

@@ -16,6 +16,8 @@
using namespace BlackMisc::Math;
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Network, CUrl, CUrlList)
namespace BlackMisc::Network
{
CUrlList::CUrlList() { }

View File

@@ -20,6 +20,8 @@
#include <QString>
#include <QStringList>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Network, CUrl, CUrlList)
namespace BlackMisc::Network
{
//! Value object encapsulating a list of URLs.

View File

@@ -8,6 +8,8 @@
#include "blackmisc/network/urlloglist.h"
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Network, CUrlLog, CUrlLogList)
namespace BlackMisc::Network
{
CUrlLogList::CUrlLogList() { }

View File

@@ -18,6 +18,8 @@
#include "blackmisc/sequence.h"
#include <QNetworkReply>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Network, CUrlLog, CUrlLogList)
namespace BlackMisc::Network
{
//! Value object encapsulating a list of voice rooms.

View File

@@ -11,6 +11,8 @@
#include <QString>
#include <tuple>
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Network, CUser, CUserList)
namespace BlackMisc::Network
{
CUserList::CUserList() { }

View File

@@ -19,6 +19,8 @@
#include <QMetaType>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Network, CUser, CUserList)
namespace BlackMisc::Network
{
//! Value object encapsulating a list of voice rooms.

View File

@@ -16,6 +16,8 @@
#include <QJsonObject>
#include <QString>
BLACK_DEFINE_COLLECTION_MIXINS(BlackMisc, CPlatform, CPlatformSet)
namespace BlackMisc
{
CPlatformSet::CPlatformSet() { }

View File

@@ -19,12 +19,17 @@
#include <QMetaType>
#include <tuple>
BLACK_DECLARE_COLLECTION_MIXINS(BlackMisc, CPlatform, CPlatformSet)
namespace BlackMisc
{
//! Value object for a set of platforms.
class BLACKMISC_EXPORT CPlatformSet : public CCollection<CPlatform>
class BLACKMISC_EXPORT CPlatformSet :
public CCollection<CPlatform>,
public Mixin::MetaType<CPlatformSet>
{
using CCollection::CCollection;
BLACKMISC_DECLARE_USING_MIXIN_METATYPE(CPlatformSet)
public:
//! Default constructor.

View File

@@ -11,6 +11,8 @@
#include <QString>
#include <tuple>
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc, CPropertyIndex, CPropertyIndexList)
namespace BlackMisc
{
CPropertyIndexList::CPropertyIndexList() { }

View File

@@ -18,6 +18,8 @@
#include <QMetaType>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc, CPropertyIndex, CPropertyIndexList)
namespace BlackMisc
{
//! Value object encapsulating a list of property indexes.

View File

@@ -21,6 +21,46 @@
#include <utility>
#include <initializer_list>
//! \cond
#define BLACK_TEMPLATE_SEQUENCE_MIXINS(NS, T, List, Extern) \
namespace NS { class List; } \
namespace BlackMisc::Private \
{ \
Extern template struct CValueObjectMetaInfo<NS::List>; \
Extern template struct CValueObjectMetaInfo<CSequence<NS::T>>; \
Extern template struct MetaTypeHelper<NS::List>; \
Extern template struct MetaTypeHelper<CSequence<NS::T>>; \
} \
namespace BlackMisc::Mixin \
{ \
Extern template class MetaType<NS::List>; \
Extern template class MetaType<CSequence<NS::T>>; \
Extern template class DBusOperators<CSequence<NS::T>>; \
Extern template class JsonOperators<CSequence<NS::T>>; \
Extern template class String<CSequence<NS::T>>; \
Extern template class DataStreamOperators<CSequence<NS::T>>; \
Extern template class Icon<CSequence<NS::T>>; \
}
//! \endcond
/*!
* \def BLACK_DECLARE_SEQUENCE_MIXINS
* Explicit template declaration of mixins for a CSequence subclass
* to be placed near the top of the header that defines the class
*/
/*!
* \def BLACK_DEFINE_SEQUENCE_MIXINS
* Explicit template definition of mixins for a CSequence subclass
*/
#if defined(Q_OS_WIN) && defined(Q_CC_GNU)
# define BLACK_DECLARE_SEQUENCE_MIXINS(Namespace, T, List)
# define BLACK_DEFINE_SEQUENCE_MIXINS(Namespace, T, List)
#else
# define BLACK_DECLARE_SEQUENCE_MIXINS(Namespace, T, List) BLACK_TEMPLATE_SEQUENCE_MIXINS(Namespace, T, List, extern)
# define BLACK_DEFINE_SEQUENCE_MIXINS(Namespace, T, List) BLACK_TEMPLATE_SEQUENCE_MIXINS(Namespace, T, List, )
#endif
namespace BlackMisc
{
/*!

View File

@@ -35,6 +35,8 @@ using namespace BlackMisc::Math;
using namespace BlackMisc::Aviation;
using namespace BlackMisc::PhysicalQuantities;
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Simulation, CAircraftModel, CAircraftModelList)
namespace BlackMisc::Simulation
{
CAircraftModelList::CAircraftModelList() { }

View File

@@ -37,6 +37,8 @@
#include <QMap>
#include <atomic>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Simulation, CAircraftModel, CAircraftModelList)
namespace BlackMisc
{
namespace Aviation

View File

@@ -12,6 +12,8 @@
#include <tuple>
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Simulation, CDistributor, CDistributorList)
namespace BlackMisc::Simulation
{
CDistributorList::CDistributorList() { }

View File

@@ -22,6 +22,8 @@
#include <QString>
#include <QStringList>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Simulation, CDistributor, CDistributorList)
namespace BlackMisc::Simulation
{
class CAircraftModel;

View File

@@ -17,6 +17,8 @@
using namespace BlackMisc;
using namespace BlackMisc::Simulation;
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Simulation::FsCommon, CAircraftCfgEntries, CAircraftCfgEntriesList)
namespace BlackMisc::Simulation::FsCommon
{
bool CAircraftCfgEntriesList::containsModelWithTitle(const QString &title, Qt::CaseSensitivity caseSensitivity)

View File

@@ -25,6 +25,8 @@
#include <Qt>
#include <tuple>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Simulation::FsCommon, CAircraftCfgEntries, CAircraftCfgEntriesList)
namespace BlackMisc::Simulation::FsCommon
{
//! Utility, providing FS aircraft.cfg entries

View File

@@ -16,6 +16,8 @@
#include <Qt>
#include <tuple>
BLACK_DEFINE_COLLECTION_MIXINS(BlackMisc::Simulation::FsCommon, CVPilotModelRule, CVPilotModelRuleSet)
namespace BlackMisc::Simulation::FsCommon
{
CVPilotModelRuleSet::CVPilotModelRuleSet(const CCollection<CVPilotModelRule> &other) :

View File

@@ -22,6 +22,8 @@
#include "blackmisc/simulation/aircraftmodellist.h"
#include "blackmisc/simulation/fscommon/vpilotmodelrule.h"
BLACK_DECLARE_COLLECTION_MIXINS(BlackMisc::Simulation::FsCommon, CVPilotModelRule, CVPilotModelRuleSet)
namespace BlackMisc::Simulation::FsCommon
{
//! Value object reading a set of vPilot rules

View File

@@ -8,6 +8,8 @@
#include "blackmisc/simulation/interpolationsetuplist.h"
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Simulation, CInterpolationAndRenderingSetupPerCallsign, CInterpolationSetupList)
namespace BlackMisc::Simulation
{
CInterpolationSetupList::CInterpolationSetupList() { }

View File

@@ -17,6 +17,8 @@
#include "blackmisc/collection.h"
#include "blackmisc/sequence.h"
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Simulation, CInterpolationAndRenderingSetupPerCallsign, CInterpolationSetupList)
namespace BlackMisc::Simulation
{
//! Value object encapsulating a list of setups.

View File

@@ -8,6 +8,8 @@
#include "blackmisc/simulation/matchingstatistics.h"
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Simulation, CMatchingStatisticsEntry, CMatchingStatistics)
namespace BlackMisc::Simulation
{
CMatchingStatistics::CMatchingStatistics()

View File

@@ -18,6 +18,8 @@
#include "blackmisc/collection.h"
#include "blackmisc/mixin/mixinmetatype.h"
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Simulation, CMatchingStatisticsEntry, CMatchingStatistics)
namespace BlackMisc::Simulation
{
//! Value object for matching statistics.

View File

@@ -24,6 +24,8 @@ using namespace BlackMisc::Geo;
using namespace BlackMisc::PhysicalQuantities;
using namespace BlackMisc::Network;
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Simulation, CSimulatedAircraft, CSimulatedAircraftList)
namespace BlackMisc::Simulation
{
CSimulatedAircraftList::CSimulatedAircraftList() { }

View File

@@ -21,6 +21,8 @@
#include "blackmisc/sequence.h"
#include <QMetaType>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Simulation, CSimulatedAircraft, CSimulatedAircraftList)
namespace BlackMisc
{
namespace Aviation

View File

@@ -11,6 +11,8 @@
#include <QList>
#include <tuple>
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Simulation, CSimulatorInfo, CSimulatorInfoList)
namespace BlackMisc::Simulation
{
CSimulatorInfoList::CSimulatorInfoList() { }

View File

@@ -18,6 +18,8 @@
#include <QMetaType>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Simulation, CSimulatorInfo, CSimulatorPluginInfoList)
namespace BlackMisc::Simulation
{
//! Value object encapsulating a list of distributors.

View File

@@ -14,6 +14,8 @@
#include <algorithm>
#include <tuple>
BLACK_DEFINE_SEQUENCE_MIXINS(BlackMisc::Simulation, CSimulatorPluginInfo, CSimulatorPluginInfoList)
namespace BlackMisc::Simulation
{
CSimulatorPluginInfoList::CSimulatorPluginInfoList() { }

View File

@@ -21,6 +21,8 @@
#include <QString>
#include <QStringList>
BLACK_DECLARE_SEQUENCE_MIXINS(BlackMisc::Simulation, CSimulatorPluginInfo, CSimulatorPluginInfoList)
namespace BlackMisc::Simulation
{
class CSimulatorPluginInfo;

Some files were not shown because too many files have changed in this diff Show More