public class RelyingPartyUIContext extends BaseContext
BaseContext.ContextSetNoRemoveIteratorDecorator| Modifier and Type | Field and Description |
|---|---|
private List<String> |
browserLanguages
The languages that this browser wants to know about.
|
private List<String> |
fallbackLanguages
The languages that this the Operator want to fall back to.
|
private org.slf4j.Logger |
log
The log.
|
private AttributeConsumingService |
rpAttributeConsumingService
The appropriate
AttributeConsumingService. |
private EntityDescriptor |
rpEntityDescriptor
The appropriate
EntityDescriptor. |
private SPSSODescriptor |
rpSPSSODescriptor
The appropriate
SPSSODescriptor. |
private UIInfo |
rpUIInfo
The appropriate
UIInfo. |
private List<String> |
usableLanguages
The languages that this the bean needs to look at.
|
| Constructor and Description |
|---|
RelyingPartyUIContext()
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
protected List<String> |
getBrowserLanguages()
Get the browser languages.
|
String |
getContactEmail(String contactType)
look for the <ContactPerson> and within that the Email.
|
String |
getContactGivenName(String contactType)
look for the <ContactPerson> and within that the GivenName.
|
ContactPerson |
getContactPerson(ContactPersonTypeEnumeration contactType)
Lookup the specified type of Contact in the RP metadata.
|
String |
getContactSurName(String contactType)
look for the <ContactPerson> and within that the SurName.
|
protected ContactPersonTypeEnumeration |
getContactType(String type)
Parser for the contact type.
|
protected String |
getDescriptionFromAttributeConsumingService(String lang)
look for an <AttributeConsumeService> and if its there look for an appropriate description.
|
protected String |
getDescriptionFromUIInfo(String lang)
look at <UIInfo> if there and if so look for appropriate description.
|
protected List<String> |
getFallbackLanguages()
Get the fallback languages.
|
String |
getInformationURL()
Get the <mdui:InformationURL>.
|
String |
getLogo()
Get the Logo (or null).
|
String |
getLogo(int minWidth,
int minHeight,
int maxWidth,
int maxHeight)
Get the Logo (or null).
|
String |
getLogo(String minWidth,
String minHeight,
String maxWidth,
String maxHeight)
Get the Logo (or null).
|
private String |
getLogoByLanguage(String lang,
int minWidth,
int minHeight,
int maxWidth,
int maxHeight)
Get the Logo of the given language which fits the size.
|
private String |
getLogoNoLanguage(int minWidth,
int minHeight,
int maxWidth,
int maxHeight)
Get a Logo without a language which fits the size.
|
protected String |
getNameFromAttributeConsumingService(String lang)
Look for an <AttributeConsumeService> and if its there look for an appropriate name.
|
protected String |
getNameFromEntityId()
If the entityId can look like a host return that, otherwise the entityId in full.
|
protected String |
getNameFromUIInfo(String lang)
look at <UIinfo>; if there and if so look for appropriate name.
|
protected Organization |
getOrganization()
|
String |
getOrganizationDisplayName()
Look for the <OrganizationDisplayName>.
|
String |
getOrganizationName()
Look for the <OrganizationName>.
|
String |
getOrganizationURL()
* Look for the <OrganizationURL>.
|
String |
getPrivacyStatementURL()
Get the <mdui:PrivacyStatementURL>.
|
protected AttributeConsumingService |
getRPAttributeConsumingService()
Get the
AttributeConsumingService for the request. |
protected EntityDescriptor |
getRPEntityDescriptor()
Get the
EntityDescriptor. |
protected SPSSODescriptor |
getRPSPSSODescriptor()
Get the
SPSSODescriptor. |
protected UIInfo |
getRPUInfo()
Get the RP
UIInfo associated with the request. |
String |
getServiceDescription()
Get the service Description.
|
String |
getServiceName()
Get the service name.
|
protected List<String> |
getUsableLanguages()
Get the all the languages.
|
private boolean |
logoFits(Logo logo,
int minWidth,
int minHeight,
int maxWidth,
int maxHeight)
Does the logo fit the supplied parameters?
|
protected void |
makeNewusableList()
Construct the usableLanguages from the
browserLanguages and the fallbackLanguages. |
private String |
policeURL(String url,
List<String> acceptableSchemes)
Check to see whether a supplied URL is acceptable, returning the default if it isn't.
|
protected String |
policeURLLogo(String url)
Police a url found for a logo.
|
protected String |
policeURLNonLogo(String url)
Police a url found for non logo data.
|
RelyingPartyUIContext |
setBrowserLanguages(List<String> languages)
Set the browser languages.
|
RelyingPartyUIContext |
setFallbackLanguages(List<String> languages)
Set the fallback languages.
|
RelyingPartyUIContext |
setRPAttributeConsumingService(AttributeConsumingService what)
Set the
AttributeConsumingService for the request. |
RelyingPartyUIContext |
setRPEntityDescriptor(EntityDescriptor what)
Set the
EntityDescriptor. |
RelyingPartyUIContext |
setRPSPSSODescriptor(SPSSODescriptor what)
Set the
SPSSODescriptor. |
RelyingPartyUIContext |
setRPUInfo(UIInfo what)
Set the RP
UIInfo associated with the request. |
addSubcontext, addSubcontext, clearSubcontexts, containsSubcontext, createSubcontext, getParent, getSubcontext, getSubcontext, getSubcontext, getSubcontext, isAutoCreateSubcontexts, iterator, removeSubcontext, removeSubcontext, setAutoCreateSubcontexts, setParent@Nonnull private final org.slf4j.Logger log
@Nullable private EntityDescriptor rpEntityDescriptor
EntityDescriptor.@Nullable private SPSSODescriptor rpSPSSODescriptor
SPSSODescriptor.@Nullable private AttributeConsumingService rpAttributeConsumingService
AttributeConsumingService.@Nonnull @NonnullElements private List<String> browserLanguages
@Nullable private List<String> fallbackLanguages
@Nonnull @NonnullElements @Unmodifiable private List<String> usableLanguages
@Nullable protected EntityDescriptor getRPEntityDescriptor()
EntityDescriptor.@Nonnull public RelyingPartyUIContext setRPEntityDescriptor(@Nullable EntityDescriptor what)
EntityDescriptor.what - what to set@Nullable protected SPSSODescriptor getRPSPSSODescriptor()
SPSSODescriptor.@Nonnull public RelyingPartyUIContext setRPSPSSODescriptor(@Nullable SPSSODescriptor what)
SPSSODescriptor.what - what to set@Nullable protected AttributeConsumingService getRPAttributeConsumingService()
AttributeConsumingService for the request.@Nullable protected UIInfo getRPUInfo()
UIInfo associated with the request.@Nonnull public RelyingPartyUIContext setRPUInfo(@Nullable UIInfo what)
UIInfo associated with the request.what - the value to set@Nonnull public RelyingPartyUIContext setRPAttributeConsumingService(@Nullable AttributeConsumingService what)
AttributeConsumingService for the request.what - what to set@Nonnull public RelyingPartyUIContext setBrowserLanguages(@Nonnull@NonnullElements List<String> languages)
languages - the languages to set@Nonnull @NonnullElements protected List<String> getBrowserLanguages()
@Nonnull public RelyingPartyUIContext setFallbackLanguages(@Nullable List<String> languages)
languages - the languages to set@Nonnull @NonnullElements protected List<String> getFallbackLanguages()
protected void makeNewusableList()
browserLanguages and the fallbackLanguages.@Nonnull @NonnullElements @Unmodifiable protected List<String> getUsableLanguages()
@Nullable private String policeURL(@Nullable String url, @Nonnull@NotEmpty List<String> acceptableSchemes)
url - the url to look atacceptableSchemes - the schemes to test againstprotected String policeURLLogo(@Nullable String url)
url - the url to look atprotected String policeURLNonLogo(@Nullable String url)
url - the url to look at@Nullable protected String getNameFromUIInfo(String lang)
lang - - which language to look up@Nullable protected String getNameFromAttributeConsumingService(String lang)
lang - - which language to look up@Nullable protected String getNameFromEntityId()
@Nullable protected String getDescriptionFromUIInfo(String lang)
lang - - which language to look up@Nullable protected String getDescriptionFromAttributeConsumingService(String lang)
lang - - which language to look up@Nullable protected Organization getOrganization()
Organization for the relying party.protected ContactPersonTypeEnumeration getContactType(@Nullable String type)
type - in value@Nullable public ContactPerson getContactPerson(ContactPersonTypeEnumeration contactType)
contactType - what type to look up.ContactPerson or null.@Nullable public String getServiceName()
@Nullable public String getServiceDescription()
@Nullable public String getOrganizationDisplayName()
@Nullable public String getOrganizationName()
public String getOrganizationURL()
@Nullable public String getContactSurName(@Nullable String contactType)
contactType - the type of contact to look for@Nullable public String getContactGivenName(@Nullable String contactType)
contactType - the type of contact to look for@Nullable public String getContactEmail(@Nullable String contactType)
contactType - the type of contact to look for@Nullable public String getInformationURL()
@Nullable public String getPrivacyStatementURL()
private boolean logoFits(Logo logo, int minWidth, int minHeight, int maxWidth, int maxHeight)
logo - the logominWidth - min WidthminHeight - min HeightmaxWidth - max WidthmaxHeight - max Height@Nullable private String getLogoByLanguage(@Nonnull String lang, int minWidth, int minHeight, int maxWidth, int maxHeight)
lang - the languageminWidth - the minimum width to allow.minHeight - the minimum height to allow.maxWidth - the maximum width to allow.maxHeight - the maximum height to allow.@Nullable private String getLogoNoLanguage(int minWidth, int minHeight, int maxWidth, int maxHeight)
minWidth - the minimum width to allow.minHeight - the minimum height to allow.maxWidth - the maximum width to allow.maxHeight - the maximum height to allow.@Nullable public String getLogo(int minWidth, int minHeight, int maxWidth, int maxHeight)
minWidth - the minimum width to allow.minHeight - the minimum height to allow.maxWidth - the maximum width to allow.maxHeight - the maximum height to allow.@Nullable public String getLogo(String minWidth, String minHeight, String maxWidth, String maxHeight)
minWidth - the minimum width to allow.minHeight - the minimum height to allow.maxWidth - the maximum width to allow.maxHeight - the maximum height to allow.Copyright © 1999–2018 Shibboleth Consortium. All rights reserved.