Package test;
Import java. util. stringtokenizer;
Import java. Io. file;
Import java. Io. outputstream;
Import java. Io. fileoutputstream;
Import java. Io. ioexception;
Public class test {
Public static string Ss = "title1 = Java: This is the tile1 field;" +
"Title2 = Java: This is the tile2 field;" +
"Title3 = Java: This is the tile3 field;" +
"Title4 = Java: This is the tile4 field;" +
"Title5 = Java: This is the tile5 field ;"
;
Public test (){
}
Public static void main (string [] ARGs) throws ioexception {
Stringtokenizer ST = new stringtokenizer (SS, "=;", false );
// System. Out. println ("st. counttokens ():" + st. counttokens ());
While (St. hasmoretokens ()){
// System. Out. println ("st. counttokens ():" + st. counttokens ());
String key = ST. nexttoken ();
String value = ST. nexttoken ();
// System. Out. println ("Key =:" + key + "\ n" + "value =:" + value );
}
String S = "ABCDE & fgh61 = klklkl ";
System. Out. println ("S. indexof (61):" + S. indexof (61 ));
File file;
File = file. createtempfile ("policy", "pdf ");
System. Out. println (file. getname ());
System. Out. println (file. getabsolutepath ());
System. Out. println (file. getabsolutefile ());
System. Out. println (file. GetCanonicalPath ());
System. Out. println (file. tourl ());
System. Out. println (file. tostring ());
Outputstream out = new fileoutputstream (File );
}
}