Struct cfile::CFile
[−]
[src]
pub struct CFile {
// some fields omitted
}A reference to an open stream on the filesystem.
An instance of a CFile can be read and/or written depending on what modes it was opened with.
CFile also implement Seek to alter the logical cursor that the file contains internally.
Methods
impl CFile
fn from_raw(f: *mut FILE, owned: bool) -> Result<CFile>
Constructs a CFile from a raw pointer.
fn reopen(&self, filename: &str, mode: &str) -> Result<CFile>
opens the file whose name is the string pointed to by filename
and associates the stream pointed to by stream with it.
The original stream (if it exists) is closed.
The mode argument is used just as in the open() function.
Methods from Deref<Target=RawFile>
fn stream(&self) -> RawFilePtr
returns the raw pointer of the stream