org.apache.directory.shared.ldap.name.DN.get()方法的使用及代码示例

x33g5p2x  于2022-01-18 转载在 其他  
字(1.4k)|赞(0)|评价(0)|浏览(173)

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

DN.get介绍

[英]Get the given RDN as a String. The position is used in the reverse order. Assuming that we have a DN like

dc=example,dc=apache,dc=org

then :

  • get(0) will return dc=org
  • get(1) will return dc=apache
  • get(2) will return dc=example
    [中]以字符串形式获取给定的RDN。该位置按相反顺序使用。假设我们有一个类似
dc=example,dc=apache,dc=org

的DN,那么:
*get(0)将返回dc=org
*get(1)将返回dc=apache
*get(2)将返回dc=示例

代码示例

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

/**
 * Copies a DN to an DN.
 *
 * @param name composed of String name components.
 * @throws LdapInvalidDnException If the Name is invalid.
 */
public DN( DN dn ) throws LdapInvalidDnException
{
  if ( ( dn != null ) && ( dn.size() != 0 ) )
  {
    for ( int ii = 0; ii < dn.size(); ii++ )
    {
      String nameComponent = dn.get( ii );
      add( nameComponent );
    }
  }
  normalized = false;
}

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

String childRdn = childUpdn.get( childUpdn.size() - 1 );
DN newUpdn = new DN( getEntryUpdn( newParentId ) );
newUpdn.add( newUpdn.size(), childRdn );

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

DN oldUpdn = new DN( getEntryUpdn( childId ) );
String rdn = oldUpdn.get( oldUpdn.size() - 1 );
DN rdnDN = new DN( rdn );
rdnDN.normalize( schemaManager.getNormalizerMapping() );

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

RDN rdn = new RDN( name.get( i ) );
rdns.add( size() - posn, rdn );

相关文章