com.atlassian.crowd.directory.ldap.validator
Class GroupRoleDnOverlapValidator

java.lang.Object
  extended by com.atlassian.crowd.directory.ldap.validator.GroupRoleDnOverlapValidator
All Implemented Interfaces:
Validator

public class GroupRoleDnOverlapValidator
extends java.lang.Object
implements Validator

Checks if the Role DN Addition and Group DN Addition overlap each other


Constructor Summary
GroupRoleDnOverlapValidator()
           
 
Method Summary
 java.lang.String getError(Directory directory)
          Validates a specific directory configuration.
 boolean isDNConfigOverlapping(java.lang.String roleDN, java.lang.String groupDN)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GroupRoleDnOverlapValidator

public GroupRoleDnOverlapValidator()
Method Detail

getError

public java.lang.String getError(Directory directory)
Description copied from interface: Validator
Validates a specific directory configuration.

Specified by:
getError in interface Validator
Parameters:
directory - directory object.
Returns:
error message or null if there is no error in the configuration.

isDNConfigOverlapping

public boolean isDNConfigOverlapping(java.lang.String roleDN,
                                     java.lang.String groupDN)
Parameters:
roleDN - DN addition for roles.
groupDN - DN addition for groups.
Returns:
true if either roleDN or groupDN are blank; or if roleDN starts with groupDN or vice versa.


Copyright © 2010 Atlassian. All Rights Reserved.