- Sort Score
- Result 10 results
- Languages All
Results 21 - 30 of 44 for openStream (0.05 sec)
-
src/main/java/org/codelibs/core/io/CopyUtil.java
*/ public static int copy(final URL in, final OutputStream out) { assertArgumentNotNull("in", in); assertArgumentNotNull("out", out); final InputStream is = URLUtil.openStream(in); try { if (out instanceof FileOutputStream) { return copyInternal(wrap(is), (FileOutputStream) out); } return copyInternal(wrap(is), wrap(out));
Registered: Fri Sep 05 20:58:11 UTC 2025 - Last Modified: Thu Jul 31 08:16:49 UTC 2025 - 45.2K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/io/TestByteSource.java
@Override public boolean wasStreamOpened() { return inputStreamOpened; } @Override public boolean wasStreamClosed() { return inputStreamClosed; } @Override public InputStream openStream() throws IOException { inputStreamOpened = true; return new RandomAmountInputStream(new In(), new Random()); } private final class In extends TestInputStream { In() throws IOException {
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Mon Jul 14 14:44:08 UTC 2025 - 2K bytes - Viewed (0) -
guava-tests/test/com/google/common/io/TestByteSource.java
@Override public boolean wasStreamOpened() { return inputStreamOpened; } @Override public boolean wasStreamClosed() { return inputStreamClosed; } @Override public InputStream openStream() throws IOException { inputStreamOpened = true; return new RandomAmountInputStream(new In(), new Random()); } private final class In extends TestInputStream { In() throws IOException {
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Mon Jul 14 14:44:08 UTC 2025 - 2K bytes - Viewed (0) -
guava-tests/test/com/google/common/io/CharSourceTest.java
// read the first 8 chars manually, since there's no equivalent to ByteSource.slice // TODO(cgdecker): Add CharSource.slice? StringBuilder builder = new StringBuilder(); Reader reader = concatenated.openStream(); // no need to worry about closing for (int i = 0; i < 8; i++) { builder.append((char) reader.read()); } assertEquals(expected, builder.toString()); }
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Tue May 13 17:27:14 UTC 2025 - 11.5K bytes - Viewed (0) -
api/maven-api-core/src/test/java/org/apache/maven/api/services/SourcesTest.java
String content = "test content"; Files.writeString(testFile, content); Source source = Sources.fromPath(testFile); try (InputStream inputStream = source.openStream()) { String readContent = new String(inputStream.readAllBytes()); assertEquals(content, readContent); } } @Test void testNullHandling() {
Registered: Sun Sep 07 03:35:12 UTC 2025 - Last Modified: Fri Mar 21 04:56:21 UTC 2025 - 5.2K bytes - Viewed (0) -
android/guava/src/com/google/common/io/MultiInputStream.java
} } } /** Closes the current input stream and opens the next one, if any. */ private void advance() throws IOException { close(); if (it.hasNext()) { in = it.next().openStream(); } } @Override public int available() throws IOException { if (in == null) { return 0; } return in.available(); } @Override
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Wed May 14 19:40:47 UTC 2025 - 2.8K bytes - Viewed (0) -
compat/maven-builder-support/src/main/java/org/apache/maven/building/UrlSource.java
this.url = Objects.requireNonNull(url, "url cannot be null"); this.hashCode = Objects.hashCode(url); } @Override public InputStream getInputStream() throws IOException { return url.openStream(); } @Override public String getLocation() { return url.toString(); } /** * Gets the URL of this source. *
Registered: Sun Sep 07 03:35:12 UTC 2025 - Last Modified: Wed Jan 15 18:51:29 UTC 2025 - 2.4K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/io/CharSourceTest.java
// read the first 8 chars manually, since there's no equivalent to ByteSource.slice // TODO(cgdecker): Add CharSource.slice? StringBuilder builder = new StringBuilder(); Reader reader = concatenated.openStream(); // no need to worry about closing for (int i = 0; i < 8; i++) { builder.append((char) reader.read()); } assertEquals(expected, builder.toString()); }
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Tue May 13 17:27:14 UTC 2025 - 11.5K bytes - Viewed (0) -
src/main/java/org/codelibs/core/io/TraversalUtil.java
this.zipUrl = zipUrl; this.prefix = prefix; } private void loadFromZip(final URL zipUrl) { final ZipInputStream zis = new ZipInputStream(URLUtil.openStream(zipUrl)); try { ZipEntry entry = null; while ((entry = ZipInputStreamUtil.getNextEntry(zis)) != null) { entryNames.add(entry.getName());
Registered: Fri Sep 05 20:58:11 UTC 2025 - Last Modified: Thu Jul 31 08:16:49 UTC 2025 - 18.6K bytes - Viewed (0) -
.teamcity/.mvn/wrapper/MavenWrapperDownloader.java
} }); } URL website = new URL(urlString); ReadableByteChannel rbc; rbc = Channels.newChannel(website.openStream()); FileOutputStream fos = new FileOutputStream(destination); fos.getChannel().transferFrom(rbc, 0, Long.MAX_VALUE); fos.close(); rbc.close(); }
Registered: Wed Sep 10 11:36:15 UTC 2025 - Last Modified: Wed Feb 26 01:48:39 UTC 2020 - 4.8K bytes - Viewed (0)