org.wso2.solutions.identity.openid.extensions
Class OpenIDSimpleReg

java.lang.Object
  extended by org.wso2.solutions.identity.openid.extensions.OpenIDExtension
      extended by org.wso2.solutions.identity.openid.extensions.OpenIDSimpleReg

public class OpenIDSimpleReg
extends OpenIDExtension


Constructor Summary
OpenIDSimpleReg(OpenIDAuthenticationRequest request)
          Constructed during building the response
 
Method Summary
 void addRequiredAttributes(java.util.List<java.lang.String> requiredAttributes)
           
 org.openid4java.message.MessageExtension getMessageExtension(java.lang.String userId, java.lang.String profileName)
          Creates an instance of MessageExtension for the OpenID authentication response
protected  java.util.Map<java.lang.String,OpenIDClaim> populateAttributeValues(java.util.List<java.lang.String> requiredClaims, java.lang.String userId, java.lang.String profileName)
          Populate the required claims with claim values.
protected  void setSimpleAttributeRegistrationValues(org.openid4java.message.sreg.SRegResponse response, java.util.Map<java.lang.String,OpenIDClaim> claimValues)
          Populate the response with claim values.
 
Methods inherited from class org.wso2.solutions.identity.openid.extensions.OpenIDExtension
mapToAttriId, populateAttributeValues
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OpenIDSimpleReg

public OpenIDSimpleReg(OpenIDAuthenticationRequest request)
Constructed during building the response

Parameters:
request - An instance of OpenIDAuthenticationRequest
Method Detail

addRequiredAttributes

public void addRequiredAttributes(java.util.List<java.lang.String> requiredAttributes)
                           throws IdentityProviderException
Specified by:
addRequiredAttributes in class OpenIDExtension
Throws:
IdentityProviderException

getMessageExtension

public org.openid4java.message.MessageExtension getMessageExtension(java.lang.String userId,
                                                                    java.lang.String profileName)
                                                             throws IdentityProviderException
Creates an instance of MessageExtension for the OpenID authentication response

Specified by:
getMessageExtension in class OpenIDExtension
Parameters:
request - OpenID authentication request
Returns:
An instance of MessageExtension
Throws:
RelyingPartyException
IdentityProviderException

setSimpleAttributeRegistrationValues

protected void setSimpleAttributeRegistrationValues(org.openid4java.message.sreg.SRegResponse response,
                                                    java.util.Map<java.lang.String,OpenIDClaim> claimValues)
                                             throws org.openid4java.message.MessageException
Populate the response with claim values. If we can't find the required values with us, we simply avoid sending them. An Identity Provider MAY return any subset of the following fields in response to the query.

Parameters:
response - Simple Registration response.
claimValues - Claim values.
Throws:
org.openid4java.message.MessageException

populateAttributeValues

protected java.util.Map<java.lang.String,OpenIDClaim> populateAttributeValues(java.util.List<java.lang.String> requiredClaims,
                                                                              java.lang.String userId,
                                                                              java.lang.String profileName)
                                                                       throws IdentityProviderException
Populate the required claims with claim values.

Parameters:
requiredClaims - Required claims as requested by the RP.
userId - User ID.
Returns:
A map, populated with required claim values.
Throws:
IdentityProviderException