AVA(Reader in,int format,Map<String,String> keywordMap) throws IOException {
  StringBuilder temp=new StringBuilder();
  int c;
  while (true) {
    c=readChar(in,"Incorrect AVA format");
    if (c == '=') {
      break;
    }
    temp.append((char)c);
  }
  oid=AVAKeyword.getOID(temp.toString(),format,keywordMap);
  temp.setLength(0);
  if (format == RFC2253) {
    c=in.read();
    if (c == ' ') {
      throw new IOException("Incorrect AVA RFC2253 format - " + "leading space must be escaped");
    }
  }
 else {
    do {
      c=in.read();
    }
 while ((c == ' ') || (c == '\n'));
  }
  if (c == -1) {
    value=new DerValue("");
    return;
  }
  if (c == '#') {
    value=parseHexString(in,format);
  }
 else   if ((c == '"') && (format != RFC2253)) {
    value=parseQuotedString(in,temp);
  }
 else {
    value=parseString(in,c,format,temp);
  }
}

AVA ( Reader in , int format , Map < String , String > keywordMap ) throws IOException { StringBuilder temp = new StringBuilder ( ) ; int c ; while ( true ) { c = readChar ( in , "Incorrect AVA format" ) ; if ( c == '=' ) { break ; } temp . append ( ( char ) c ) ; } oid = AVAKeyword . getOID ( temp . toString ( ) , format , keywordMap ) ; temp . setLength ( 0 ) ; if ( format == RFC2253 ) { c = in . read ( ) ; if ( c == ' ' ) { throw new IOException ( "Incorrect AVA RFC2253 format - " + "leading space must be escaped" ) ; } } else { do { c = in . read ( ) ; } while ( ( c == ' ' ) || ( c == '\n' ) ) ; } if ( c == - 1 ) { value = new DerValue ( "" ) ; return ; } if ( c == '#' ) { value = parseHexString ( in , format ) ; } else if ( ( c == '"' ) && ( format != RFC2253 ) ) { value = parseQuotedString ( in , temp ) ; } else { value = parseString ( in , c , format , temp ) ; } }
parse an ava string formatted according to format .
