Here you can find the source of putUnsignedShort(final ByteBuffer pByteBuffer, final int pPosition, final int pValue)
public static void putUnsignedShort(final ByteBuffer pByteBuffer, final int pPosition, final int pValue)
//package com.java2s; import java.nio.ByteBuffer; public class Main { public static void putUnsignedShort(final ByteBuffer pByteBuffer, final int pValue) { pByteBuffer.putShort((short) (pValue & 0xFFFF)); }/*from w w w . ja va 2s. c om*/ public static void putUnsignedShort(final ByteBuffer pByteBuffer, final int pPosition, final int pValue) { pByteBuffer.putShort(pPosition, (short) (pValue & 0xFFFF)); } }