Package org.apache.directory.shared.ldap.model.exception

Examples of org.apache.directory.shared.ldap.model.exception.LdapInvalidAttributeTypeException


            compareContext.setAttributeType( attributeType );
        }
        catch ( LdapException le )
        {
            throw new LdapInvalidAttributeTypeException( I18n.err( I18n.ERR_266, compareContext.getOid() ) );
        }

        return next.compare( compareContext );
    }
View Full Code Here


                    {
                        nbAdded = serverAttribute.add( Strings.utf8ToString((byte[]) value) );
                    }
                    else
                    {
                        throw new LdapInvalidAttributeTypeException();
                    }
                }
                else
                {
                    if ( value instanceof String )
                    {
                        nbAdded = serverAttribute.add( Strings.getBytesUtf8((String) value) );
                    }
                    else if ( value instanceof byte[] )
                    {
                        nbAdded = serverAttribute.add( (byte[])value );
                    }
                    else
                    {
                        throw new LdapInvalidAttributeTypeException();
                    }
                }
               
                if ( nbAdded == 0 )
                {
                    throw new LdapInvalidAttributeTypeException();
                }
            }
           
            return serverAttribute;
        }
        catch ( NamingException ne )
        {
            throw new LdapInvalidAttributeTypeException();
        }
    }
View Full Code Here

               
                return entry;
            }
            catch ( LdapException ne )
            {
                throw new LdapInvalidAttributeTypeException( ne.getLocalizedMessage() );
            }
        }
        else
        {
            return null;
View Full Code Here

                     && modification.getOperation() == ModificationOperation.REPLACE_ATTRIBUTE )
                {
                    // The attributeType does not exist in the schema.
                    // It's an error
                    String message = I18n.err( I18n.ERR_467, id );
                    throw new LdapInvalidAttributeTypeException( message );
                }
                else
                {
                    // TODO : handle options
                    AttributeType attributeType = schemaManager.lookupAttributeTypeRegistry( id );
View Full Code Here

TOP

Related Classes of org.apache.directory.shared.ldap.model.exception.LdapInvalidAttributeTypeException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.