Search Options

Results per page
Sort
Preferred Languages
Advance

Results 101 - 110 of 1,629 for closeFn (0.14 sec)

  1. src/net/http/transfer.go

    	mu         sync.Mutex // guards following, and calls to Read and Close
    	sawEOF     bool
    	closed     bool
    	earlyClose bool   // Close called and we didn't read to the end of src
    	onHitEOF   func() // if non-nil, func to call when EOF is Read
    }
    
    // ErrBodyReadAfterClose is returned when reading a [Request] or [Response]
    // Body after the body has been closed. This typically happens when the body is
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Mar 21 22:14:00 UTC 2024
    - 31.1K bytes
    - Viewed (0)
  2. pkg/scheduler/profile/profile.go

    func (m Map) HandlesSchedulerName(name string) bool {
    	_, ok := m[name]
    	return ok
    }
    
    // Close closes all frameworks registered in this map.
    func (m Map) Close() error {
    	var errs []error
    	for name, f := range m {
    		err := f.Close()
    		if err != nil {
    			errs = append(errs, fmt.Errorf("framework %s failed to close: %w", name, err))
    		}
    	}
    	return errors.Join(errs...)
    }
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sat Jan 06 01:11:19 UTC 2024
    - 4K bytes
    - Viewed (0)
  3. staging/src/k8s.io/apimachinery/pkg/runtime/serializer/streaming/streaming.go

    type Decoder interface {
    	// Decode will return io.EOF when no more objects are available.
    	Decode(defaults *schema.GroupVersionKind, into runtime.Object) (runtime.Object, *schema.GroupVersionKind, error)
    	// Close closes the underlying stream.
    	Close() error
    }
    
    // Serializer is a factory for creating encoders and decoders that work over streams.
    type Serializer interface {
    	NewEncoder(w io.Writer) Encoder
    	NewDecoder(r io.ReadCloser) Decoder
    }
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Aug 25 14:51:36 UTC 2023
    - 3.7K bytes
    - Viewed (0)
  4. staging/src/k8s.io/apimachinery/pkg/util/net/util_test.go

    	}
    	defer resp.Body.Close()
    	data, err := io.ReadAll(resp.Body)
    	if err != nil {
    		t.Fatalf("unexpected error: %+v", err)
    	}
    	if string(data) != "Hello, HTTP/2.0" {
    		t.Fatalf("unexpected response: %s", data)
    	}
    
    	// Deliberately let the LB stop proxying traffic for the current
    	// connection. This mimics a broken TCP connection that's not properly
    	// closed.
    	close(stopCh)
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sat May 20 19:02:55 UTC 2023
    - 4.3K bytes
    - Viewed (0)
  5. staging/src/k8s.io/apimachinery/pkg/util/wait/wait.go

    // when the provided parentCh is closed. The implementation returns
    // context.Canceled for Err() if and only if the parentCh is closed.
    func ContextForChannel(parentCh <-chan struct{}) context.Context {
    	return channelContext{stopCh: parentCh}
    }
    
    var _ context.Context = channelContext{}
    
    // channelContext will behave as if the context were cancelled when stopCh is
    // closed.
    type channelContext struct {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Mar 14 19:14:11 UTC 2023
    - 7.1K bytes
    - Viewed (0)
  6. platforms/core-configuration/configuration-cache/src/integTest/groovy/org/gradle/internal/cc/impl/ConfigurationCacheFlowScopeIntegrationTest.groovy

                    private Boolean closed = false
    
                    void setColor(String color) {
                        assert !closed
                        println('(' + color + ')')
                    }
    
                    @Override
                    void close() {
                        println '(closed)'
                        closed = true
                    }
                }
    
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Sat Jun 08 11:29:25 UTC 2024
    - 11.5K bytes
    - Viewed (0)
  7. cmd/bitrot.go

    }
    
    // Close all the readers.
    func closeBitrotReaders(rs []io.ReaderAt) {
    	for _, r := range rs {
    		if r != nil {
    			if br, ok := r.(io.Closer); ok {
    				br.Close()
    			}
    		}
    	}
    }
    
    // Close all the writers.
    func closeBitrotWriters(ws []io.Writer) {
    	for _, w := range ws {
    		if w != nil {
    			if bw, ok := w.(io.Closer); ok {
    				bw.Close()
    			}
    		}
    	}
    Registered: Sun Jun 16 00:44:34 UTC 2024
    - Last Modified: Tue Jan 30 20:43:25 UTC 2024
    - 7.6K bytes
    - Viewed (0)
  8. okhttp/src/main/kotlin/okhttp3/Call.kt

       *
       * To avoid leaking resources callers should close the [Response] which in turn will close the
       * underlying [ResponseBody].
       *
       * ```java
       * // ensure the response (and underlying response body) is closed
       * try (Response response = client.newCall(request).execute()) {
       *   ...
       * }
       * ```
       *
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Wed Dec 20 23:27:07 UTC 2023
    - 3.6K bytes
    - Viewed (0)
  9. pkg/volume/csi/csi_client.go

    	nodeClient csipbv1.NodeClient,
    	closer io.Closer,
    	err error,
    )
    
    type nodeV1AccessModeMapper func(am api.PersistentVolumeAccessMode) csipbv1.VolumeCapability_AccessMode_Mode
    
    // newV1NodeClient creates a new NodeClient with the internally used gRPC
    // connection set up. It also returns a closer which must be called to close
    // the gRPC connection when the NodeClient is not used anymore.
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Sep 20 10:15:36 UTC 2022
    - 22.1K bytes
    - Viewed (0)
  10. android/guava-tests/test/com/google/common/io/CharSourceTest.java

      }
    
      public void testCopyToAppendable_doesNotCloseIfWriter() throws IOException {
        TestWriter writer = new TestWriter();
        assertFalse(writer.closed());
        source.copyTo(writer);
        assertFalse(writer.closed());
      }
    
      public void testClosesOnErrors_copyingToCharSinkThatThrows() {
        for (TestOption option : EnumSet.of(OPEN_THROWS, WRITE_THROWS, CLOSE_THROWS)) {
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Tue May 07 15:26:58 UTC 2024
    - 10.5K bytes
    - Viewed (0)
Back to top