- Sort Score
- Num 10 results
- Language All
Results 1 - 10 of 11 for ByteProcessor (0.54 seconds)
-
android/guava/src/com/google/common/io/ByteProcessor.java
* {@code false} when you want to stop processing. * * @author Chris Nokleberg * @since 1.0 */ @DoNotMock("Implement it normally") @J2ktIncompatible @GwtIncompatible public interface ByteProcessor<T extends @Nullable Object> { /** * This method will be called for each chunk of bytes in an input stream. The implementation * should process the bytes from {@code buf[off]} through {@code buf[off + len - 1]} (inclusive).Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Sun Dec 22 03:38:46 GMT 2024 - 2K bytes - Click Count (0) -
guava-tests/test/com/google/common/io/ByteSourceTest.java
assertTrue(source.wasStreamOpened() && source.wasStreamClosed()); } public void testRead_withProcessor() throws IOException { byte[] processedBytes = new byte[bytes.length]; ByteProcessor<byte[]> processor = new ByteProcessor<byte[]>() { int pos; @Override public boolean processBytes(byte[] buf, int off, int len) throws IOException {
Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Thu Mar 19 18:53:45 GMT 2026 - 15.6K bytes - Click Count (0) -
android/guava-tests/test/com/google/common/io/ByteSourceTest.java
assertTrue(source.wasStreamOpened() && source.wasStreamClosed()); } public void testRead_withProcessor() throws IOException { byte[] processedBytes = new byte[bytes.length]; ByteProcessor<byte[]> processor = new ByteProcessor<byte[]>() { int pos; @Override public boolean processBytes(byte[] buf, int off, int len) throws IOException {
Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Thu Mar 19 18:53:45 GMT 2026 - 15.6K bytes - Click Count (0) -
android/guava-tests/test/com/google/common/io/FilesTest.java
assertThat(Files.getNameWithoutExtension("/foo/.bar/blah")).isEqualTo("blah"); } public void testReadBytes() throws IOException { ByteProcessor<byte[]> processor = new ByteProcessor<byte[]>() { private final ByteArrayOutputStream out = new ByteArrayOutputStream(); @Override
Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Thu Mar 19 18:53:45 GMT 2026 - 22.8K bytes - Click Count (0) -
guava-tests/test/com/google/common/io/ByteSourceTester.java
} })); } public void testRead_usingByteProcessor() throws IOException { byte[] readBytes = source.read( new ByteProcessor<byte[]>() { final ByteArrayOutputStream out = new ByteArrayOutputStream(); @Override public boolean processBytes(byte[] buf, int off, int len) throws IOException {Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Thu Mar 19 18:53:45 GMT 2026 - 8.6K bytes - Click Count (0) -
guava-tests/test/com/google/common/io/ByteStreamsTest.java
assertThat(ByteStreams.readBytes(new ByteArrayInputStream(array), new TestByteProcessor())) .isEqualTo(array); } private static class TestByteProcessor implements ByteProcessor<byte[]> { private final ByteArrayOutputStream out = new ByteArrayOutputStream(); @Override public boolean processBytes(byte[] buf, int off, int len) { out.write(buf, off, len);
Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Tue Mar 17 19:26:39 GMT 2026 - 22K bytes - Click Count (0) -
android/guava-tests/test/com/google/common/io/ByteStreamsTest.java
assertThat(ByteStreams.readBytes(new ByteArrayInputStream(array), new TestByteProcessor())) .isEqualTo(array); } private static class TestByteProcessor implements ByteProcessor<byte[]> { private final ByteArrayOutputStream out = new ByteArrayOutputStream(); @Override public boolean processBytes(byte[] buf, int off, int len) { out.write(buf, off, len);
Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Tue Mar 17 19:26:39 GMT 2026 - 22K bytes - Click Count (0) -
android/guava-tests/test/com/google/common/io/ByteSourceTester.java
} })); } public void testRead_usingByteProcessor() throws IOException { byte[] readBytes = source.read( new ByteProcessor<byte[]>() { final ByteArrayOutputStream out = new ByteArrayOutputStream(); @Override public boolean processBytes(byte[] buf, int off, int len) throws IOException {Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Thu Mar 19 18:53:45 GMT 2026 - 8.6K bytes - Click Count (0) -
android/guava/src/com/google/common/io/ByteSource.java
* processor} throws an {@code IOException} * @since 16.0 */ @CanIgnoreReturnValue // some processors won't return a useful result @ParametricNullness public <T extends @Nullable Object> T read(ByteProcessor<T> processor) throws IOException { checkNotNull(processor); Closer closer = Closer.create(); try { InputStream in = closer.register(openStream());Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Mon Sep 08 18:35:13 GMT 2025 - 25.7K bytes - Click Count (0) -
android/guava/src/com/google/common/io/Files.java
imports = "com.google.common.io.Files") @CanIgnoreReturnValue // some processors won't return a useful result @ParametricNullness public static <T extends @Nullable Object> T readBytes(File file, ByteProcessor<T> processor) throws IOException { return asByteSource(file).read(processor); } /** * Computes the hash code of the {@code file} using {@code hashFunction}. *
Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Mon Jan 05 22:13:21 GMT 2026 - 32.8K bytes - Click Count (0)