Using CharsetDecoder
import java.nio.charset.CharacterCodingException;
import java.nio.charset.CharsetDecoder;
import java.nio.charset.CodingErrorAction;
import java.nio.charset.StandardCharsets;
CharsetDecoder charsetDecoder = StandardCharsets.UTF_16.newDecoder();
charsetDecoder.onUnmappableCharacter(CodingErrorAction.REPLACE)
.onMalformedInput(CodingErrorAction.REPLACE)
.replaceWith("*");
byte[] byteArr = {-2, -1, 0, 100, 0, 101, 0, 109, 0, 111, 0, 33, -10};
String stringFromBytes = charsetDecoder.decode(ByteBuffer.wrap(byteArr)).toString();