Trait unsafe_io::os::windows::FromRawHandleOrSocket [−][src]
Like FromRawHandle
and FromRawSocket
, but implementable by types
which can implement both.
Note: Don't implement this trait for types which can only implement one or the other, such that it would need to panic if passed the wrong form.
Required methods
unsafe fn from_raw_handle_or_socket(
raw_handle_or_socket: RawHandleOrSocket
) -> Self
[src]
raw_handle_or_socket: RawHandleOrSocket
) -> Self
Like FromRawHandle::from_raw_handle
and
FromRawSocket::from_raw_socket
but can be passed either type.
Safety
raw_handle_or_socket
must be valid and otherwise unowned.
Implementors
impl FromRawHandleOrSocket for UnsafeHandle
[src]
UnsafeHandle
doesn't own its handle; see the comments for
impl AsRawFd for UnsafeHandle
.
unsafe fn from_raw_handle_or_socket(
raw_handle_or_socket: RawHandleOrSocket
) -> Self
[src]
raw_handle_or_socket: RawHandleOrSocket
) -> Self
impl FromRawHandleOrSocket for UnsafeReadable
[src]
UnsafeReadable
doesn't own its handle; see the comments for
impl AsRawFd for UnsafeHandle
.
unsafe fn from_raw_handle_or_socket(
raw_handle_or_socket: RawHandleOrSocket
) -> Self
[src]
raw_handle_or_socket: RawHandleOrSocket
) -> Self
impl FromRawHandleOrSocket for UnsafeWriteable
[src]
UnsafeWriteable
doesn't own its handle; see the comments for
impl AsRawFd for UnsafeHandle
.
unsafe fn from_raw_handle_or_socket(
raw_handle_or_socket: RawHandleOrSocket
) -> Self
[src]
raw_handle_or_socket: RawHandleOrSocket
) -> Self