com.force.sdk.oauth.userdata
Class UserDataRetrievalService

java.lang.Object
  extended by com.force.sdk.oauth.userdata.UserDataRetrievalService
Direct Known Subclasses:
CustomUserDataRetrievalService

public class UserDataRetrievalService
extends Object

Used to retrieve data about the authenticated user for storage in the SecurityContext.

Author:
John Simone

Constructor Summary
UserDataRetrievalService()
          Create with a ForceUserDataRetriever.
UserDataRetrievalService(boolean storeUsername)
          Create with the given value for the storeUsername flag.
 
Method Summary
 boolean isStoreUsername()
          Flag stating whether or not the username should be stored.
 SecurityContext retrieveUserData(String sessionId, String endpoint, String refreshToken)
          Set up the user data retriever and use it to retrieve data about the user.
 void setStoreUsername(boolean storeUsername)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

UserDataRetrievalService

public UserDataRetrievalService(boolean storeUsername)
Create with the given value for the storeUsername flag.

Parameters:
storeUsername - boolean

UserDataRetrievalService

public UserDataRetrievalService()
Create with a ForceUserDataRetriever.

Method Detail

retrieveUserData

public SecurityContext retrieveUserData(String sessionId,
                                        String endpoint,
                                        String refreshToken)
                                 throws com.sforce.ws.ConnectionException
Set up the user data retriever and use it to retrieve data about the user.

Parameters:
sessionId - String
endpoint - String
refreshToken - String
Returns:
SecurityContext containing data about the user
Throws:
com.sforce.ws.ConnectionException - connection error

setStoreUsername

public void setStoreUsername(boolean storeUsername)

isStoreUsername

public boolean isStoreUsername()
Flag stating whether or not the username should be stored.

Returns:
boolean


Copyright © 2011. All Rights Reserved.