21 #ifndef CLASSIFIED_PROFILEMODEL_H 22 #define CLASSIFIED_PROFILEMODEL_H 23 #include <QSqlDatabase> 24 #include "../mcontroller.h" 25 #include "../net/connection.h" 81 bool aEmitErrorOnEncryptionErrors =
true,
82 bool aOmitImage =
false ) ;
107 QByteArray& aResultingProfileData,
108 QByteArray& aResultingSignature,
109 bool* aIsProfilePrivate,
110 quint32* aTimeOfPublish = NULL,
111 QByteArray* aResultingPublicKey = NULL ) ;
129 const QByteArray& aContent,
130 const QByteArray& aSignature,
131 const QList<quint32>& aBangPath,
132 const QByteArray& aProfilePublicKey,
133 const unsigned char aFlags,
134 const quint32 aTimeStamp,
135 const Hash& aFromNode) ;
150 const QByteArray& aContent,
151 const QByteArray& aSignature,
152 const QByteArray& aProfilePublicKey,
153 const unsigned char aFlags,
154 const quint32 aTimeStamp,
155 const Hash& fromNode ) ;
175 void fillBucket(QList<SendQueueItem>& aSendQueue,
176 const Hash& aStartOfBucket,
177 const Hash& aEndOfBucket,
178 quint32 aLastMutualConnectTime,
179 const Hash& aForNode );
199 const Hash& aProfile ) ;
207 const QVariant& aPrivateData ) ;
233 const QByteArray& aContent,
234 const QByteArray& aSignature,
235 const QList<quint32>& aBangPath,
236 const QByteArray& aProfilePublicKey,
237 const unsigned char aFlags,
238 const quint32 aTimeStamp,
240 const Hash& aFromNode ) ;
247 const QString& aExplanation) ;
QVariant privateDataOfProfile(const Hash &aProfile)
bool profileDataByFingerPrint(const Hash &aFingerPrint, QByteArray &aResultingProfileData, QByteArray &aResultingSignature, bool *aIsProfilePrivate, quint32 *aTimeOfPublish=NULL, QByteArray *aResultingPublicKey=NULL)
bool publishProfile(const Profile &aProfile)
const MModelProtocolInterface & iModel
Definition: profilemodel.h:253
Hash is class that carries 160-bit digest.
Definition: hash.h:38
CAErrorSituation
Definition: mcontroller.h:52
ProfileModel(MController *aMController, const MModelProtocolInterface &aModel)
ProtocolItemType
Definition: protocol.h:150
time_t getLastProfileUpdateTime(const Hash &aProfile)
MController * iController
Definition: profilemodel.h:252
Hash profileWithOldestTimeSinceMsgPoll(quint32 *aLastPollTime)
Pure-virtual interface of datamodel for message parser to use.
Definition: mmodelprotocolinterface.h:45
void setPrivateMessagePollTimeForProfile(const quint32 aTimeStamp, const Hash &aProfile)
Pure-virtual interface class for controller. This is spammed across parties needing access to applica...
Definition: mcontroller.h:43
void fillBucket(QList< SendQueueItem > &aSendQueue, const Hash &aStartOfBucket, const Hash &aEndOfBucket, quint32 aLastMutualConnectTime, const Hash &aForNode)
datamodel-parts common part. this is inherited and contains common funcs
Definition: datamodelbase.h:39
bool sentProfileReceived(const Hash &aFingerPrint, const QByteArray &aContent, const QByteArray &aSignature, const QByteArray &aProfilePublicKey, const unsigned char aFlags, const quint32 aTimeStamp, const Hash &fromNode)
This is is part of datamodel for storing user profiles.
Definition: profilemodel.h:39
Profile * profileByFingerPrint(const Hash &aFingerPrint, bool aEmitErrorOnEncryptionErrors=true, bool aOmitImage=false)
bool publishedProfileReceived(const Hash &aFingerPrint, const QByteArray &aContent, const QByteArray &aSignature, const QList< quint32 > &aBangPath, const QByteArray &aProfilePublicKey, const unsigned char aFlags, const quint32 aTimeStamp, const Hash &aFromNode)
virtual bool deleteOldestDataRowInTable()
void setLastProfileUpdateTime(const Hash &aProfile, time_t aTime)
Carrier-class for user-profile data.
Definition: profile.h:37
void error(MController::CAErrorSituation aError, const QString &aExplanation)
void contentReceived(const Hash &aHashOfContent, const ProtocolItemType aTypeOfReceivdContent)
void setPrivateDataForProfile(const Hash &aProfile, const QVariant &aPrivateData)
void reIndexAllProfilesIntoFTS()
bool doHandlepublishedOrSentProfile(const Hash &aFingerPrint, const QByteArray &aContent, const QByteArray &aSignature, const QList< quint32 > &aBangPath, const QByteArray &aProfilePublicKey, const unsigned char aFlags, const quint32 aTimeStamp, bool aWasPublish, const Hash &aFromNode)