public void checkModify( LdapDN normName, ModificationItemImpl[] mods ) throws NamingException { Attributes originalEntry = nexus.lookup( normName ); Attributes targetEntry = SchemaUtils.getTargetEntry( mods, originalEntry ); Attribute targetObjectClasses = targetEntry.get( "objectClass" ); if ( AttributeUtils.containsValueCaseIgnore( targetObjectClasses, "collectiveAttributeSubentry" ) ) { return; } if ( addsAnyCollectiveAttributes( mods ) ) { /* * TODO: Replace the Exception and the ResultCodeEnum with the correct ones. */ throw new LdapSchemaViolationException( "Cannot operate on collective attributes in non-collectiveAttributeSubentries", ResultCodeEnum.OTHER); } }