Reading Writing Text  «Prev 


Java String Constructors

public String(byte bytes[], int offset, int length, String encoding) throws UnsupportedEncodingException
 
public String(byte bytes[], String encoding) throws UnsupportedEncodingException

If you have a byte array t that you know is encoded with the ISO 8859-9 characters set (essentially ASCII plus Turkish), you would convert it into Unicode like this:
String s = new String(t, "8859-9");