Heart 1.3.842.34c2ab5
Heart is base back end library for your c++ Qt projects.
QH::PKG::APIVersion Class Reference

The APIVersion class This is base pacakge class that send information about supported api version on the paired node. More...

#include <apiversion.h>

Inheritance diagram for QH::PKG::APIVersion:
Inheritance graph
Collaboration diagram for QH::PKG::APIVersion:
Collaboration graph

Public Member Functions

 APIVersion ()
 
unsigned short cmd () const override
 cmd - This is command of this object, (for generate cmd use macross QH_PACKAGE)
 
QString cmdString () const override
 cmdString - This is command string of this object, (for generate cmd use macross QH_PACKAGE)
 
bool isValid () const override
 isValid This method check current object to valid.
 
PackagesVersionData packagesVersions () const
 packagesVersions This method return list of available multi-version packages on the node.
 
void setPackagesVersions (const PackagesVersionData &newPackagesVersions)
 
VersionData apisVersions () const
 
void setApisVersions (const VersionData &newApisVersions)
 
- Public Member Functions inherited from QH::PKG::AbstractData
 ~AbstractData () override
 
virtual bool toPackage (Package &package, const DistVersion &reqVersion, unsigned int triggerHash=0) const
 toPackage This method convert this class object to the package. For more info see Package class.
 
QString toString () const override
 toString - Return a string implementation for this object.
 
template<class C , class... Args>
C * create (Args &&... args) const
 create - This is factory method for create a new object.
 
void fromPakcage (const Package &pkg)
 fromPakcage - This method initialize the current object from a package class object.
 
- Public Member Functions inherited from QH::StreamBase
 StreamBase ()
 
virtual ~StreamBase ()
 
bool fromBytes (const QByteArray &data)
 fromBytes This method provide initialization of object from byte array.
 
QByteArray toBytes () const
 toBytes This method convert a current object to bytes array.
 
bool fromBase64 (const QString &data)
 fromBase64 This method provide initialization of object from the base64 string.
 
bool fromBase64 (const QByteArray &data)
 fromBase64 This method provide initialization of object from the base64 string.
 
QByteArray toBase64 () const
 toBase64 This method convert a current object to the base64 string.
 
template<class T >
T & copy (const StreamBase &right)
 copy This is base copy method for all StreamBase structures. Default implementation it is copy from byteArray.
 
template<class T >
bool compare (const T &right)
 compare This method compare array signatures of this and right objects.
 

Static Public Member Functions

static unsigned short command ()
 
static unsigned short version ()
 
static QString commandText ()
 
- Static Public Member Functions inherited from QH::PKG::AbstractData
static unsigned int command ()
 command This static method that return glaball code of this object.
 
static QString commandText ()
 commandText This method return text of package command
 

Protected Member Functions

QDataStream & fromStream (QDataStream &stream) override
 fromStream This method should be read all bytes from the stream object and full the current object.
 
QDataStream & toStream (QDataStream &stream) const override
 fromStream This method should be write all members of the current object to the stream object.
 
- Protected Member Functions inherited from QH::PKG::AbstractData
 AbstractData ()
 AbstractData - Base constructor of this object.
 
- Protected Member Functions inherited from QH::StreamBase
virtual int parsingVersion () const
 parsingVersion this method return parsing version of Qt. By Default is 0 (last available parsing). see https://doc.qt.io/qt-6/qdatastream.html#Version-enum
 
virtual unsigned int typeId () const
 typeId This method return id of type.
 

Detailed Description

The APIVersion class This is base pacakge class that send information about supported api version on the paired node.

Definition at line 23 of file apiversion.h.

Constructor & Destructor Documentation

◆ APIVersion()

QH::PKG::APIVersion::APIVersion ( )

Definition at line 14 of file apiversion.cpp.

Member Function Documentation

◆ apisVersions()

VersionData QH::PKG::APIVersion::apisVersions ( ) const

Definition at line 32 of file apiversion.cpp.

◆ cmd()

unsigned short QH::PKG::APIVersion::cmd ( ) const
inlineoverridevirtual

cmd - This is command of this object, (for generate cmd use macross QH_PACKAGE)

Note
Use the QH_PACKAGE macross for implement this method.
Returns
global command of package.
See also
QH_PACKAGE

Implements QH::PKG::AbstractData.

Definition at line 33 of file apiversion.h.

Here is the call graph for this function:

◆ cmdString()

QString QH::PKG::APIVersion::cmdString ( ) const
inlineoverridevirtual

cmdString - This is command string of this object, (for generate cmd use macross QH_PACKAGE)

Note
Use the QH_PACKAGE macross for implement this method.
Returns
global command of package.
See also
QH_PACKAGE

Implements QH::PKG::AbstractData.

Definition at line 35 of file apiversion.h.

Here is the call graph for this function:

◆ command()

static unsigned short QH::PKG::APIVersion::command ( )
inlinestatic

Definition at line 29 of file apiversion.h.

Here is the caller graph for this function:

◆ commandText()

static QString QH::PKG::APIVersion::commandText ( )
inlinestatic

Definition at line 32 of file apiversion.h.

Here is the caller graph for this function:

◆ fromStream()

QDataStream & QH::PKG::APIVersion::fromStream ( QDataStream &  stream)
overrideprotectedvirtual

fromStream This method should be read all bytes from the stream object and full the current object.

Note
The implementation of this method should be invoke a method of base class.
Parameters
streamThis is Qt stream object.
Returns
Qt stream object.

Examle of base simple implementation:

QDataStream &ExampleClass::fromStream(QDataStream &stream) const {
stream >> exampleMember;
return stream;
}
virtual QDataStream & toStream(QDataStream &stream) const =0
fromStream This method should be write all members of the current object to the stream object.

Implements QH::StreamBase.

Definition at line 18 of file apiversion.cpp.

◆ isValid()

bool QH::PKG::APIVersion::isValid ( ) const
overridevirtual

isValid This method check current object to valid.

Returns
True if class isValid.

Reimplemented from QH::PKG::AbstractData.

Definition at line 48 of file apiversion.cpp.

Here is the call graph for this function:

◆ packagesVersions()

PackagesVersionData QH::PKG::APIVersion::packagesVersions ( ) const

packagesVersions This method return list of available multi-version packages on the node.

Returns

Definition at line 40 of file apiversion.cpp.

◆ setApisVersions()

void QH::PKG::APIVersion::setApisVersions ( const VersionData newApisVersions)

Definition at line 36 of file apiversion.cpp.

Here is the caller graph for this function:

◆ setPackagesVersions()

void QH::PKG::APIVersion::setPackagesVersions ( const PackagesVersionData newPackagesVersions)

Definition at line 44 of file apiversion.cpp.

◆ toStream()

QDataStream & QH::PKG::APIVersion::toStream ( QDataStream &  stream) const
overrideprotectedvirtual

fromStream This method should be write all members of the current object to the stream object.

Note
The implementation of this method should be invoke a method of base class.
Parameters
streamThis is Qt stream object.
Returns
Qt stream object.

Examle of base simple implementation:

QDataStream &ExampleClass::toStream(QDataStream &stream) const {
stream << exampleMember;
return stream;
}

Implements QH::StreamBase.

Definition at line 25 of file apiversion.cpp.

◆ version()

static unsigned short QH::PKG::APIVersion::version ( )
inlinestatic

Definition at line 30 of file apiversion.h.

Here is the caller graph for this function:

The documentation for this class was generated from the following files: