org.eclipse.stardust.engine.core.compatibility.spi.security
Class DefaultPrincipalNameProvider

java.lang.Object
  extended by org.eclipse.stardust.engine.core.compatibility.spi.security.DefaultPrincipalNameProvider
All Implemented Interfaces:
PrincipalNameProvider

public class DefaultPrincipalNameProvider
extends Object
implements PrincipalNameProvider

Default implementation for interface PrincipalNameProvider. This will be used if no other is specified. It simply will return the name of the given principal.

Author:
stephan.born

Constructor Summary
DefaultPrincipalNameProvider()
           
 
Method Summary
 String getName(Principal principal)
          Provides the name for a given principal.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultPrincipalNameProvider

public DefaultPrincipalNameProvider()
Method Detail

getName

public String getName(Principal principal)
Description copied from interface: PrincipalNameProvider
Provides the name for a given principal. Default implementation would be to return principal.getName(). It is possible to test for a certain implementation and use method fo these implementation in order to return a more specific name for the given principal.

Specified by:
getName in interface PrincipalNameProvider
Parameters:
principal - the principal
Returns:
the name of the principal. Not allowed to be null.


Copyright © 2017 Eclipse Stardust. All Rights Reserved.