Here you can find the source of getShort(byte[] b, int index)
public static short getShort(byte[] b, int index)
//package com.java2s; public class Main { public static short getShort(byte[] b, int index) { return (short) (((b[index] << 8) | b[index + 1] & 0xff)); }/*from ww w. java 2s . c om*/ }