public DerValue(String value) throws IOException {
  boolean isPrintableString=true;
  for (int i=0; i < value.length(); i++) {
    if (!isPrintableStringChar(value.charAt(i))) {
      isPrintableString=false;
      break;
    }
  }
  data=init(isPrintableString ? tag_PrintableString : tag_UTF8String,value);
}

public DerValue ( String value ) throws IOException { boolean isPrintableString = true ; for ( int i = 0 ; i < value . length ( ) ; i ++ ) { if ( ! isPrintableStringChar ( value . charAt ( i ) ) ) { isPrintableString = false ; break ; } } data = init ( isPrintableString ? tag_PrintableString : tag_UTF8String , value ) ; }
creates a printablestring or utf8string der value from a string
