info.magnolia.cms.security
Class DummyUser

java.lang.Object
  extended by info.magnolia.cms.security.AbstractUser
      extended by info.magnolia.cms.security.DummyUser
All Implemented Interfaces:
User, Serializable, Principal

Deprecated. since 4.3.6 - usage needs to be reviewed - see MAGNOLIA-3269

@Deprecated
public class DummyUser
extends AbstractUser

Dummy user implementation returned when an actual user instance can't be instantiated.

Version:
$Revision:9391 $ ($Author:scharles $)
Author:
Sameer Charles
See Also:
Serialized Form

Constructor Summary
DummyUser()
          Deprecated.  
 
Method Summary
 void addGroup(String groupName)
          Deprecated. Adds this user to a group.
 void addRole(String roleName)
          Deprecated. Simply log that its a dummy user.
 Collection<String> getAllGroups()
          Deprecated. Get all groups to which this user belongs to, collected recursively including.
 Collection<String> getAllRoles()
          Deprecated. Get all roles assigned to this user, collected recursively including groups/subgroups.
 Collection<String> getGroups()
          Deprecated. Get groups that are directly assigned to the user.
 String getIdentifier()
          Deprecated. Gets user identifier.
 String getLanguage()
          Deprecated.  
 String getName()
          Deprecated.  
 String getPassword()
          Deprecated.  
 String getProperty(String propertyName)
          Deprecated. Gets an arbitrary property from this user.
 Collection<String> getRoles()
          Deprecated. Get roles that are directly assigned to the user.
 boolean hasRole(String roleName)
          Deprecated. Dummy user has full access, always returns true.
 boolean inGroup(String groupName)
          Deprecated. Always returns true.
 boolean isEnabled()
          Deprecated. Returns false if the user was explicitly disabled.
 void removeGroup(String groupName)
          Deprecated. Remove a group.
 void removeRole(String roleName)
          Deprecated. Simply log that its a dummy user.
 void setEnabled(boolean enabled)
          Deprecated.  
 void setProperty(String propertyName, String value)
          Deprecated. Sets an arbitrary property for this user.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface java.security.Principal
equals, hashCode, toString
 

Constructor Detail

DummyUser

public DummyUser()
Deprecated. 
Method Detail

hasRole

public boolean hasRole(String roleName)
Deprecated. 
Dummy user has full access, always returns true.

Parameters:
roleName - the name of the role
Returns:
true if in role

removeRole

public void removeRole(String roleName)
                throws UnsupportedOperationException
Deprecated. 
Simply log that its a dummy user.

Throws:
UnsupportedOperationException

addRole

public void addRole(String roleName)
             throws UnsupportedOperationException
Deprecated. 
Simply log that its a dummy user.

Parameters:
roleName - the name of the role
Throws:
UnsupportedOperationException

inGroup

public boolean inGroup(String groupName)
Deprecated. 
Always returns true.

Returns:
true if in group

removeGroup

public void removeGroup(String groupName)
                 throws UnsupportedOperationException
Deprecated. 
Description copied from interface: User
Remove a group. Implementation is optional

Throws:
UnsupportedOperationException

addGroup

public void addGroup(String groupName)
              throws UnsupportedOperationException
Deprecated. 
Description copied from interface: User
Adds this user to a group. Implementation is optional

Throws:
UnsupportedOperationException

isEnabled

public boolean isEnabled()
Deprecated. 
Description copied from interface: User
Returns false if the user was explicitly disabled. Implementations should return true by default if the status is unknown.


setEnabled

public void setEnabled(boolean enabled)
Deprecated. 

getLanguage

public String getLanguage()
Deprecated. 

getName

public String getName()
Deprecated. 

getPassword

public String getPassword()
Deprecated. 

getProperty

public String getProperty(String propertyName)
Deprecated. 
Description copied from interface: User
Gets an arbitrary property from this user.


setProperty

public void setProperty(String propertyName,
                        String value)
Deprecated. 
Description copied from interface: User
Sets an arbitrary property for this user. Values are currently Strings; we'd need some kind of abstract encoding mechanism to allow other types if needed.


getIdentifier

public String getIdentifier()
Deprecated. 
Description copied from interface: User
Gets user identifier.


getGroups

public Collection<String> getGroups()
Deprecated. 
Description copied from interface: User
Get groups that are directly assigned to the user.


getAllGroups

public Collection<String> getAllGroups()
Deprecated. 
Description copied from interface: User
Get all groups to which this user belongs to, collected recursively including.


getRoles

public Collection<String> getRoles()
Deprecated. 
Description copied from interface: User
Get roles that are directly assigned to the user.


getAllRoles

public Collection<String> getAllRoles()
Deprecated. 
Description copied from interface: User
Get all roles assigned to this user, collected recursively including groups/subgroups.



Copyright © 2003–2014 Magnolia International Ltd.. All rights reserved.