github.com/shogo82148/std@v1.22.1-0.20240327122250-4e474527810c/internal/poll/fd_poll_runtime.go (about)

     1  // Copyright 2013 The Go Authors. All rights reserved.
     2  // Use of this source code is governed by a BSD-style
     3  // license that can be found in the LICENSE file.
     4  
     5  //go:build unix || windows || wasip1
     6  
     7  package poll
     8  
     9  import (
    10  	"github.com/shogo82148/std/time"
    11  )
    12  
    13  // SetDeadline sets the read and write deadlines associated with fd.
    14  func (fd *FD) SetDeadline(t time.Time) error
    15  
    16  // SetReadDeadline sets the read deadline associated with fd.
    17  func (fd *FD) SetReadDeadline(t time.Time) error
    18  
    19  // SetWriteDeadline sets the write deadline associated with fd.
    20  func (fd *FD) SetWriteDeadline(t time.Time) error
    21  
    22  // IsPollDescriptor reports whether fd is the descriptor being used by the poller.
    23  // This is only used for testing.
    24  func IsPollDescriptor(fd uintptr) bool