import java.io.*; import javax.microedition.io.file.*; import javax.microedition.io.*; public class File { InputStream is; OutputStream os; public FileConnection fc; public String string; public char c; public StringEncoder win; public File(){ } public String read(String url){ string = new String(); win = new StringEncoder(); try{ is = getClass().getResourceAsStream(url); while(true){ int a = is.read(); if (a == -1) break; c = win.decodeCharCP1251(a); if (a == 192) c = 'A'; string = string + c; } is.close(); } catch (Exception e){ string = " Failed to Loadning File: " + url; } return string; } public void writeFile(String name, String str){ try { fc = (FileConnection)Connector.open(name); os = fc.openOutputStream(); for(int i= 0; i