2008-04-20 07:11:03 -04:00
|
|
|
#ifndef RSQBLOG_H_
|
|
|
|
#define RSQBLOG_H_
|
|
|
|
|
|
|
|
/*
|
2008-04-22 04:19:02 -04:00
|
|
|
* libretroshare/src/rsiface: rsQblog.h
|
2008-04-20 07:11:03 -04:00
|
|
|
*
|
|
|
|
* RetroShare C++ Interface.
|
|
|
|
*
|
2008-04-22 04:19:02 -04:00
|
|
|
* Copyright 2007-2008 by Chris Parker, Robert Fernie.
|
2008-04-20 07:11:03 -04:00
|
|
|
*
|
|
|
|
* 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".
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
|
|
|
#include <iostream>
|
2008-05-08 20:30:29 -04:00
|
|
|
#include <string>
|
2008-04-20 07:11:03 -04:00
|
|
|
#include <list>
|
|
|
|
#include <map>
|
|
|
|
|
|
|
|
|
|
|
|
|
2008-04-22 04:19:02 -04:00
|
|
|
|
|
|
|
/*! allows gui to interface with the rsQblogs service */
|
|
|
|
class RsQblog
|
2008-04-20 07:11:03 -04:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
|
|
|
|
|
2008-04-22 04:19:02 -04:00
|
|
|
RsQblog() { return; }
|
|
|
|
virtual ~RsQblog() { return; }
|
2008-04-20 07:11:03 -04:00
|
|
|
|
|
|
|
/**
|
|
|
|
* allow user to set his status
|
|
|
|
* @param status The status of the user
|
|
|
|
*/
|
|
|
|
virtual bool setStatus(std::string &status) = 0;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* get status of users friends
|
|
|
|
*
|
|
|
|
**/
|
2008-04-22 04:19:02 -04:00
|
|
|
virtual bool getStatus(std::string &status) = 0;
|
2008-04-20 07:11:03 -04:00
|
|
|
|
|
|
|
/**
|
|
|
|
* choose whether to filter or not
|
|
|
|
* @param filterSwitch
|
|
|
|
**/
|
2008-05-08 20:30:29 -04:00
|
|
|
virtual bool setFilterSwitch(bool &filterSwitch) = 0;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* get usrs friend list
|
|
|
|
* @ param usrList
|
|
|
|
*/
|
|
|
|
virtual bool getFriendList(std::list<std::string> &friendList) =0;
|
2008-04-20 07:11:03 -04:00
|
|
|
|
|
|
|
/**
|
|
|
|
* retrieve usrs filterSwitch status
|
|
|
|
**/
|
|
|
|
virtual bool getFilterSwitch(void) = 0;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* add user id to filter list
|
|
|
|
* @param usr id to add to filter list
|
|
|
|
**/
|
2008-05-08 20:30:29 -04:00
|
|
|
virtual bool addToFilter(std::string &usrId) = 0;
|
2008-04-20 07:11:03 -04:00
|
|
|
|
|
|
|
/**
|
|
|
|
* remove friend from filter list
|
|
|
|
* @param id The user's frined's id
|
|
|
|
**/
|
2008-05-08 20:30:29 -04:00
|
|
|
virtual bool removeFiltFriend(std::string &usrId) = 0;
|
2008-04-20 07:11:03 -04:00
|
|
|
|
|
|
|
/**
|
2008-05-08 20:30:29 -04:00
|
|
|
* get users fav song
|
|
|
|
* @param usrId the usr whose fav song you want
|
|
|
|
* @param favSong puts ref for fav song here
|
2008-04-20 07:11:03 -04:00
|
|
|
*/
|
2008-05-08 20:30:29 -04:00
|
|
|
virtual bool getProfile(std::string &usrId, std::string &favSong) = 0;
|
|
|
|
|
|
|
|
|
2008-04-20 07:11:03 -04:00
|
|
|
|
|
|
|
/**
|
2008-05-08 20:30:29 -04:00
|
|
|
* for now just fav song, TODO: must find way to link to rs profile
|
2008-04-20 07:11:03 -04:00
|
|
|
*/
|
2008-05-08 20:30:29 -04:00
|
|
|
virtual bool setProfile(std::string &favSong) = 0;
|
2008-04-20 07:11:03 -04:00
|
|
|
|
|
|
|
/**
|
2008-05-08 20:30:29 -04:00
|
|
|
* send blog info, will send to a data structure for transmission
|
|
|
|
* @param msg The msg the usr wants to send
|
2008-04-20 07:11:03 -04:00
|
|
|
*/
|
2008-05-08 20:30:29 -04:00
|
|
|
virtual bool sendBlog(std::string &msg) = 0;
|
2008-04-20 07:11:03 -04:00
|
|
|
|
|
|
|
/**
|
2008-05-08 20:30:29 -04:00
|
|
|
* retrieve blog of a usr
|
|
|
|
* @param blogs contains the blog msgs of usr along with time posted for sorting
|
2008-04-20 07:11:03 -04:00
|
|
|
*/
|
2008-05-08 20:30:29 -04:00
|
|
|
virtual bool getBlogs(std::map< std::string, std::multimap<long int, std:: string> > &blogs) = 0;
|
2008-04-20 07:11:03 -04:00
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif /*RSQBLOG_H_*/
|