/** * {@inheritDoc} */ @Override public void modify( String dn, Modification... modifications ) throws LdapException { modify( new Dn( dn ), modifications ); }
/** * {@inheritDoc} */ @Override public void modify( String dn, Modification... modifications ) throws LdapException { modify( new Dn( dn ), modifications ); }
/** * {@inheritDoc} */ @Override public void modify( String dn, Modification... modifications ) throws LdapException { modify( new Dn( dn ), modifications ); }
ModifyResponse modifyResponse = modify( modReq );
/** * {@inheritDoc} */ @Override public void modify( Entry entry, ModificationOperation modOp ) throws LdapException { if ( entry == null ) { if ( LOG.isDebugEnabled() ) { LOG.debug( I18n.msg( I18n.MSG_04140_NULL_ENTRY_MODIFY ) ); } throw new IllegalArgumentException( I18n.err( I18n.ERR_04133_NULL_MODIFIED_ENTRY ) ); } ModifyRequest modReq = new ModifyRequestImpl(); modReq.setName( entry.getDn() ); Iterator<Attribute> itr = entry.iterator(); while ( itr.hasNext() ) { modReq.addModification( itr.next(), modOp ); } ModifyResponse modifyResponse = modify( modReq ); processResponse( modifyResponse ); }
ModifyResponse modifyResponse = modify( modReq );
ModifyResponse modifyResponse = modify( modReq );
/** * {@inheritDoc} */ @Override public void modify( Entry entry, ModificationOperation modOp ) throws LdapException { if ( entry == null ) { if ( LOG.isDebugEnabled() ) { LOG.debug( I18n.msg( I18n.MSG_04140_NULL_ENTRY_MODIFY ) ); } throw new IllegalArgumentException( I18n.err( I18n.ERR_04133_NULL_MODIFIED_ENTRY ) ); } ModifyRequest modReq = new ModifyRequestImpl(); modReq.setName( entry.getDn() ); Iterator<Attribute> itr = entry.iterator(); while ( itr.hasNext() ) { modReq.addModification( itr.next(), modOp ); } ModifyResponse modifyResponse = modify( modReq ); processResponse( modifyResponse ); }
/** * {@inheritDoc} */ @Override public void modify( Entry entry, ModificationOperation modOp ) throws LdapException { if ( entry == null ) { if ( LOG.isDebugEnabled() ) { LOG.debug( I18n.msg( I18n.MSG_04140_NULL_ENTRY_MODIFY ) ); } throw new IllegalArgumentException( I18n.err( I18n.ERR_04133_NULL_MODIFIED_ENTRY ) ); } ModifyRequest modReq = new ModifyRequestImpl(); modReq.setName( entry.getDn() ); Iterator<Attribute> itr = entry.iterator(); while ( itr.hasNext() ) { modReq.addModification( itr.next(), modOp ); } ModifyResponse modifyResponse = modify( modReq ); processResponse( modifyResponse ); }
ModifyResponse modifyResponse = ldapConnection.modify( request );
@Override public Response<Void> modify(final ModifyRequest request) throws LdapException { Response<Void> response = null; try { final ApacheLdapUtils bu = new ApacheLdapUtils(); final ModifyRequestImpl mri = new ModifyRequestImpl(); if (request.getControls() != null) { mri.addAllControls(config.getControlProcessor().processRequestControls(request.getControls())); } mri.setName(new Dn(request.getDn())); for (Modification m : bu.fromAttributeModification(request.getAttributeModifications())) { mri.addModification(m); } final ModifyResponse mr = connection.modify(mri); throwOperationException(request, mr); response = createResponse(request, null, mr); } catch (LdapOperationException e) { processLdapOperationException(e); } catch (org.apache.directory.api.ldap.model.exception.LdapException e) { processLdapException(e); } return response; }