Struct unsafe_io::UnsafeFile [−][src]
#[repr(transparent)]pub struct UnsafeFile(_);
Expand description
A non-owning unsafe I/O handle which on Windows is limited to handling what
Windows considers to be RawHandle
s—mainly files and pipes.
Implementations
impl UnsafeFile
[src]
impl UnsafeFile
[src]#[must_use]pub const fn as_unowned_unsafe_handle(self) -> UnsafeHandle
[src]
#[must_use]pub const fn as_unowned_unsafe_handle(self) -> UnsafeHandle
[src]Like AsUnsafeHandle::as_unsafe_handle
, but isn’t unsafe because it
doesn’t imply a dereference.
#[must_use]pub const fn into_unowned_unsafe_handle(self) -> UnsafeHandle
[src]
#[must_use]pub const fn into_unowned_unsafe_handle(self) -> UnsafeHandle
[src]Like IntoUnsafeHandle::into_unsafe_handle
, but isn’t unsafe because it
doesn’t imply a dereference.
#[must_use]pub const fn as_unowned_raw_fd(self) -> RawFd
[src]
#[must_use]pub const fn as_unowned_raw_fd(self) -> RawFd
[src]Like AsRawFd::as_raw_fd
, but isn’t unsafe because it
doesn’t imply a dereference.
#[must_use]pub const fn into_unowned_raw_fd(self) -> RawFd
[src]
#[must_use]pub const fn into_unowned_raw_fd(self) -> RawFd
[src]Like IntoRawFd::into_raw_fd
, but isn’t unsafe because it
doesn’t imply a dereference.
#[must_use]pub const fn unowned_from_raw_fd(raw_fd: RawFd) -> Self
[src]
#[must_use]pub const fn unowned_from_raw_fd(raw_fd: RawFd) -> Self
[src]Like FromRawFd::from_raw_fd
, but isn’t unsafe because it doesn’t
imply a dereference.
Trait Implementations
impl AsRawFd for UnsafeFile
[src]
impl AsRawFd for UnsafeFile
[src]UnsafeFile
doesn’t own its handle; see the comments for
impl AsRawFd for UnsafeHandle
.
impl Clone for UnsafeFile
[src]
impl Clone for UnsafeFile
[src]fn clone(&self) -> UnsafeFile
[src]
fn clone(&self) -> UnsafeFile
[src]Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]Performs copy-assignment from source
. Read more
impl Debug for UnsafeFile
[src]
impl Debug for UnsafeFile
[src]impl FromRawFd for UnsafeFile
[src]
impl FromRawFd for UnsafeFile
[src]UnsafeFile
doesn’t own its handle; see the comments for
impl AsRawFd for UnsafeHandle
.
unsafe fn from_raw_fd(raw_fd: RawFd) -> Self
[src]
unsafe fn from_raw_fd(raw_fd: RawFd) -> Self
[src]Constructs a new instance of Self
from the given raw file
descriptor. Read more
impl IntoRawFd for UnsafeFile
[src]
impl IntoRawFd for UnsafeFile
[src]UnsafeFile
doesn’t own its handle; see the comments for
impl AsRawFd for UnsafeHandle
.
fn into_raw_fd(self) -> RawFd
[src]
fn into_raw_fd(self) -> RawFd
[src]Consumes this object, returning the raw underlying file descriptor. Read more
impl Copy for UnsafeFile
[src]
Auto Trait Implementations
impl RefUnwindSafe for UnsafeFile
impl Send for UnsafeFile
impl Sync for UnsafeFile
impl Unpin for UnsafeFile
impl UnwindSafe for UnsafeFile
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more
impl<T> ToOwned for T where
T: Clone,
[src]
impl<T> ToOwned for T where
T: Clone,
[src]type Owned = T
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn to_owned(&self) -> T
[src]Creates owned data from borrowed data, usually by cloning. Read more
pub fn clone_into(&self, target: &mut T)
[src]
pub fn clone_into(&self, target: &mut T)
[src]🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more