Here you can find the source of encode_u8(String what)
private static final byte[] encode_u8(String what)
//package com.java2s; import java.io.UnsupportedEncodingException; public class Main { private static final byte[] encode_u8(String what) { byte u8[]; if (what == null) { u8 = null;/* w ww . j ava 2 s. c o m*/ } else { try { u8 = what.getBytes("UTF-8"); } catch (UnsupportedEncodingException e) { e.printStackTrace(); throw new InternalError(e.toString()); } } return u8; } }