org.jasig.cas.services
Class RegisteredServiceImpl

java.lang.Object
  extended by org.jasig.cas.services.RegisteredServiceImpl
All Implemented Interfaces:
java.io.Serializable, java.lang.Cloneable, java.lang.Comparable<RegisteredService>, RegisteredService

@Entity
public class RegisteredServiceImpl
extends java.lang.Object
implements RegisteredService, java.lang.Comparable<RegisteredService>

Mutable implementation of a RegisteredService.

Since:
3.1
Version:
$Revision: 47787 $ $Date: 2010-01-19 23:12:31 -0500 (Tue, 19 Jan 2010) $
Author:
Scott Battaglia
See Also:
Serialized Form

Constructor Summary
RegisteredServiceImpl()
           
 
Method Summary
 java.lang.Object clone()
           
 int compareTo(RegisteredService other)
           
 boolean equals(java.lang.Object o)
           
 java.util.List<java.lang.String> getAllowedAttributes()
          Returns the list of allowed attributes.
 java.lang.String getDescription()
          Returns the description of the service.
 int getEvaluationOrder()
          Gets the relative evaluation order of this service when determining matches.
 long getId()
           
 java.lang.String getName()
          Returns the name of the service.
 java.lang.String getServiceId()
          The unique identifier for this service.
 java.lang.String getTheme()
          Returns a short theme name.
 int hashCode()
           
 boolean isAllowedToProxy()
          Is this application allowed to take part in the proxying capabilities of CAS?
 boolean isAnonymousAccess()
          Determines whether the service is allowed anonymous or priveleged access to user information.
 boolean isEnabled()
          Is this application currently allowed to use CAS?
 boolean isIgnoreAttributes()
          Sets whether we should bother to read the attribute list or not.
 boolean isSsoEnabled()
          Does this application participate in the SSO session?
 boolean matches(Service service)
          Returns whether the service matches the registered service.
 void setAllowedAttributes(java.util.List<java.lang.String> allowedAttributes)
           
 void setAllowedToProxy(boolean allowedToProxy)
           
 void setAnonymousAccess(boolean anonymousAccess)
           
 void setDescription(java.lang.String description)
           
 void setEnabled(boolean enabled)
           
 void setEvaluationOrder(int evaluationOrder)
           
 void setId(long id)
           
 void setIgnoreAttributes(boolean ignoreAttributes)
           
 void setName(java.lang.String name)
           
 void setServiceId(java.lang.String id)
           
 void setSsoEnabled(boolean ssoEnabled)
           
 void setTheme(java.lang.String theme)
           
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RegisteredServiceImpl

public RegisteredServiceImpl()
Method Detail

isAnonymousAccess

public boolean isAnonymousAccess()
Description copied from interface: RegisteredService
Determines whether the service is allowed anonymous or priveleged access to user information. Anonymous access should not return any identifying information such as user id.

Specified by:
isAnonymousAccess in interface RegisteredService

setAnonymousAccess

public void setAnonymousAccess(boolean anonymousAccess)

getAllowedAttributes

public java.util.List<java.lang.String> getAllowedAttributes()
Description copied from interface: RegisteredService
Returns the list of allowed attributes.

Specified by:
getAllowedAttributes in interface RegisteredService
Returns:
the list of attributes

getId

public long getId()
Specified by:
getId in interface RegisteredService

getDescription

public java.lang.String getDescription()
Description copied from interface: RegisteredService
Returns the description of the service.

Specified by:
getDescription in interface RegisteredService
Returns:
the description of the service.

getServiceId

public java.lang.String getServiceId()
Description copied from interface: RegisteredService
The unique identifier for this service.

Specified by:
getServiceId in interface RegisteredService
Returns:
the unique identifier for this service.

getName

public java.lang.String getName()
Description copied from interface: RegisteredService
Returns the name of the service.

Specified by:
getName in interface RegisteredService
Returns:
the name of the service.

getTheme

public java.lang.String getTheme()
Description copied from interface: RegisteredService
Returns a short theme name. Services do not need to have unique theme names.

Specified by:
getTheme in interface RegisteredService
Returns:
the theme name associated with this service.

isAllowedToProxy

public boolean isAllowedToProxy()
Description copied from interface: RegisteredService
Is this application allowed to take part in the proxying capabilities of CAS?

Specified by:
isAllowedToProxy in interface RegisteredService
Returns:
true if it can, false otherwise.

isEnabled

public boolean isEnabled()
Description copied from interface: RegisteredService
Is this application currently allowed to use CAS?

Specified by:
isEnabled in interface RegisteredService
Returns:
true if it can use CAS, false otherwise.

isSsoEnabled

public boolean isSsoEnabled()
Description copied from interface: RegisteredService
Does this application participate in the SSO session?

Specified by:
isSsoEnabled in interface RegisteredService
Returns:
true if it does, false otherwise.

matches

public boolean matches(Service service)
Description copied from interface: RegisteredService
Returns whether the service matches the registered service.

Note, as of 3.1.2, matches are case insensitive.

Specified by:
matches in interface RegisteredService
Parameters:
service - the service to match.
Returns:
true if they match, false otherwise.

equals

public boolean equals(java.lang.Object o)
Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

setAllowedAttributes

public void setAllowedAttributes(java.util.List<java.lang.String> allowedAttributes)

setAllowedToProxy

public void setAllowedToProxy(boolean allowedToProxy)

setDescription

public void setDescription(java.lang.String description)

setEnabled

public void setEnabled(boolean enabled)

setServiceId

public void setServiceId(java.lang.String id)

setId

public void setId(long id)

setName

public void setName(java.lang.String name)

setSsoEnabled

public void setSsoEnabled(boolean ssoEnabled)

setTheme

public void setTheme(java.lang.String theme)

isIgnoreAttributes

public boolean isIgnoreAttributes()
Description copied from interface: RegisteredService
Sets whether we should bother to read the attribute list or not.

Specified by:
isIgnoreAttributes in interface RegisteredService
Returns:
true if we should read it, false otherwise.

setIgnoreAttributes

public void setIgnoreAttributes(boolean ignoreAttributes)

setEvaluationOrder

public void setEvaluationOrder(int evaluationOrder)

getEvaluationOrder

public int getEvaluationOrder()
Description copied from interface: RegisteredService
Gets the relative evaluation order of this service when determining matches.

Specified by:
getEvaluationOrder in interface RegisteredService
Returns:
Evaluation order relative to other registered services. Services with lower values will be evaluated for a match before others.

clone

public java.lang.Object clone()
                       throws java.lang.CloneNotSupportedException
Specified by:
clone in interface RegisteredService
Overrides:
clone in class java.lang.Object
Throws:
java.lang.CloneNotSupportedException

compareTo

public int compareTo(RegisteredService other)
Specified by:
compareTo in interface java.lang.Comparable<RegisteredService>


Copyright © 2004-2010 Java Architectures Special Interest Group. All Rights Reserved.