/** * Parse an AttributeType/AttributeValue * * @param entry The entry where to store the value * @param line The line to parse * @param lowerLine The same line, lowercased * @throws LdapLdifException If anything goes wrong */ public void parseAttributeValue( LdifEntry entry, String line, String lowerLine ) throws LdapLdifException, LdapException { int colonIndex = line.indexOf( ':' ); String attributeType = lowerLine.substring( 0, colonIndex ); // We should *not* have a DN twice if ( attributeType.equals( "dn" ) ) { LOG.error( I18n.err( I18n.ERR_12002 ) ); throw new LdapLdifException( I18n.err( I18n.ERR_12003 ) ); } Object attributeValue = parseValue( line, colonIndex ); // Update the entry entry.addAttribute( attributeType, attributeValue ); }
Object attributeValue = parseValue( line, colonIndex ); entry.setNewRdn( attributeValue instanceof String ? ( String ) attributeValue : StringTools .utf8ToString( ( byte[] ) attributeValue ) ); Object attributeValue = parseValue( line, colonIndex ); entry.setDeleteOldRdn( "1".equals( attributeValue ) );
Object attributeValue = parseValue( line, colonIndex ); entry.setNewSuperior( attributeValue instanceof String ? ( String ) attributeValue : StringTools.utf8ToString( ( byte[] ) attributeValue ) );
Object attributeValue = parseValue( line, colonIndex );