Struct dokan::Drive[][src]

pub struct Drive<'a> { /* fields omitted */ }

A builder that allows configuring and mounting a volume.

Implementations

impl<'a> Drive<'a>[src]

pub fn new() -> Self[src]

Creates a new instance of this builder with default settings.

pub fn thread_count(&mut self, value: u16) -> &mut Self[src]

Sets the number of threads used to handle file system operations.

pub fn flags(&mut self, value: MountFlags) -> &mut Self[src]

Sets flags that controls behavior of the volume.

pub fn mount_point(&mut self, value: &'a impl AsRef<U16CStr>) -> &mut Self[src]

Sets mount point path.

pub fn unc_name(&mut self, value: &'a impl AsRef<U16CStr>) -> &mut Self[src]

Sets UNC name of the network drive.

pub fn timeout(&mut self, value: Duration) -> &mut Self[src]

Sets the time that Dokan will wait for an operation to complete.

If an operation times out, the user mode implementation is considered to be unable to handle file system operations properly, and the driver will therefore unmount the volume in order to keep the system stable.

This timeout can be temporarily extended for an operation with OperationInfo::reset_timeout.

pub fn allocation_unit_size(&mut self, value: u32) -> &mut Self[src]

Sets allocation unit size of the volume.

This value will affect file sizes.

pub fn sector_size(&mut self, value: u32) -> &mut Self[src]

Sets sector size of the volume.

This value will affect file sizes.

pub fn mount<'b, 'c: 'b, T: FileSystemHandler<'b, 'c> + 'c>(
    &mut self,
    handler: &'c T
) -> Result<(), MountError>
[src]

Mounts the volume and blocks the current thread until the volume gets unmounted.

Trait Implementations

impl<'a> Debug for Drive<'a>[src]

Auto Trait Implementations

impl<'a> RefUnwindSafe for Drive<'a>

impl<'a> !Send for Drive<'a>

impl<'a> !Sync for Drive<'a>

impl<'a> Unpin for Drive<'a>

impl<'a> UnwindSafe for Drive<'a>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.