Package lumis.socialnetworkintegration
Interface ISocialNetworkConnector
-
- All Known Implementing Classes:
FacebookConnector
,TwitterConnector
public interface ISocialNetworkConnector
The implementations of this interface should execute low level calls to the remote social network it belongs to.- Since:
- 6.1.0
- Version:
- $Revision: 13752 $ $Date: 2011-10-13 14:10:51 -0300 (Thu, 13 Oct 2011) $
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description String
buildAuthenticationURL(String callbackURL, SocialNetworkApplication application, Map<String,Object> stored)
Builds the Authentication URL for the social network.void
callback(String returnedValue, SocialNetworkAccount account, Map<String,Object> stored)
Executes the callback after application/account authorization.String
publish(SocialNetworkMessage message)
Calls the social network's publish method (varies according to network).void
remove(SocialNetworkMessage message)
Calls the social network's remove method (varies according to network) if there is one.String
update(SocialNetworkMessage message)
Calls the social network's update method (varies according to network) if there is one.
-
-
-
Method Detail
-
publish
String publish(SocialNetworkMessage message) throws PortalException
Calls the social network's publish method (varies according to network).- Parameters:
message
- the message to be published.- Returns:
- the remote message id.
- Throws:
PortalException
- Since:
- 6.1.0
-
remove
void remove(SocialNetworkMessage message) throws PortalException
Calls the social network's remove method (varies according to network) if there is one.- Parameters:
message
- the message to be removed.- Throws:
PortalException
- Since:
- 6.1.0
-
update
String update(SocialNetworkMessage message) throws PortalException
Calls the social network's update method (varies according to network) if there is one.- Parameters:
message
- the message to be updated.- Returns:
- the remote message id.
- Throws:
PortalException
- Since:
- 6.1.0
-
buildAuthenticationURL
String buildAuthenticationURL(String callbackURL, SocialNetworkApplication application, Map<String,Object> stored) throws PortalException
Builds the Authentication URL for the social network. Will store any needed values to be used in call back in thestored
object.- Parameters:
callbackURL
- String representing the url that should be called after the first step of authentication is taken.application
- SocialNetworkApplication contaning configuration specific values.stored
- Map to store object created by this method and that will be used in thecallback(String, SocialNetworkAccount, Map)
method.- Returns:
- String to where the portal should redirect user to.
- Throws:
PortalException
- Since:
- 6.1.0
-
callback
void callback(String returnedValue, SocialNetworkAccount account, Map<String,Object> stored) throws PortalException
Executes the callback after application/account authorization. ResponseAuthentication will be put in account.- Parameters:
returnedValue
- value returned by original call/redirect from social network authorization.account
- Social network account to which the validation will occur.stored
- Map that has the objects created inbuildAuthenticationURL(String, SocialNetworkApplication, Map)
to be used in callback.- Throws:
PortalException
- Since:
- 6.1.0
-
-