错误:UnsupportedEncodingException cannot to a type

/**
* @author Tommy
*将字节型数据转化为字符集输出的构造器
*"String (byte[]bytes,int offset,int length,String charsetName)"意即:将第一个字节数组中从第"offset"个位置的字符开始到"length"长度结束,
*其中间的字符形成字符串对象,然后将这个字符串按照某种字符集输出
*字符集一般有"usascii"、"utf-8"、"utf-16be"、"utf-16le"、"utf-16"等样式
*/
public class str5 {
public static void main (String[]args){
byte[]b={97,98,99,100,101,102};
try{
String str=new String(b,3,2,"utf-8");
System.out.println (str);
}
catch (UnsupportedEncodingException ex){
}
}
}