21 #ifndef CLASSIFIED_CLASSIFIEDADMODEL_H 22 #define CLASSIFIED_CLASSIFIEDADMODEL_H 23 #include <QSqlDatabase> 24 #include "../mcontroller.h" 25 #include "../net/protocol.h" 27 #include <QStringList> 144 QByteArray& aResultingCaData,
145 QByteArray& aResultingSignature,
146 QByteArray& aPublicKeyOfPublisher,
147 quint32* aTimeOfPublish = NULL ) ;
171 const QByteArray& aContent,
172 const QByteArray& aSignature,
173 const QList<quint32>& aBangPath,
174 const QByteArray& aKeyOfPublisher,
175 const unsigned char aFlags,
176 const quint32 aTimeStamp,
177 const Hash& aFromNode ) ;
193 const QByteArray& aContent,
194 const QByteArray& aSignature,
195 const QByteArray& aKeyOfPublisher,
196 const unsigned char aFlags,
197 const quint32 aTimeStamp,
198 const Hash& aFromNode ) ;
227 void fillBucket(QList<SendQueueItem>& aSendQueue,
228 const Hash& aStartOfBucket,
229 const Hash& aEndOfBucket,
230 quint32 aLastMutualConnectTime,
231 const Hash& aForNode );
248 QList<QPair<Hash,quint32> >& aResultingArticles,
249 const Hash& aRequestingNode ) ;
265 const Hash& aRequestingNode,
266 const Hash& aClassification) ;
278 const QString& aExplanation) ;
286 const Hash& aHashOfClassification,
295 const QByteArray& aContent,
296 const QByteArray& aSignature,
297 const QList<quint32>& aBangPath,
298 const QByteArray& aKeyOfPublisher,
299 const unsigned char aFlags,
300 const quint32 aTimeStamp,
302 const Hash& aFromNode ) ;
ClassifiedAdsModel(MController *aMController, const MModelProtocolInterface &aModel)
const QStringList & aboutComboBoxTexts() const
QStringList iRegardingComboBoxTexts
Definition: camodel.h:310
void fillBucket(QList< SendQueueItem > &aSendQueue, const Hash &aStartOfBucket, const Hash &aEndOfBucket, quint32 aLastMutualConnectTime, const Hash &aForNode)
QStringList iAboutComboBoxTexts
Definition: camodel.h:309
virtual void newCaReceived(const CA &aNewCa)=0
const MModelProtocolInterface & iModel
Definition: camodel.h:307
QList< CAObserver * > * iNewCaObservers
Definition: camodel.h:308
QString localizedPurposeOfAdString(PurposeOfAd aPurpose) const
ConcernOfAd
Definition: camodel.h:60
bool caListingByClassificationReceived(QList< QPair< Hash, quint32 > > &aReceivedArticles, const Hash &aRequestingNode, const Hash &aClassification)
Hash is class that carries 160-bit digest.
Definition: hash.h:38
CAErrorSituation
Definition: mcontroller.h:57
const QString & concernOfAdString(ConcernOfAd aConcern) const
CA caByHash(const Hash &aFingerPrint)
bool caDataForPublish(const Hash &aFingerPrint, QByteArray &aResultingCaData, QByteArray &aResultingSignature, QByteArray &aPublicKeyOfPublisher, quint32 *aTimeOfPublish=NULL)
ProtocolItemType
Definition: protocol.h:157
This is part of datamodel for storage/retrieval of classified ads.
Definition: camodel.h:40
const QStringList & regardingComboBoxTexts() const
bool sentCAReceived(const Hash &aFingerPrint, const QByteArray &aContent, const QByteArray &aSignature, const QByteArray &aKeyOfPublisher, const unsigned char aFlags, const quint32 aTimeStamp, const Hash &aFromNode)
bool doHandleReceivedCA(const Hash &aFingerPrint, const QByteArray &aContent, const QByteArray &aSignature, const QList< quint32 > &aBangPath, const QByteArray &aKeyOfPublisher, const unsigned char aFlags, const quint32 aTimeStamp, bool aWasPublish, const Hash &aFromNode)
Carrier-class for classified ad.
Definition: ca.h:35
Pure-virtual interface of datamodel for message parser to use.
Definition: mmodelprotocolinterface.h:46
const QStringList & whereComboBoxTexts() const
Pure-virtual interface class for controller. This is spammed across parties needing access to applica...
Definition: mcontroller.h:48
datamodel-parts common part. this is inherited and contains common funcs
Definition: datamodelbase.h:39
bool publishedCAReceived(const Hash &aFingerPrint, const QByteArray &aContent, const QByteArray &aSignature, const QList< quint32 > &aBangPath, const QByteArray &aKeyOfPublisher, const unsigned char aFlags, const quint32 aTimeStamp, const Hash &aFromNode)
void reIndexAllAdsIntoFTS()
void removeCAObserver(CAObserver *aObserver)
void caListingByClassification(const Hash &aClassificationHash, quint32 aStartDate, quint32 aEndDate, QList< QPair< Hash, quint32 > > &aResultingArticles, const Hash &aRequestingNode)
MController * iController
Definition: camodel.h:306
void installCAObserver(CAObserver *aObserver)
QStringList iWhereComboBoxTexts
Definition: camodel.h:311
void contentReceived(const Hash &aHashOfContent, const Hash &aHashOfClassification, const ProtocolItemType aTypeOfReceivdContent)
const QString & purposeOfAdString(PurposeOfAd aPurpose) const
Hash publishClassifiedAd(const Profile &aPublishingProfile, CA &aAd)
Carrier-class for user-profile data.
Definition: profile.h:37
QString localizedConcernOfAdString(ConcernOfAd aConcern) const
void error(MController::CAErrorSituation aError, const QString &aExplanation)
PurposeOfAd
Definition: camodel.h:48