@Test public void testTruncateUnicodeUnaligned() { String unicode257Bytes = ASCII_250 + "," + EURO + EURO; assertEquals(ASCII_250 + ",...", PubsubConstraints.truncateAttributeKey(unicode257Bytes)); }
public static String truncateAttributeKey(String key) { return truncateToFitUtf8ByteLength(key, MAX_ATTRIBUTE_KEY_BYTES); }
PubsubConstraints { public static String truncateAttributeKey(String key) { return truncateToFitUtf8ByteLength(key, MAX_ATTRIBUTE_KEY_BYTES); } }
PubsubConstraints { public static String truncateAttributeKey(String key) { return truncateToFitUtf8ByteLength(key, MAX_ATTRIBUTE_KEY_BYTES); }  }
PubsubConstraints { public static String truncateAttributeKey(String key) { return truncateToFitUtf8ByteLength(key, MAX_ATTRIBUTE_KEY_BYTES); }  static String truncateAttributeKey(String key); static String truncateAttributeValue(String value); static PubsubMessage ensureNonNull(PubsubMessage message); static TruncateAttributes truncateAttributes(); }
PubsubConstraints { public static String truncateAttributeKey(String key) { return truncateToFitUtf8ByteLength(key, MAX_ATTRIBUTE_KEY_BYTES); }  static String truncateAttributeKey(String key); static String truncateAttributeValue(String value); static PubsubMessage ensureNonNull(PubsubMessage message); static TruncateAttributes truncateAttributes(); static final int MAX_MESSAGE_BYTES; static final int MAX_ATTRIBUTES_PER_MESSAGE; static final int MAX_ATTRIBUTE_KEY_BYTES; static final int MAX_ATTRIBUTE_VALUE_BYTES; static final int MAX_ENCODABLE_MESSAGE_BYTES; static final String ELLIPSIS; }