Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 66 for closeQuietly (0.1 sec)

  1. guava-tests/test/com/google/common/io/CloseablesTest.java

            new TestInputStream(new ByteArrayInputStream(new byte[1]), TestOption.CLOSE_THROWS);
        Closeables.closeQuietly(in);
        assertTrue(in.closed());
      }
    
      public void testCloseQuietly_readerWithEatenException() throws IOException {
        TestReader in = new TestReader(TestOption.CLOSE_THROWS);
        Closeables.closeQuietly(in);
        assertTrue(in.closed());
      }
    
      public void testCloseNull() throws IOException {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Mon Dec 04 17:37:03 UTC 2017
    - 4K bytes
    - Viewed (0)
  2. okhttp/src/main/kotlin/okhttp3/internal/connection/ConnectPlan.kt

            plan = this,
            nextPlan = retryTlsConnection,
            throwable = e,
          )
        } finally {
          user.removePlanToCancel(this)
          if (!success) {
            socket?.closeQuietly()
            rawSocket?.closeQuietly()
          }
        }
      }
    
      /** Does all the work necessary to build a full HTTP or HTTPS connection on a raw socket. */
      @Throws(IOException::class)
      private fun connectSocket() {
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sat Apr 20 17:03:43 UTC 2024
    - 18.6K bytes
    - Viewed (0)
  3. okhttp-coroutines/src/main/kotlin/okhttp3/coroutines/ExecuteAsync.kt

    import kotlinx.coroutines.ExperimentalCoroutinesApi
    import kotlinx.coroutines.suspendCancellableCoroutine
    import okhttp3.Call
    import okhttp3.Callback
    import okhttp3.Response
    import okhttp3.internal.closeQuietly
    import okio.IOException
    
    @ExperimentalCoroutinesApi // resume with a resource cleanup.
    suspend fun Call.executeAsync(): Response =
      suspendCancellableCoroutine { continuation ->
        continuation.invokeOnCancellation {
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Thu Apr 18 01:24:38 UTC 2024
    - 1.5K bytes
    - Viewed (0)
  4. fess-crawler/src/test/java/org/codelibs/fess/crawler/rule/impl/SitemapsRuleTest.java

                File temporaryFile = ((TemporaryFileInputStream) is).getTemporaryFile();
                assertTrue(temporaryFile.exists());
                CloseableUtil.closeQuietly(is);
                assertFalse(temporaryFile.exists());
            } else {
                CloseableUtil.closeQuietly(is);
            }
        }
    
        private ResponseData getTestData1_OK() {
            final ResponseData responseData = new ResponseData();
    Registered: Sun Nov 10 03:50:12 UTC 2024
    - Last Modified: Thu Feb 22 01:36:27 UTC 2024
    - 4.7K bytes
    - Viewed (0)
  5. fess-crawler/src/main/java/org/codelibs/fess/crawler/util/ResponseDataUtil.java

            } catch (final Exception e) {
                CloseableUtil.closeQuietly(fos); // for deleting file
                FileUtil.deleteInBackground(tempFile); // clean up
                throw new CrawlingAccessException("Could not read a response body: " + responseData.getUrl(), e);
            } finally {
                CloseableUtil.closeQuietly(fos);
            }
            return tempFile;
        }
    Registered: Sun Nov 10 03:50:12 UTC 2024
    - Last Modified: Thu Feb 22 01:36:27 UTC 2024
    - 1.8K bytes
    - Viewed (0)
  6. okhttp/src/main/kotlin/okhttp3/internal/cache/CacheInterceptor.kt

    import okhttp3.Cache
    import okhttp3.EventListener
    import okhttp3.Headers
    import okhttp3.Interceptor
    import okhttp3.Protocol
    import okhttp3.Request
    import okhttp3.Response
    import okhttp3.internal.closeQuietly
    import okhttp3.internal.connection.RealCall
    import okhttp3.internal.discard
    import okhttp3.internal.http.ExchangeCodec
    import okhttp3.internal.http.HttpMethod
    import okhttp3.internal.http.RealResponseBody
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Fri Mar 22 07:09:21 UTC 2024
    - 10.2K bytes
    - Viewed (0)
  7. mockwebserver/src/test/java/mockwebserver3/internal/http2/Http2Server.kt

            connection.start()
          } catch (e: IOException) {
            logger.log(Level.INFO, "Http2Server connection failure: $e")
            socket?.closeQuietly()
          } catch (e: Exception) {
            logger.log(Level.WARNING, "Http2Server unexpected failure", e)
            socket?.closeQuietly()
          }
        }
      }
    
      private fun doSsl(socket: Socket): SSLSocket {
        val sslSocket =
          sslSocketFactory.createSocket(
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 6.1K bytes
    - Viewed (0)
  8. src/main/java/org/codelibs/fess/helper/ProcessHelper.java

                final CountDownLatch latch = new CountDownLatch(3);
                final Process process = jobProcess.getProcess();
                new Thread(() -> {
                    try {
                        CloseableUtil.closeQuietly(process.getInputStream());
                    } catch (final Exception e) {
                        logger.warn("Could not close a process input stream.", e);
                    } finally {
                        latch.countDown();
    Registered: Thu Oct 31 13:40:30 UTC 2024
    - Last Modified: Fri Oct 11 21:20:39 UTC 2024
    - 6.4K bytes
    - Viewed (0)
  9. okhttp/src/test/java/okhttp3/SocksProxy.kt

    import java.util.concurrent.atomic.AtomicInteger
    import java.util.logging.Level
    import java.util.logging.Logger
    import okhttp3.TestUtil.threadFactory
    import okhttp3.internal.and
    import okhttp3.internal.closeQuietly
    import okhttp3.internal.threadName
    import okio.Buffer
    import okio.BufferedSink
    import okio.BufferedSource
    import okio.buffer
    import okio.sink
    import okio.source
    import okio.use
    
    /**
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Thu Apr 11 22:09:35 UTC 2024
    - 7.7K bytes
    - Viewed (0)
  10. fess-crawler/src/main/java/org/codelibs/fess/crawler/extractor/impl/TikaExtractor.java

                            }
                            parser.parse(in, new BodyContentHandler(writer), metadata, parseContext);
                        } finally {
                            CloseableUtil.closeQuietly(in);
                        }
                    }, contentEncoding, normalizeText);
                    if (StringUtil.isBlank(content)) {
                        if (resourceName != null) {
    Registered: Sun Nov 10 03:50:12 UTC 2024
    - Last Modified: Sat Oct 12 01:41:37 UTC 2024
    - 25K bytes
    - Viewed (0)
Back to top