org.hardtokenmgmt.admin.common
Class DefaultOrganizationIdMapper

java.lang.Object
  extended by org.hardtokenmgmt.admin.common.DefaultOrganizationIdMapper
All Implemented Interfaces:
IOrganizationIdMapper

public class DefaultOrganizationIdMapper
extends java.lang.Object
implements IOrganizationIdMapper

Default Organization ID Mapper that extracts O from the DN and stripps it from illegal characters using EJBCA StringTools

Version:
$Id$
Author:
Philip Vendil 2 apr 2009

Constructor Summary
DefaultOrganizationIdMapper()
           
 
Method Summary
 java.lang.String getOrganizationDisplayName(java.lang.String dn)
          Returns the organization display name from a given DN.
 java.lang.String getOrganizationId(java.lang.String dn)
          Extracts the O field from DN and stripps it from illegal characters using EJBCA StringTools
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultOrganizationIdMapper

public DefaultOrganizationIdMapper()
Method Detail

getOrganizationId

public java.lang.String getOrganizationId(java.lang.String dn)
Extracts the O field from DN and stripps it from illegal characters using EJBCA StringTools

Specified by:
getOrganizationId in interface IOrganizationIdMapper
Parameters:
dn - to calculate organization Id from
Returns:
a unique organization Id.
See Also:
IOrganizationIdMapper.getOrganizationId(java.lang.String)

getOrganizationDisplayName

public java.lang.String getOrganizationDisplayName(java.lang.String dn)
Description copied from interface: IOrganizationIdMapper
Returns the organization display name from a given DN.

Specified by:
getOrganizationDisplayName in interface IOrganizationIdMapper
Parameters:
dn - to calculate organization display name from
Returns:
a organization display name.