1 5 6 package org.exoplatform.services.portletcontainer.imp; 7 8 import java.io.UnsupportedEncodingException ; 9 10 15 public class TestCharacterEncoding extends BaseTest{ 16 public TestCharacterEncoding(String s) { 17 super(s); 18 } 19 20 public void testSetCharacterEncoding() throws UnsupportedEncodingException { 21 String s = "\u00e1zov portletu"; 22 System.out.println("STRING "+s); 23 24 s = "\u0160t\u00fdl"; 25 System.out.println("STRING "+s); 26 27 s = "\u8D1F\u8F7D\u6D4B\u8BD5"; 28 System.out.println(new String (s.getBytes(), "UTF-8")); 29 30 s = "\u5355\u5143\u6D4B\u8BD5cc"; 31 System.out.println(new String (s.getBytes(), "UTF-8")); 32 33 System.out.println("�tre aim� et d�t�st� to�t � la fois c'�st �a"); 34 35 s = "Septemberov\u00fd \u010dl\u00e1nok"; 36 System.out.println(s); 37 System.out.println(new String (s.getBytes(), "UTF-8")); 38 39 s = "�l�nok Spr�vy Testy za�a�enia"; 40 System.out.println(new String (s.getBytes(), "ISO-8859-2")); 41 } 42 } 43 | Popular Tags |