|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.nimbusds.openid.connect.sdk.claims.ClaimsSet com.nimbusds.openid.connect.sdk.claims.UserInfo
public class UserInfo
UserInfo claims set, serialisable to a JSON object.
Example UserInfo claims set:
{ "sub" : "248289761001", "name" : "Jane Doe", "given_name" : "Jane", "family_name" : "Doe", "preferred_username" : "j.doe", "email" : "[email protected]", "picture" : "http://example.com/janedoe/me.jpg" }
Related specifications:
Constructor Summary | |
---|---|
UserInfo(net.minidev.json.JSONObject jsonObject)
Creates a new UserInfo claims set from the specified JSON object. |
|
UserInfo(Subject sub)
Creates a new minimal UserInfo claims set. |
Method Summary | |
---|---|
Address |
getAddress()
Gets the preferred address. |
Address |
getAddress(com.nimbusds.langtag.LangTag langTag)
Gets the preferred address. |
Map<com.nimbusds.langtag.LangTag,Address> |
getAddressEntries()
Gets the preferred address entries. |
String |
getBirthdate()
Gets the date of birth. |
javax.mail.internet.InternetAddress |
getEmail()
Gets the preferred email address. |
Boolean |
getEmailVerified()
Gets the email verification status. |
String |
getFamilyName()
Gets the surname or last name. |
String |
getFamilyName(com.nimbusds.langtag.LangTag langTag)
Gets the surname or last name. |
Map<com.nimbusds.langtag.LangTag,String> |
getFamilyNameEntries()
Gets the surname or last name entries. |
Gender |
getGender()
Gets the gender. |
String |
getGivenName()
Gets the given or first name. |
String |
getGivenName(com.nimbusds.langtag.LangTag langTag)
Gets the given or first name. |
Map<com.nimbusds.langtag.LangTag,String> |
getGivenNameEntries()
Gets the given or first name entries. |
String |
getLocale()
Gets the locale. |
String |
getMiddleName()
Gets the middle name. |
String |
getMiddleName(com.nimbusds.langtag.LangTag langTag)
Gets the middle name. |
Map<com.nimbusds.langtag.LangTag,String> |
getMiddleNameEntries()
Gets the middle name entries. |
String |
getName()
Gets the full name. |
String |
getName(com.nimbusds.langtag.LangTag langTag)
Gets the full name. |
Map<com.nimbusds.langtag.LangTag,String> |
getNameEntries()
Gets the full name entries. |
String |
getNickname()
Gets the casual name. |
String |
getNickname(com.nimbusds.langtag.LangTag langTag)
Gets the casual name. |
Map<com.nimbusds.langtag.LangTag,String> |
getNicknameEntries()
Gets the casual name entries. |
String |
getPhoneNumber()
Gets the preferred telephone number. |
Boolean |
getPhoneNumberVerified()
Gets the phone number verification status. |
URL |
getPicture()
Gets the picture. |
String |
getPreferredUsername()
Gets the preferred username. |
URL |
getProfile()
Gets the profile page. |
static Set<String> |
getStandardClaimNames()
Gets the names of the standard top-level UserInfo claims. |
Subject |
getSubject()
Gets the UserInfo subject. |
Date |
getUpdatedTime()
Gets the time the end-user information was last updated. |
URL |
getWebsite()
Gets the web page or blog. |
String |
getZoneinfo()
Gets the zoneinfo. |
void |
setAddress(Address address)
Sets the preferred address. |
void |
setAddress(Address address,
com.nimbusds.langtag.LangTag langTag)
Sets the preferred address. |
void |
setBirthdate(String birthdate)
Sets the date of birth. |
void |
setEmail(javax.mail.internet.InternetAddress email)
Sets the preferred email address. |
void |
setEmailVerified(Boolean emailVerified)
Sets the email verification status. |
void |
setFamilyName(String familyName)
Sets the surname or last name. |
void |
setFamilyName(String familyName,
com.nimbusds.langtag.LangTag langTag)
Sets the surname or last name. |
void |
setGender(Gender gender)
Sets the gender. |
void |
setGivenName(String givenName)
Sets the given or first name. |
void |
setGivenName(String givenName,
com.nimbusds.langtag.LangTag langTag)
Sets the given or first name. |
void |
setLocale(String locale)
Sets the locale. |
void |
setMiddleName(String middleName)
Sets the middle name. |
void |
setMiddleName(String middleName,
com.nimbusds.langtag.LangTag langTag)
Sets the middle name. |
void |
setName(String name)
Sets the full name. |
void |
setName(String name,
com.nimbusds.langtag.LangTag langTag)
Sets the full name. |
void |
setNickname(String nickname)
Sets the casual name. |
void |
setNickname(String nickname,
com.nimbusds.langtag.LangTag langTag)
Sets the casual name. |
void |
setPhoneNumber(String phoneNumber)
Sets the preferred telephone number. |
void |
setPhoneNumberVerified(Boolean phoneNumberVerified)
Sets the email verification status. |
void |
setPicture(URL picture)
Sets the picture. |
void |
setPreferredUsername(String preferredUsername)
Sets the preferred username. |
void |
setProfile(URL profile)
Sets the profile page. |
void |
setUpdatedTime(Date updatedTime)
Sets the time the end-user information was last updated. |
void |
setWebsite(URL website)
Sets the web page or blog. |
void |
setZoneinfo(String zoneinfo)
Sets the zoneinfo. |
Methods inherited from class com.nimbusds.openid.connect.sdk.claims.ClaimsSet |
---|
getBooleanClaim, getClaim, getClaim, getDateClaim, getEmailClaim, getJSONObject, getLangTaggedClaim, getNumberClaim, getStringClaim, getStringClaim, getURLClaim, setClaim, setClaim, setDateClaim, setEmailClaim, setURLClaim |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public UserInfo(Subject sub)
sub
- The subject. Must not be null
.public UserInfo(net.minidev.json.JSONObject jsonObject)
jsonObject
- The JSON object. Must not be null
.
IllegalArgumentException
- If the JSON object doesn't contain
a subject sub
string claim.Method Detail |
---|
public static Set<String> getStandardClaimNames()
public Subject getSubject()
sub
claim.
null
if not specified.public String getName()
name
claim, with no
language tag.
null
if not specified.public String getName(com.nimbusds.langtag.LangTag langTag)
name
claim, with an
optional language tag.
langTag
- The language tag of the entry, null
to get
the non-tagged entry.
null
if not specified.public Map<com.nimbusds.langtag.LangTag,String> getNameEntries()
name
claim.
public void setName(String name)
name
claim, with no
language tag.
name
- The full name. If null
the claim will be
removed.public void setName(String name, com.nimbusds.langtag.LangTag langTag)
name
claim, with an
optional language tag.
name
- The full name. If null
the claim will be
removed.langTag
- The language tag, null
if not specified.public String getGivenName()
given_name
claim, with no language tag.
null
if not specified.public String getGivenName(com.nimbusds.langtag.LangTag langTag)
given_name
claim, with an optional language tag.
langTag
- The language tag of the entry, null
to get
the non-tagged entry.
null
if not specified.public Map<com.nimbusds.langtag.LangTag,String> getGivenNameEntries()
given_name
claim.
public void setGivenName(String givenName)
given_name
claim, with no language tag.
givenName
- The given or first name. If null
the claim
will be removed.public void setGivenName(String givenName, com.nimbusds.langtag.LangTag langTag)
given_name
claim, with an optional language tag.
givenName
- The given or first full name. If null
the
claim will be removed.langTag
- The language tag, null
if not specified.public String getFamilyName()
family_name
claim, with no language tag.
null
if not specified.public String getFamilyName(com.nimbusds.langtag.LangTag langTag)
family_name
claim, with an optional language tag.
langTag
- The language tag of the entry, null
to get
the non-tagged entry.
null
if not specified.public Map<com.nimbusds.langtag.LangTag,String> getFamilyNameEntries()
public void setFamilyName(String familyName)
family_name
claim, with no language tag.
familyName
- The surname or last name. If null
the
claim will be removed.public void setFamilyName(String familyName, com.nimbusds.langtag.LangTag langTag)
family_name
claim, with an optional language tag.
familyName
- The surname or last name. If null
the
claim will be removed.langTag
- The language tag, null
if not specified.public String getMiddleName()
middle_name
claim,
with no language tag.
null
if not specified.public String getMiddleName(com.nimbusds.langtag.LangTag langTag)
middle_name
claim,
with an optional language tag.
langTag
- The language tag of the entry, null
to get
the non-tagged entry.
null
if not specified.public Map<com.nimbusds.langtag.LangTag,String> getMiddleNameEntries()
middle_name
claim.
public void setMiddleName(String middleName)
middle_name
claim,
with no language tag.
middleName
- The middle name. If null
the claim will be
removed.public void setMiddleName(String middleName, com.nimbusds.langtag.LangTag langTag)
middle_name
claim,
with an optional language tag.
middleName
- The middle name. If null
the claim will be
removed.langTag
- The language tag, null
if not specified.public String getNickname()
nickname
claim,
with no language tag.
null
if not specified.public String getNickname(com.nimbusds.langtag.LangTag langTag)
nickname
claim,
with an optional language tag.
langTag
- The language tag of the entry, null
to get
the non-tagged entry.
null
if not specified.public Map<com.nimbusds.langtag.LangTag,String> getNicknameEntries()
nickname
claim.
public void setNickname(String nickname)
nickname
claim,
with no language tag.
nickname
- The casual name. If null
the claim will be
removed.public void setNickname(String nickname, com.nimbusds.langtag.LangTag langTag)
nickname
claim,
with an optional language tag.
nickname
- The casual name. If null
the claim will be
removed.langTag
- The language tag, null
if not specified.public String getPreferredUsername()
preferred_username
claim.
null
if not specified.public void setPreferredUsername(String preferredUsername)
preferred_username
claim.
preferredUsername
- The preferred username. If null
the
claim will be removed.public URL getProfile()
profile
claim.
null
if not specified.public void setProfile(URL profile)
profile
claim.
profile
- The profile page URL. If null
the claim will
be removed.public URL getPicture()
picture
claim.
null
if not specified.public void setPicture(URL picture)
picture
claim.
picture
- The picture URL. If null
the claim will be
removed.public URL getWebsite()
website
claim.
null
if not specified.public void setWebsite(URL website)
website
claim.
website
- The web page or blog URL. If null
the claim
will be removed.public javax.mail.internet.InternetAddress getEmail()
email
claim.
null
if not specified.public void setEmail(javax.mail.internet.InternetAddress email)
email
claim.
email
- The preferred email address. If null
the claim
will be removed.public Boolean getEmailVerified()
email_verified
claim.
null
if not
specified.public void setEmailVerified(Boolean emailVerified)
email_verified
claim.
emailVerified
- The email verification status. If null
the claim will be removed.public Gender getGender()
gender
claim.
null
if not specified.public void setGender(Gender gender)
gender
claim.
gender
- The gender. If null
the claim will be removed.public String getBirthdate()
birthdate
claim.
null
if not specified.public void setBirthdate(String birthdate)
birthdate
claim.
birthdate
- The date of birth. If null
the claim will
be removed.public String getZoneinfo()
zoneinfo
claim.
null
if not specified.public void setZoneinfo(String zoneinfo)
zoneinfo
claim.
zoneinfo
- The zoneinfo. If null
the claim will be
removed.public String getLocale()
locale
claim.
null
if not specified.public void setLocale(String locale)
locale
claim.
locale
- The locale. If null
the claim will be
removed.public String getPhoneNumber()
phone_number
claim.
null
if not
specified.public void setPhoneNumber(String phoneNumber)
phone_number
claim.
phoneNumber
- The preferred telephone number. If null
the claim will be removed.public Boolean getPhoneNumberVerified()
phone_number_verified
claim.
null
if not
specified.public void setPhoneNumberVerified(Boolean phoneNumberVerified)
phone_number_verified
claim.
phoneNumberVerified
- The phone number verification status. If
null
the claim will be removed.public Address getAddress()
address
claim, with no language tag.
null
if not specified.public Address getAddress(com.nimbusds.langtag.LangTag langTag)
address
claim, with an optional language tag.
langTag
- The language tag of the entry, null
to get
the non-tagged entry.
null
if not specified.public Map<com.nimbusds.langtag.LangTag,Address> getAddressEntries()
address
claim.
public void setAddress(Address address)
address
claim, with no language tag.
address
- The preferred address. If null
the claim will
be removed.public void setAddress(Address address, com.nimbusds.langtag.LangTag langTag)
address
claim, with an optional language tag.
address
- The preferred address. If null
the claim
will be removed.langTag
- The language tag, null
if not specified.public Date getUpdatedTime()
updated_at
claim.
null
if not specified.public void setUpdatedTime(Date updatedTime)
updated_at
claim.
updatedTime
- The time the end-user information was last
updated. If null
the claim will be
removed.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |