/** * Parse an AttributeType/AttributeValue * * @param attributes 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 */ private void parseAttribute( Attributes attributes, String line, String lowerLine ) throws LdapLdifException { int colonIndex = line.indexOf( ':' ); String attributeType = lowerLine.substring( 0, colonIndex ); // We should *not* have a Dn twice if ( "dn".equals( attributeType ) ) { LOG.error( I18n.err( I18n.ERR_13400_ENTRY_WITH_TWO_DNS ) ); throw new LdapLdifException( I18n.err( I18n.ERR_13439_LDIF_ENTRY_WITH_TWO_DNS ) ); } Object attributeValue = parseValue( attributeType, line, colonIndex ); // Update the entry javax.naming.directory.Attribute attribute = attributes.get( attributeType ); if ( attribute == null ) { attributes.put( attributeType, attributeValue ); } else { attribute.add( attributeValue ); } }
/** * Parse an AttributeType/AttributeValue * * @param attributes 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 */ private void parseAttribute( Attributes attributes, String line, String lowerLine ) throws LdapLdifException { int colonIndex = line.indexOf( ':' ); String attributeType = lowerLine.substring( 0, colonIndex ); // We should *not* have a Dn twice if ( "dn".equals( attributeType ) ) { LOG.error( I18n.err( I18n.ERR_13400_ENTRY_WITH_TWO_DNS ) ); throw new LdapLdifException( I18n.err( I18n.ERR_13439_LDIF_ENTRY_WITH_TWO_DNS ) ); } Object attributeValue = parseValue( attributeType, line, colonIndex ); // Update the entry javax.naming.directory.Attribute attribute = attributes.get( attributeType ); if ( attribute == null ) { attributes.put( attributeType, attributeValue ); } else { attribute.add( attributeValue ); } }
/** * Parse an AttributeType/AttributeValue * * @param attributes 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 */ private void parseAttribute( Attributes attributes, String line, String lowerLine ) throws LdapLdifException { int colonIndex = line.indexOf( ':' ); String attributeType = lowerLine.substring( 0, colonIndex ); // We should *not* have a Dn twice if ( "dn".equals( attributeType ) ) { LOG.error( I18n.err( I18n.ERR_13400_ENTRY_WITH_TWO_DNS ) ); throw new LdapLdifException( I18n.err( I18n.ERR_13439_LDIF_ENTRY_WITH_TWO_DNS ) ); } Object attributeValue = parseValue( attributeType, line, colonIndex ); // Update the entry javax.naming.directory.Attribute attribute = attributes.get( attributeType ); if ( attribute == null ) { attributes.put( attributeType, attributeValue ); } else { attribute.add( attributeValue ); } }
Object attributeValue = parseValue( attributeName, line, colonIndex );
Object attributeValue = parseValue( attributeName, line, colonIndex );
Object attributeValue = parseValue( attributeName, line, colonIndex );