164165166167168169170171172173174
targetArray[targetIdx] = (byte) ('?' & 0x7f); targetIdx += 1; } else if (errorHandling == EncodingErrorType.FAIL) { throw new EncodingException(); } } } buffer.setCursor(targetIdx);
6667686970717273
} catch (UnsupportedEncodingException e) { // this should not happen, as the encodings should have been checked by // the system already ... throw new EncodingException("Failed to encode the string: " + e.getMessage()); } }
109110111112113114115116117
} catch (UnsupportedEncodingException e) { // this should not happen, as the encodings should have been checked by // the system already ... throw new EncodingException("Failed to encode the string: " + e.getMessage()); } return buffer; }
targetArray[targetIdx] = (byte) ('?' & 0xff); targetIdx += 1; } else if (errorHandling == EncodingErrorType.FAIL) { throw new EncodingException(); } } } buffer.setCursor(targetIdx);