Search in sources :

Example 61 with LdapException

use of org.apache.directory.api.ldap.model.exception.LdapException in project directory-ldap-api by apache.

the class DefaultSchemaLoader method loadDitStructureRules.

private void loadDitStructureRules(Attribute ditStructureRules) throws LdapException {
    if (ditStructureRules == null) {
        return;
    }
    for (Value value : ditStructureRules) {
        String desc = value.getValue();
        try {
            DitStructureRule ditStructureRule = DSR_DESCR_SCHEMA_PARSER.parseDITStructureRuleDescription(desc);
            updateSchemas(ditStructureRule);
        } catch (ParseException pe) {
            throw new LdapException(pe);
        }
    }
}
Also used : DitStructureRule(org.apache.directory.api.ldap.model.schema.DitStructureRule) Value(org.apache.directory.api.ldap.model.entry.Value) ParseException(java.text.ParseException) LdapException(org.apache.directory.api.ldap.model.exception.LdapException)

Example 62 with LdapException

use of org.apache.directory.api.ldap.model.exception.LdapException in project directory-ldap-api by apache.

the class DefaultSchemaLoader method loadObjectClasses.

private void loadObjectClasses(Attribute objectClasses) throws LdapException {
    if (objectClasses == null) {
        return;
    }
    for (Value value : objectClasses) {
        String desc = value.getValue();
        try {
            ObjectClass objectClass = OC_DESCR_SCHEMA_PARSER.parseObjectClassDescription(desc);
            updateSchemas(objectClass);
        } catch (ParseException pe) {
            throw new LdapException(pe);
        }
    }
}
Also used : ObjectClass(org.apache.directory.api.ldap.model.schema.ObjectClass) Value(org.apache.directory.api.ldap.model.entry.Value) ParseException(java.text.ParseException) LdapException(org.apache.directory.api.ldap.model.exception.LdapException)

Example 63 with LdapException

use of org.apache.directory.api.ldap.model.exception.LdapException in project directory-ldap-api by apache.

the class DefaultSchemaLoader method loadNameForms.

private void loadNameForms(Attribute nameForms) throws LdapException {
    if (nameForms == null) {
        return;
    }
    for (Value value : nameForms) {
        String desc = value.getValue();
        try {
            NameForm nameForm = NF_DESCR_SCHEMA_PARSER.parseNameFormDescription(desc);
            updateSchemas(nameForm);
        } catch (ParseException pe) {
            throw new LdapException(pe);
        }
    }
}
Also used : NameForm(org.apache.directory.api.ldap.model.schema.NameForm) Value(org.apache.directory.api.ldap.model.entry.Value) ParseException(java.text.ParseException) LdapException(org.apache.directory.api.ldap.model.exception.LdapException)

Example 64 with LdapException

use of org.apache.directory.api.ldap.model.exception.LdapException in project directory-ldap-api by apache.

the class DefaultSchemaLoader method loadLdapSyntaxes.

private void loadLdapSyntaxes(Attribute ldapSyntaxes) throws LdapException {
    if (ldapSyntaxes == null) {
        return;
    }
    for (Value value : ldapSyntaxes) {
        String desc = value.getValue();
        try {
            LdapSyntax ldapSyntax = LS_DESCR_SCHEMA_PARSER.parseLdapSyntaxDescription(desc);
            updateSchemas(ldapSyntax);
        } catch (ParseException pe) {
            throw new LdapException(pe);
        }
    }
}
Also used : Value(org.apache.directory.api.ldap.model.entry.Value) LdapSyntax(org.apache.directory.api.ldap.model.schema.LdapSyntax) ParseException(java.text.ParseException) LdapException(org.apache.directory.api.ldap.model.exception.LdapException)

Example 65 with LdapException

use of org.apache.directory.api.ldap.model.exception.LdapException in project directory-ldap-api by apache.

the class DefaultSchemaLoader method loadNormalizers.

private void loadNormalizers(Attribute normalizers) throws LdapException {
    if (normalizers == null) {
        return;
    }
    for (Value value : normalizers) {
        String desc = value.getValue();
        try {
            NormalizerDescription normalizer = N_DESCR_SCHEMA_PARSER.parseNormalizerDescription(desc);
            updateSchemas(normalizer);
        } catch (ParseException pe) {
            throw new LdapException(pe);
        }
    }
}
Also used : NormalizerDescription(org.apache.directory.api.ldap.model.schema.parsers.NormalizerDescription) Value(org.apache.directory.api.ldap.model.entry.Value) ParseException(java.text.ParseException) LdapException(org.apache.directory.api.ldap.model.exception.LdapException)

Aggregations

LdapException (org.apache.directory.api.ldap.model.exception.LdapException)361 LdapConnection (org.apache.directory.ldap.client.api.LdapConnection)161 CursorException (org.apache.directory.api.ldap.model.cursor.CursorException)111 ArrayList (java.util.ArrayList)94 FinderException (org.apache.directory.fortress.core.FinderException)73 Modification (org.apache.directory.api.ldap.model.entry.Modification)70 Entry (org.apache.directory.api.ldap.model.entry.Entry)68 IOException (java.io.IOException)57 DefaultModification (org.apache.directory.api.ldap.model.entry.DefaultModification)57 DefaultEntry (org.apache.directory.api.ldap.model.entry.DefaultEntry)53 SearchCursor (org.apache.directory.api.ldap.model.cursor.SearchCursor)51 UpdateException (org.apache.directory.fortress.core.UpdateException)41 LdapInvalidDnException (org.apache.directory.api.ldap.model.exception.LdapInvalidDnException)35 Dn (org.apache.directory.api.ldap.model.name.Dn)34 SEPASecurityException (it.unibo.arces.wot.sepa.commons.exceptions.SEPASecurityException)29 LdapAuthenticationException (org.apache.directory.api.ldap.model.exception.LdapAuthenticationException)25 AttributeType (org.apache.directory.api.ldap.model.schema.AttributeType)25 Attribute (org.apache.directory.api.ldap.model.entry.Attribute)23 DecoderException (org.apache.directory.api.asn1.DecoderException)22 LdapNoPermissionException (org.apache.directory.api.ldap.model.exception.LdapNoPermissionException)22