My Project
SallyAPI::Facebook::CFacebookManager Class Reference

Manager for facebooks. More...

#include <FacebookManager.h>

List of all members.

Public Member Functions

bool IsEnabled ()
 Query if this object is enabled.
std::string RequestData (const std::string &action, std::map< std::string, std::string > &requestMap, std::string &errorMessage, SallyAPI::Network::NETWORK_RETURN &errorCode)
 Request data.
bool SendData (const std::string &action, std::map< std::string, std::string > &requestMap)
 Send data.
bool SendStatusMessage (const std::string &explicidAppName, const std::string &appName, const std::string &message, const std::string &action, const std::string &actionName)
 Send status message.
void SendUpdateToRegistedNotifier ()
 Send update to registed notifier.
void RegisterStatusUpdateNotifier (SallyAPI::GUI::CGUIBaseObject *window)
 Register status update notifier.
bool UpdateFacebookUserInfo ()
 Updates a facebook user information.
std::string GetFacebookUserName ()
 Gets the facebook user name.
std::string GetFacebookUserId ()
 Gets the facebook user identifier.
std::string GetSallyKey ()
 Gets the sally key.
std::string GetFacebookAccessToken ()
 Gets the facebook access token.
void SetFacebookUserName (const std::string &userName)
 Sets a user name.
void Disable ()
 Disables this object.
void Enable (const std::string &accessToken, const std::string &userName, const std::string &userId)
 Enables.
bool ActivateFacebook ()
 Activates a facebook.
void ConnectFacebook ()
 Connects the facebook. Requests a token from Facebook.
void ShowErrorMessage (SallyAPI::GUI::CGUIBaseObject *mainWindow)
 Shows the a popup error message. Is called when the facebook connect is not working anymore.
bool PostMessageToWall (const std::string &message, const std::string &description, const std::string &link, const std::string &image, std::string &errorMessage)
 Post message to wall.
bool GetWall (std::string &dataResponse, std::string &errorMessage, SallyAPI::Network::NETWORK_RETURN &errorCode)
 Gets the messages from the wall of the logged in facebook user.
bool GetNews (std::string &dataResponse, std::string &errorMessage, SallyAPI::Network::NETWORK_RETURN &errorCode)
int GetFacebookUserImageId (const std::string &userId)
void DownloadFacebookUserImage (const std::string &imageFolder, const std::string &userId)
 Downloads a facebook user image.
bool ReloadAllFacebookUserImages ()
bool LoadFacebookUserImage (const std::string &userId)
 Loads a facebook user image.

Static Public Member Functions

static
SallyAPI::Facebook::CFacebookManager
GetInstance ()
 Gets the instance.
static void DeleteInstance ()
 Deletes an instance.

Detailed Description

Manager for facebooks.

Author:
Christian Knobloch
Date:
24.12.2010

Member Function Documentation

Activates a facebook.

Author:
Christian Knobloch
Date:
24.12.2010
Returns:
true if it succeeds, false if it fails.

Connects the facebook. Requests a token from Facebook.

Author:
Christian Knobloch
Date:
24.12.2010

Deletes an instance.

Author:
Christian Knobloch
Date:
19.04.2010

Disables this object.

Author:
Christian Knobloch
Date:
23.12.2010
void CFacebookManager::DownloadFacebookUserImage ( const std::string &  imageFolder,
const std::string &  userId 
)

Downloads a facebook user image.

Author:
Christian Knobloch
Date:
27.12.2010
Parameters:
imageFolderPathname of the image folder.
userIdIdentifier for the user.
void CFacebookManager::Enable ( const std::string &  accessToken,
const std::string &  userName,
const std::string &  userId 
)

Enables.

Author:
Christian Knobloch
Date:
23.12.2010
Parameters:
accessTokenThe access token.
userNameName of the user.
userIdIdentifier for the user.
sallyKeyThe sally key.

Gets the facebook access token.

Author:
Christian Knobloch
Date:
23.12.2010
Returns:
The facebook access token.

Gets the facebook user identifier.

Author:
Christian Knobloch
Date:
23.12.2010
Returns:
The facebook user identifier.
int CFacebookManager::GetFacebookUserImageId ( const std::string &  userId)

Gets the facebook user name.

Author:
Christian Knobloch
Date:
23.12.2010
Returns:
The facebook user name.

Gets the instance.

Author:
Christian Knobloch
Date:
19.04.2010
Returns:
null if it fails, else the instance.
bool CFacebookManager::GetNews ( std::string &  dataResponse,
std::string &  errorMessage,
SallyAPI::Network::NETWORK_RETURN errorCode 
)

Gets the sally key.

Author:
Christian Knobloch
Date:
23.12.2010
Returns:
The sally key.
bool CFacebookManager::GetWall ( std::string &  dataResponse,
std::string &  errorMessage,
SallyAPI::Network::NETWORK_RETURN errorCode 
)

Gets the messages from the wall of the logged in facebook user.

Author:
Christian Knobloch
Date:
19.08.2011
Parameters:
[in,out]dataResponseThe data response.
[in,out]errorMessageMessage describing the error.
[in,out]errorCodeThe error code.
Returns:
true if it succeeds, false if it fails.

Query if this object is enabled.

Author:
Christian Knobloch
Date:
19.04.2010
Returns:
true if enabled, false if not.
bool CFacebookManager::LoadFacebookUserImage ( const std::string &  userId)

Loads a facebook user image.

Author:
Christian Knobloch
Date:
27.12.2010
Parameters:
userIdIdentifier for the user.
Returns:
true if it succeeds, false if it fails.
bool CFacebookManager::PostMessageToWall ( const std::string &  message,
const std::string &  description,
const std::string &  link,
const std::string &  image,
std::string &  errorMessage 
)

Post message to wall.

Author:
Christian Knobloch
Date:
24.12.2010
Parameters:
messageThe message.
descriptionThe description.
linkThe link.
imageThe image.
[in,out]errorMessageMessage describing the error.
Returns:
true if it succeeds, false if it fails.

Register status update notifier.

Author:
Christian Knobloch
Date:
19.04.2010
Parameters:
[in,out]windowIf non-null, the window.
bool false if it fails *bool CFacebookManager::ReloadAllFacebookUserImages ( )
std::string CFacebookManager::RequestData ( const std::string &  action,
std::map< std::string, std::string > &  requestMap,
std::string &  errorMessage,
SallyAPI::Network::NETWORK_RETURN errorCode 
)

Request data.

Author:
Christian Knobloch
Date:
28.01.2011
Parameters:
actionThe action.
[in,out]requestMapThe request map.
[in,out]errorMessageMessage describing the error.
[in,out]errorCodeThe error code.
Returns:
.
bool CFacebookManager::SendData ( const std::string &  action,
std::map< std::string, std::string > &  requestMap 
)

Send data.

Author:
Christian Knobloch
Date:
19.04.2010
Parameters:
actionThe action.
[in,out]requestMapThe request map.
Returns:
true if it succeeds, false if it fails.
bool CFacebookManager::SendStatusMessage ( const std::string &  explicidAppName,
const std::string &  appName,
const std::string &  message,
const std::string &  action,
const std::string &  actionName 
)

Send status message.

Author:
Christian Knobloch
Date:
19.04.2010
Parameters:
explicidAppNameName of the explicid application.
appNameName of the application.
messageThe message.
actionThe action.
actionNameName of the action.
Returns:
true if it succeeds, false if it fails.

Send update to registed notifier.

Author:
Christian Knobloch
Date:
19.04.2010
void CFacebookManager::SetFacebookUserName ( const std::string &  userName)

Sets a user name.

Author:
Christian Knobloch
Date:
24.12.2010
Parameters:
userNameName of the user.

Shows the a popup error message. Is called when the facebook connect is not working anymore.

Author:
Christian Knobloch
Date:
24.12.2010
Parameters:
[in,out]mainWindowIf non-null, the main window.

Updates a facebook user information.

Author:
Christian Knobloch
Date:
23.12.2010
Returns:
true if it succeeds, false if it fails.

The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Defines