1 28 29 package com.caucho.vfs.i18n; 30 31 import com.caucho.vfs.OutputStreamWithBuffer; 32 33 import java.io.IOException ; 34 35 39 public class WindowsHackWriter extends EncodingWriter { 40 private final static WindowsHackWriter _writer = new WindowsHackWriter(); 41 42 45 public WindowsHackWriter() 46 { 47 } 48 49 52 public String getJavaEncoding() 53 { 54 return "WindowsHack"; 55 } 56 57 65 public EncodingWriter create(String javaEncoding) 66 { 67 return _writer; 68 } 69 70 75 public void write(OutputStreamWithBuffer os, char ch) 76 throws IOException 77 { 78 os.write(ch); 79 } 80 81 88 public void write(OutputStreamWithBuffer os, char []cbuf, int off, int len) 89 throws IOException 90 { 91 for (int i = 0; i < len; i++) 92 os.write(cbuf[off + i]); 93 } 94 } 95 96 97 | Popular Tags |