Search Options

Results per page
Sort
Preferred Languages
Advance

Results 31 - 40 of 845 for CLOSE (0.2 sec)

  1. docs_src/dependencies/tutorial008_an.py

    
    async def dependency_a():
        dep_a = generate_dep_a()
        try:
            yield dep_a
        finally:
            dep_a.close()
    
    
    async def dependency_b(dep_a: Annotated[DepA, Depends(dependency_a)]):
        dep_b = generate_dep_b()
        try:
            yield dep_b
        finally:
            dep_b.close(dep_a)
    
    
    async def dependency_c(dep_b: Annotated[DepB, Depends(dependency_b)]):
        dep_c = generate_dep_c()
        try:
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sat Mar 18 12:29:59 UTC 2023
    - 531 bytes
    - Viewed (0)
  2. okhttp/src/test/java/okhttp3/EventListenerTest.kt

          Request.Builder()
            .url(server.url("/"))
            .build(),
        ).execute().close()
        listener.removeUpToEvent<CallEnd>()
        val call =
          client.newCall(
            Request.Builder()
              .url(server.url("/"))
              .build(),
          )
        val response = call.execute()
        response.close()
        assertThat(listener.recordedEventTypes()).containsExactly(
          "CallStart",
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Sat Jan 20 10:30:28 UTC 2024
    - 56.9K bytes
    - Viewed (2)
  3. android/guava/src/com/google/common/hash/HashingOutputStream.java

      public HashCode hash() {
        return hasher.hash();
      }
    
      // Overriding close() because FilterOutputStream's close() method pre-JDK8 has bad behavior:
      // it silently ignores any exception thrown by flush(). Instead, just close the delegate stream.
      // It should flush itself if necessary.
      @Override
      public void close() throws IOException {
        out.close();
      }
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Fri Oct 11 22:00:03 UTC 2024
    - 2.6K bytes
    - Viewed (0)
  4. cmd/metacache-stream_test.go

    	w := newMetacacheWriter(&buf, 1<<20)
    	defer w.Close()
    	err := r.readFn(func(object metaCacheEntry) bool {
    		err := w.write(object)
    		if err != nil {
    			t.Fatal(err)
    		}
    		return true
    	})
    	r.Close()
    	if err != io.EOF {
    		t.Fatal(err)
    	}
    	err = w.Close()
    	if err != nil {
    		t.Fatal(err)
    	}
    
    	r = newMetacacheReader(&buf)
    	defer r.Close()
    	names, err := r.readNames(-1)
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Mon Sep 19 18:05:16 UTC 2022
    - 15K bytes
    - Viewed (0)
  5. guava/src/com/google/common/io/Closer.java

       * any exceptions thrown when attempting to close a closeable will be suppressed. Otherwise, the
       * <i>first</i> exception to be thrown from an attempt to close a closeable will be thrown and any
       * additional exceptions that are thrown after that will be suppressed.
       */
      @Override
      public void close() throws IOException {
        Throwable throwable = thrown;
    
        // close closeables in LIFO order
        while (!stack.isEmpty()) {
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Tue May 07 15:26:58 UTC 2024
    - 10.4K bytes
    - Viewed (0)
  6. tests/prepared_stmt_test.go

    // TestPreparedStmtConcurrentClose test calling close and executing SQL concurrently
    // for example: one goroutine found error and just close the database, and others are executing SQL
    // this test making sure that the gorm would not get a Segmentation Fault,
    // and the only error cause by this is using a closed Stmt or gorm.ErrInvalidDB
    // and all of the goroutine must got gorm.ErrInvalidDB after database close
    Registered: Sun Nov 03 09:35:10 UTC 2024
    - Last Modified: Thu Aug 22 11:02:05 UTC 2024
    - 8.5K bytes
    - Viewed (0)
  7. samples/guide/src/main/java/okhttp3/recipes/WebSocketEcho.java

        System.out.println("MESSAGE: " + bytes.hex());
      }
    
      @Override public void onClosing(WebSocket webSocket, int code, String reason) {
        webSocket.close(1000, null);
        System.out.println("CLOSE: " + code + " " + reason);
      }
    
      @Override public void onFailure(WebSocket webSocket, Throwable t, Response response) {
        t.printStackTrace();
      }
    
      public static void main(String... args) {
        new WebSocketEcho().run();
      }
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Thu Apr 04 11:40:21 UTC 2024
    - 1.6K bytes
    - Viewed (0)
  8. istioctl/pkg/validate/validate_test.go

    	defer closeValidYAMLFile.Close()
    
    	validFilenameJSON, closeValidJSONFile := createTestFile(t, validJSON)
    	defer closeValidJSONFile.Close()
    
    	invalidFilenameYAML, closeInvalidYAMLFile := createTestFile(t, invalidYAML)
    	defer closeInvalidYAMLFile.Close()
    
    	warningFilename, closeWarningFile := createTestFile(t, warningsYAML)
    	defer closeWarningFile.Close()
    
    Registered: Wed Nov 06 22:53:10 UTC 2024
    - Last Modified: Fri Aug 02 16:18:14 UTC 2024
    - 21.4K bytes
    - Viewed (0)
  9. cmd/metacache-stream.go

    				continue
    			}
    		}
    	}()
    
    	return objs, nil
    }
    
    // Close and release resources.
    func (w *metacacheWriter) Close() error {
    	if w == nil || w.closer == nil {
    		return nil
    	}
    	w.streamWg.Wait()
    	err := w.closer()
    	w.closer = nil
    	return err
    }
    
    // Reset and start writing to new writer.
    // Close must have been called before this.
    func (w *metacacheWriter) Reset(out io.Writer) {
    Registered: Sun Nov 03 19:28:11 UTC 2024
    - Last Modified: Thu Apr 04 12:04:40 UTC 2024
    - 19.5K bytes
    - Viewed (0)
  10. src/archive/tar/writer_test.go

    		}
    		if err := tw.Close(); err != nil {
    			t.Fatalf("Close() = %v, want nil", err)
    		}
    		if _, err := tw.Write([]byte("Kilts")); err != ErrWriteAfterClose {
    			t.Fatalf("Write() = %v, want %v", err, ErrWriteAfterClose)
    		}
    		if err := tw.Flush(); err != ErrWriteAfterClose {
    			t.Fatalf("Flush() = %v, want %v", err, ErrWriteAfterClose)
    		}
    		if err := tw.Close(); err != nil {
    Registered: Tue Nov 05 11:13:11 UTC 2024
    - Last Modified: Mon Sep 23 14:32:33 UTC 2024
    - 39.4K bytes
    - Viewed (0)
Back to top