mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-08-17 10:31:05 -04:00
Got message retrieval working for genexchange across gxs chain
- fixed segv bugs for message retrieval and improved data service meta data retrieval - fixed compile for windows (exposed too many of rs internals in interface!) - fixed msg signing functionality and id creation with ssl - still need to complete photoservice gui and local meta change function git-svn-id: http://svn.code.sf.net/p/retroshare/code/branches/v0.5-gxs-b1@5443 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
5425ab36b5
commit
c17460d1b1
16 changed files with 254 additions and 106 deletions
|
@ -36,6 +36,7 @@
|
|||
#include "serialiser/rsnxsitems.h"
|
||||
#include "gxs/rsgxsdata.h"
|
||||
#include "rsgxs.h"
|
||||
#include "util/retrodb.h"
|
||||
|
||||
|
||||
class RsGxsSearchModule {
|
||||
|
@ -53,6 +54,9 @@ public:
|
|||
*/
|
||||
class MsgLocMetaData {
|
||||
|
||||
public:
|
||||
RsGxsGrpMsgIdPair msgId;
|
||||
ContentValue val;
|
||||
};
|
||||
|
||||
/*!
|
||||
|
@ -61,11 +65,14 @@ class MsgLocMetaData {
|
|||
*/
|
||||
class GrpLocMetaData {
|
||||
|
||||
public:
|
||||
RsGxsGroupId grpId;
|
||||
ContentValue val;
|
||||
|
||||
};
|
||||
|
||||
//typedef std::map<RsGxsGroupId, std::vector<RsGxsMessageId> > GxsMsgReq; // <grpId, msgIds>
|
||||
|
||||
//typedef std::map<RsGxsGroupId, std::vector<RsGxsMsgMetaData*> > GxsMsgMetaResult; // <grpId, msg metadatas>
|
||||
typedef std::map<RsGxsGroupId, std::vector<RsNxsMsg*> > NxsMsgDataResult;
|
||||
typedef std::map<RsGxsGroupId, std::vector<RsNxsMsg*> > GxsMsgResult; // <grpId, msgs>
|
||||
|
||||
/*!
|
||||
* The main role of GDS is the preparation and handing out of messages requested from
|
||||
|
@ -103,7 +110,7 @@ public:
|
|||
* @param cache whether to store results of this retrieval in memory for faster later retrieval
|
||||
* @return error code
|
||||
*/
|
||||
virtual int retrieveNxsMsgs(const GxsMsgReq& reqIds, GxsMsgResult& msg, bool cache) = 0;
|
||||
virtual int retrieveNxsMsgs(const GxsMsgReq& reqIds, GxsMsgResult& msg, bool cache, bool withMeta=false) = 0;
|
||||
|
||||
/*!
|
||||
* Retrieves all groups stored
|
||||
|
@ -130,7 +137,7 @@ public:
|
|||
* @param cache whether to store retrieval in mem for faster later retrieval
|
||||
* @return error code
|
||||
*/
|
||||
virtual int retrieveGxsMsgMetaData(const std::vector<RsGxsGroupId>& grpIds, GxsMsgMetaResult& msgMeta) = 0;
|
||||
virtual int retrieveGxsMsgMetaData(GxsMsgReq& grpIds, GxsMsgMetaResult& msgMeta) = 0;
|
||||
|
||||
/*!
|
||||
* remove msgs in data store listed in msgIds param
|
||||
|
@ -174,12 +181,12 @@ public:
|
|||
/*!
|
||||
* @param metaData
|
||||
*/
|
||||
virtual int updateMessageMetaData(MsgLocMetaData* metaData) = 0;
|
||||
virtual int updateMessageMetaData(MsgLocMetaData& metaData) = 0;
|
||||
|
||||
/*!
|
||||
* @param metaData
|
||||
*/
|
||||
virtual int updateGroupMetaData(GrpLocMetaData* meta) = 0;
|
||||
virtual int updateGroupMetaData(GrpLocMetaData& meta) = 0;
|
||||
|
||||
|
||||
/*!
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue