Here you can find the source of bytesToChar(byte[] arr, int offset)
public static char bytesToChar(byte[] arr, int offset)
//package com.java2s; //License from project: Open Source License public class Main { public static char bytesToChar(byte[] arr, int offset) { return (char) ((arr[offset] << 8) | arr[offset + 1]); }// www . j a va 2 s . c o m }