stripReservedCharacter function

String stripReservedCharacter(
  1. String str
)

Implementation

String stripReservedCharacter(String str) {
  return str
      .replaceAll("\u0002", '\u0002\u0002')
      .replaceAll("\u0001", '\u0001\u0002')
      .replaceAll(RESERVED_DELIMITER, '\u0001\u0001');
}