Spring Social

Class ProviderSignInAttempt

  extended by org.springframework.social.connect.web.ProviderSignInAttempt
All Implemented Interfaces:

public class ProviderSignInAttempt
extends java.lang.Object
implements java.io.Serializable

Models an attempt to sign-in to the application using a provider user identity. Instances are created when the provider sign-in process could not be completed because no local user is associated with the provider user. This could happen because the user has not yet signed up with the application, or has not yet connected their local application identity with the their provider identity. For the former scenario, callers should invoke addConnection(String) post-signup to establish a connection between a new user account and the provider account. For the latter, existing users should sign-in using their local application credentials and formally connect to the provider they also wish to authenticate with.

Keith Donald
See Also:
Serialized Form

Constructor Summary
ProviderSignInAttempt(Connection<?> connection, ConnectionFactoryLocator connectionFactoryLocator, UsersConnectionRepository connectionRepository)
Method Summary
 Connection<?> getConnection()
          Get the connection to the provider user account the client attempted to sign-in as.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail


public ProviderSignInAttempt(Connection<?> connection,
                             ConnectionFactoryLocator connectionFactoryLocator,
                             UsersConnectionRepository connectionRepository)
Method Detail


public Connection<?> getConnection()
Get the connection to the provider user account the client attempted to sign-in as. Using this connection you may fetch a provider user profile and use that to pre-populate a local user registration/signup form. You can also lookup the id of the provider and use that to display a provider-specific user-sign-in-attempt flash message e.g. "Your Facebook Account is not connected to a Local account. Please sign up."

Spring Social