pub struct LinkableTempfile<'p, 'd> { /* private fields */ }
Expand description

A temporary file that may be given a persistent name.

Implementations

Write the file to its destination with the chosen permissions.

Write the given contents to the file to its destination with the chosen permissions.

Write the given contents to the file to its destination with the chosen permissions.

Write the file to its destination.

If a file exists at the destination already, and no override permissions are set, the permissions will be set to match the destination. Otherwise, a conservative default of 0o600 i.e. rw------- will be used.

Write the file to its destination, erroring out if there is an extant file.

Methods from Deref<Target = File>

Attempts to sync all OS-internal metadata to disk.

This corresponds to std::fs::File::sync_all.

This function is similar to sync_all, except that it may not synchronize file metadata to a filesystem.

This corresponds to std::fs::File::sync_data.

Truncates or extends the underlying file, updating the size of this file to become size.

This corresponds to std::fs::File::set_len.

Queries metadata about the underlying file.

This corresponds to std::fs::File::metadata.

Creates a new File instance that shares the same underlying file handle as the existing File instance.

This corresponds to std::fs::File::try_clone.

Changes the permissions on the underlying file.

This corresponds to std::fs::File::set_permissions.

Trait Implementations

Formats the value using the given formatter. Read more

The resulting type after dereferencing.

Dereferences the value.

Mutably dereferences the value.

Write a buffer into this writer, returning how many bytes were written. Read more

Flush this output stream, ensuring that all intermediately buffered contents reach their destination. Read more

Like write, except that it writes from a slice of buffers. Read more

🔬 This is a nightly-only experimental API. (can_vector)

Determines if this Writer has an efficient write_vectored implementation. Read more

Attempts to write an entire buffer into this writer. Read more

🔬 This is a nightly-only experimental API. (write_all_vectored)

Attempts to write multiple buffers into this writer. Read more

Writes a formatted string into this writer, returning any error encountered. Read more

Creates a “by reference” adapter for this instance of Write. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.