2012-07-05 17:26:14 -04:00
|
|
|
#ifndef P3PHOTOSERVICEV2_H
|
|
|
|
#define P3PHOTOSERVICEV2_H
|
|
|
|
|
2012-07-22 17:38:15 -04:00
|
|
|
/*
|
|
|
|
* libretroshare/src/retroshare: rsphoto.h
|
|
|
|
*
|
|
|
|
* RetroShare C++ Interface.
|
|
|
|
*
|
|
|
|
* Copyright 2008-2012 by Robert Fernie, Christopher Evi-Parker
|
|
|
|
*
|
|
|
|
* This library is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU Library General Public
|
|
|
|
* License Version 2 as published by the Free Software Foundation.
|
|
|
|
*
|
|
|
|
* This library is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
|
* Library General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU Library General Public
|
|
|
|
* License along with this library; if not, write to the Free Software
|
|
|
|
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
|
|
|
|
* USA.
|
|
|
|
*
|
|
|
|
* Please report all bugs and problems to "retroshare@lunamutt.com".
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
2012-07-05 17:26:14 -04:00
|
|
|
#include "gxs/rsgenexchange.h"
|
|
|
|
#include "retroshare/rsphotoV2.h"
|
2012-07-22 17:38:15 -04:00
|
|
|
|
2012-07-05 17:26:14 -04:00
|
|
|
|
|
|
|
class p3PhotoServiceV2 : public RsPhotoV2, public RsGenExchange
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
|
2012-07-22 17:38:15 -04:00
|
|
|
p3PhotoServiceV2(RsGeneralDataService* gds, RsNetworkExchangeService* nes);
|
2012-07-05 17:26:14 -04:00
|
|
|
|
|
|
|
public:
|
|
|
|
|
2012-07-26 17:48:54 -04:00
|
|
|
/*!
|
|
|
|
* @return
|
|
|
|
*/
|
2012-07-05 17:26:14 -04:00
|
|
|
bool updated();
|
|
|
|
|
|
|
|
public:
|
|
|
|
|
|
|
|
/** Requests **/
|
|
|
|
|
|
|
|
void groupsChanged(std::list<std::string>& grpIds);
|
|
|
|
|
|
|
|
|
|
|
|
void msgsChanged(std::map<std::string,
|
|
|
|
std::vector<std::string> >& msgs);
|
|
|
|
|
2012-07-28 16:01:30 -04:00
|
|
|
RsTokenServiceV2* getTokenService();
|
2012-07-05 17:26:14 -04:00
|
|
|
|
|
|
|
bool getGroupList(const uint32_t &token,
|
|
|
|
std::list<std::string> &groupIds);
|
|
|
|
bool getMsgList(const uint32_t &token,
|
2012-07-26 17:48:54 -04:00
|
|
|
GxsMsgIdResult& msgIds);
|
2012-07-05 17:26:14 -04:00
|
|
|
|
|
|
|
/* Generic Summary */
|
|
|
|
bool getGroupSummary(const uint32_t &token,
|
|
|
|
std::list<RsGroupMetaData> &groupInfo);
|
|
|
|
|
|
|
|
bool getMsgSummary(const uint32_t &token,
|
|
|
|
MsgMetaResult &msgInfo);
|
|
|
|
|
|
|
|
/* Specific Service Data */
|
2012-07-26 17:48:54 -04:00
|
|
|
bool getAlbum(const uint32_t &token, std::vector<RsPhotoAlbum> &albums);
|
|
|
|
bool getPhoto(const uint32_t &token, PhotoResult &photos);
|
2012-07-05 17:26:14 -04:00
|
|
|
|
|
|
|
public:
|
|
|
|
|
|
|
|
/** Modifications **/
|
|
|
|
|
2012-07-26 17:48:54 -04:00
|
|
|
bool submitAlbumDetails(RsPhotoAlbum &album);
|
|
|
|
bool submitPhoto(RsPhotoPhoto &photo);
|
2012-07-05 17:26:14 -04:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif // P3PHOTOSERVICEV2_H
|