### Question:
Rdn implements Cloneable, Externalizable, Iterable<Ava>, Comparable<Rdn> { public Object getValue( String type ) throws LdapInvalidDnException { String normalizedType = Strings.lowerCaseAscii( Strings.trim( type ) ); if ( schemaManager != null ) { AttributeType attributeType = schemaManager.getAttributeType( normalizedType ); if ( attributeType != null ) { normalizedType = attributeType.getOid(); } } switch ( nbAvas ) { case 0: return ""; case 1: if ( ava.getNormType().equals( normalizedType ) ) { if ( ava.getValue() != null ) { return ava.getValue().getString(); } else { return null; } } return ""; default: List<Ava> avaList = avaTypes.get( normalizedType ); if ( avaList != null ) { for ( Ava elem : avaList ) { if ( elem.getNormType().equals( normalizedType ) ) { if ( elem.getValue() != null ) { return elem.getValue().getString(); } else { return null; } } } return null; } return null; } } Rdn();  Rdn( SchemaManager schemaManager );  Rdn( SchemaManager schemaManager, String rdn );  Rdn( String rdn );  Rdn( SchemaManager schemaManager, String upType, String upValue );  Rdn( String upType, String upValue );  Rdn( SchemaManager schemaManager, Ava... avas );  Rdn( Ava... avas );  Rdn( Rdn rdn );  Rdn( SchemaManager schemaManager, Rdn rdn ); Object getValue( String type ); Ava getAva( String type ); @Override Iterator<Ava> iterator(); @Override Rdn clone(); String getName(); String getNormName(); Ava getAva(); Ava getAva( int pos ); String getType(); String getNormType(); String getValue(); @Override boolean equals( Object that ); int size(); static Object unescapeValue( String value ); static String escapeValue( String value ); String getEscaped(); static String escapeValue( byte[] attrValue ); boolean isSchemaAware(); static boolean isValid( String dn ); static boolean isValid( SchemaManager schemaManager, String dn ); @Override int hashCode(); int serialize( byte[] buffer, int pos ); int deserialize( byte[] buffer, int pos ); @Override void writeExternal( ObjectOutput out ); @Override void readExternal( ObjectInput in ); @Override int compareTo( Rdn otherRdn ); @Override String toString(); static final Rdn EMPTY_RDN; static final int UNDEFINED; static final int SUPERIOR; static final int INFERIOR; static final int EQUAL; }### Answer:
@Test public void testRdnCompositeMultivaluedAttribute() throws LdapException { Rdn rdn = new Rdn( "a =b+c=d + e=f + g =h + i =j " ); assertEquals( "b", rdn.getValue( "a" ) ); assertEquals( "d", rdn.getValue( "c" ) ); assertEquals( "f", rdn.getValue( " E " ) ); assertEquals( "h", rdn.getValue( "g" ) ); assertEquals( "j", rdn.getValue( "i" ) ); }
@Test public void testGetValue() throws LdapException { Rdn rdn = new Rdn( " a = b + b = f + g = h + c = d " ); assertEquals( "b", rdn.getValue() ); }