@Test public void testLength() throws Exception { byte[] bytes = "FOOBAR".getBytes("UTF-8"); ByteArrayCharSequence bacs = new ByteArrayCharSequence(bytes, 0, bytes.length); assertEquals(6, bacs.length()); }
@Override public int length() { return end - start; }
ByteArrayCharSequence implements CharSequence { @Override public int length() { return end - start; } }
ByteArrayCharSequence implements CharSequence { @Override public int length() { return end - start; } ByteArrayCharSequence(byte[] bytes, int start, int end); }
ByteArrayCharSequence implements CharSequence { @Override public int length() { return end - start; } ByteArrayCharSequence(byte[] bytes, int start, int end); @Override int length(); @Override char charAt(int index); @Override ByteArrayCharSequence subSequence(int start, int end); @Override String toString(); static byte[] toSingleByteUtf8Encoding(CharSequence charSequence); }
ByteArrayCharSequence implements CharSequence { @Override public int length() { return end - start; } ByteArrayCharSequence(byte[] bytes, int start, int end); @Override int length(); @Override char charAt(int index); @Override ByteArrayCharSequence subSequence(int start, int end); @Override String toString(); static byte[] toSingleByteUtf8Encoding(CharSequence charSequence);  }