org.apache.directory.ldap.client.api.LdapConnection.modify()方法的使用及代码示例

x33g5p2x  于2022-01-24 转载在 其他  
字(6.3k)|赞(0)|评价(0)|浏览(118)

本文整理了Java中org.apache.directory.ldap.client.api.LdapConnection.modify()方法的一些代码示例,展示了LdapConnection.modify()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。LdapConnection.modify()方法的具体详情如下:
包路径:org.apache.directory.ldap.client.api.LdapConnection
类名称:LdapConnection
方法名:modify

LdapConnection.modify介绍

[英]Applies all the modifications to the entry specified by its distinguished name.
[中]将所有修改应用于由可分辨名称指定的条目。

代码示例

代码示例来源:origin: org.apache.directory.api/api-ldap-client-api

/**
 * {@inheritDoc}
 */
@Override
public ModifyResponse modify( ModifyRequest modRequest ) throws LdapException
{
  return connection.modify( modRequest );
}

代码示例来源:origin: org.apache.directory.api/api-ldap-client-all

/**
 * {@inheritDoc}
 */
@Override
public void modify( Entry entry, ModificationOperation modOp ) throws LdapException
{
  connection.modify( entry, modOp );
}

代码示例来源:origin: org.apache.directory.api/api-all

/**
 * {@inheritDoc}
 */
@Override
public void modify( Entry entry, ModificationOperation modOp ) throws LdapException
{
  connection.modify( entry, modOp );
}

代码示例来源:origin: org.apache.directory.api/api-all

/**
 * {@inheritDoc}
 */
@Override
public void modify( Dn dn, Modification... modifications ) throws LdapException
{
  connection.modify( dn, modifications );
}

代码示例来源:origin: org.apache.directory.api/api-ldap-client-api

/**
 * {@inheritDoc}
 */
@Override
public void modify( Dn dn, Modification... modifications ) throws LdapException
{
  connection.modify( dn, modifications );
}

代码示例来源:origin: org.apache.directory.api/api-ldap-client-all

/**
 * {@inheritDoc}
 */
@Override
public void modify( String dn, Modification... modifications ) throws LdapException
{
  connection.modify( dn, modifications );
}

代码示例来源:origin: org.apache.directory.api/api-ldap-client-all

/**
 * {@inheritDoc}
 */
@Override
public ModifyResponse modify( ModifyRequest modRequest ) throws LdapException
{
  return connection.modify( modRequest );
}

代码示例来源:origin: org.apache.directory.api/api-all

/**
 * {@inheritDoc}
 */
@Override
public void modify( String dn, Modification... modifications ) throws LdapException
{
  connection.modify( dn, modifications );
}

代码示例来源:origin: org.apache.directory.api/api-all

/**
 * {@inheritDoc}
 */
@Override
public ModifyResponse modify( ModifyRequest modRequest ) throws LdapException
{
  return connection.modify( modRequest );
}

代码示例来源:origin: org.apache.directory.api/api-ldap-client-all

/**
 * {@inheritDoc}
 */
@Override
public void modify( Dn dn, Modification... modifications ) throws LdapException
{
  connection.modify( dn, modifications );
}

代码示例来源:origin: org.apache.directory.api/api-ldap-client-api

/**
 * {@inheritDoc}
 */
@Override
public void modify( String dn, Modification... modifications ) throws LdapException
{
  connection.modify( dn, modifications );
}

代码示例来源:origin: org.apache.directory.api/api-ldap-client-api

/**
 * {@inheritDoc}
 */
@Override
public void modify( Entry entry, ModificationOperation modOp ) throws LdapException
{
  connection.modify( entry, modOp );
}

代码示例来源:origin: org.apache.directory.fortress/fortress-core

/**
 * Update exiting ldap entry to the directory.  Do not add audit context.
 *
 * @param connection handle to ldap connection.
 * @param dn         contains distinguished node of entry.
 * @param mods       contains data to modify.
 * @throws LdapException in the event system error occurs.
 */
protected void modify( LdapConnection connection, String dn, List<Modification> mods ) throws LdapException
{
  COUNTERS.incrementMod();
  connection.modify( dn, mods.toArray( new Modification[]{} ) );
}

代码示例来源:origin: org.apache.directory.fortress/fortress-core

/**
 * Update exiting ldap entry to the directory.  Do not add audit context.
 *
 * @param connection handle to ldap connection.
 * @param dn         contains distinguished node of entry.
 * @param mods       contains data to modify.
 * @throws LdapException in the event system error occurs.
 */
protected void modify( LdapConnection connection, Dn dn, List<Modification> mods ) throws LdapException
{
  COUNTERS.incrementMod();
  connection.modify( dn, mods.toArray( new Modification[]
    {} ) );
}

代码示例来源:origin: org.apache.directory.server/apacheds-core-integ

public static void disableSchema( DirectoryService service, String schemaName ) throws LdapException
{
  LdapConnection connection = getAdminConnection( service );
  // now enable the test schema
  Modification mod = new DefaultModification(
    ModificationOperation.REPLACE_ATTRIBUTE, "m-disabled", "TRUE" );
  connection.modify( "cn=" + schemaName + ",ou=schema", mod );
}

代码示例来源:origin: org.apache.directory.server/apacheds-core-integ

public static void enableSchema( DirectoryService service, String schemaName ) throws LdapException
{
  LdapConnection connection = getAdminConnection( service );
  // now enable the test schema
  connection.modify( "cn=" + schemaName + ",ou=schema",
    new DefaultModification(
      ModificationOperation.REPLACE_ATTRIBUTE, "m-disabled", "FALSE" ) );
}

代码示例来源:origin: com.qwazr/qwazr-library-ldap

public void updateString(final LdapConnection connection, final String dn, final String attr,
    final String... values) throws LdapException {
  connection.bind();
  final Modification modif = new DefaultModification(ModificationOperation.REPLACE_ATTRIBUTE, attr, values);
  connection.modify(dn + ", " + baseDn, modif);
}

代码示例来源:origin: org.apache.directory.fortress/fortress-core

/**
 * Update exiting ldap entry to the directory.  Add audit context.
 *
 * @param connection handle to ldap connection.
 * @param dn         contains distinguished node of entry.
 * @param mods       contains data to modify.
 * @param entity     contains audit context.
 * @throws LdapException in the event system error occurs.
 */
protected void modify( LdapConnection connection, Dn dn, List<Modification> mods,
  FortEntity entity ) throws LdapException
{
  COUNTERS.incrementMod();
  audit( mods, entity );
  connection.modify( dn, mods.toArray( new Modification[]
    {} ) );
}

代码示例来源:origin: org.apache.directory.fortress/fortress-core

/**
 * Update exiting ldap entry to the directory.  Add audit context.
 *
 * @param connection handle to ldap connection.
 * @param dn         contains distinguished node of entry.
 * @param mods       contains data to modify.
 * @param entity     contains audit context.
 * @throws LdapException in the event system error occurs.
 */
protected void modify( LdapConnection connection, String dn, List<Modification> mods,
  FortEntity entity ) throws LdapException
{
  COUNTERS.incrementMod();
  audit( mods, entity );
  connection.modify( dn, mods.toArray( new Modification[]
    {} ) );
}

代码示例来源:origin: com.qwazr/qwazr-library-ldap

public void updatePassword(final LdapConnection connection, String dn, final String passwordAttribute,
    final String clearPassword) throws LdapException {
  connection.bind();
  Modification changePassword =
      new DefaultModification(ModificationOperation.REPLACE_ATTRIBUTE, passwordAttribute,
          getShaPassword(clearPassword));
  connection.modify(dn + ", " + baseDn, changePassword);
}

相关文章