Here you can find the source of decode(String str, String encoding)
static public String decode(String str, String encoding)
//package com.java2s; import java.io.UnsupportedEncodingException; public class Main { static public String decode(String str, String encoding) { if (str == null || str.length() == 0) return str; try {/*from w ww . j av a2s.c o m*/ return new String(str.getBytes("iso-8859-1"), encoding); } catch (UnsupportedEncodingException e) { return str; } } }