completely removed TokenQueue from GxsGroupDialog and GxsGroupFrameDialog

This commit is contained in:
csoler 2020-03-22 21:47:14 +01:00
parent 7ba83272cf
commit 6c1f09a53b
No known key found for this signature in database
GPG key ID: 7BCA522266C0804C
26 changed files with 423 additions and 217 deletions

View file

@ -398,6 +398,15 @@ public:
virtual bool subscribeToChannel( const RsGxsGroupId& channelId,
bool subscribe ) = 0;
/**
* \brief Retrieve statistics about the given channel
* @jsonapi{development}
* \param[in] channelId Id of the channel group
* \param[out] stat Statistics structure
* \return
*/
virtual bool getChannelStatistics(const RsGxsGroupId& channelId,GxsGroupStatistic& stat) =0;
/**
* @brief Request remote channels search
* @jsonapi{development}

View file

@ -219,6 +219,15 @@ public:
*/
virtual bool getForumsSummaries(std::list<RsGroupMetaData>& forums) = 0;
/**
* @brief returns statistics about a particular forum
* @jsonapi{development}
* @param[in] forumId Id of the forum
* @param[out] stat statistics struct
* @return false when the object doesn't exist or when the timeout is reached requesting the data
*/
virtual bool getForumStatistics(const RsGxsGroupId& forumId,GxsGroupStatistic& stat)=0;
/**
* @brief Get forums information (description, thumbnail...).
* Blocking API.
@ -361,5 +370,5 @@ public:
RS_DEPRECATED_FOR(createMessage)
virtual bool createMsg(uint32_t &token, RsGxsForumMsg &msg) = 0;
RS_DEPRECATED_FOR(editForum)
virtual bool updateGroup(uint32_t &token, RsGxsForumGroup &group) = 0;
virtual bool updateGroup(uint32_t &token, const RsGxsForumGroup &group) = 0;
};

View file

@ -340,13 +340,14 @@ public:
}
/// @see RsTokenService::requestGroupStatistic
void requestGroupStatistic(uint32_t& token, const RsGxsGroupId& grpId)
bool requestGroupStatistic(uint32_t& token, const RsGxsGroupId& grpId)
{
mTokenService.requestGroupStatistic(token, grpId);
RS_STACK_MUTEX(mMtx);
mActiveTokens[token]=TokenRequestType::GROUP_STATISTICS;
locked_dumpTokens();
return true;
}
bool cancelActiveRequestTokens(TokenRequestType type)

View file

@ -157,6 +157,12 @@ public:
std::vector<RsPostedPost>& posts,
std::vector<RsGxsComment>& comments ) = 0;
virtual bool editBoard(RsPostedGroup& board) =0;
virtual bool createBoard(RsPostedGroup& board) =0;
virtual bool getBoardStatistics(const RsGxsGroupId& boardId,GxsGroupStatistic& stat) =0;
enum RS_DEPRECATED RankType {TopRankType, HotRankType, NewRankType };
RS_DEPRECATED_FOR(getBoardsInfo)