Struct dav_server::DavConfig
source · [−]pub struct DavConfig { /* private fields */ }
Expand description
Configuration of the handler.
Implementations
sourceimpl DavConfig
impl DavConfig
sourcepub fn build_handler(self) -> DavHandler
pub fn build_handler(self) -> DavHandler
Use the configuration that was built to generate a DavConfig.
sourcepub fn strip_prefix(self, prefix: impl Into<String>) -> Self
pub fn strip_prefix(self, prefix: impl Into<String>) -> Self
Prefix to be stripped off before translating the rest of the request path to a filesystem path.
sourcepub fn filesystem(self, fs: Box<dyn DavFileSystem>) -> Self
pub fn filesystem(self, fs: Box<dyn DavFileSystem>) -> Self
Set the filesystem to use.
sourcepub fn locksystem(self, ls: Box<dyn DavLockSystem>) -> Self
pub fn locksystem(self, ls: Box<dyn DavLockSystem>) -> Self
Set the locksystem to use.
sourcepub fn methods(self, allow: DavMethodSet) -> Self
pub fn methods(self, allow: DavMethodSet) -> Self
Which methods to allow (default is all methods).
sourcepub fn principal(self, principal: impl Into<String>) -> Self
pub fn principal(self, principal: impl Into<String>) -> Self
Set the name of the “webdav principal”. This will be the owner of any created locks.
sourcepub fn hide_symlinks(self, hide: bool) -> Self
pub fn hide_symlinks(self, hide: bool) -> Self
Hide symbolic links (default is true)
sourcepub fn autoindex(self, autoindex: bool) -> Self
pub fn autoindex(self, autoindex: bool) -> Self
Does a GET on a directory produce a directory index.
sourcepub fn indexfile(self, indexfile: impl Into<String>) -> Self
pub fn indexfile(self, indexfile: impl Into<String>) -> Self
Indexfile to show (index.html, usually).
sourcepub fn read_buf_size(self, size: usize) -> Self
pub fn read_buf_size(self, size: usize) -> Self
Read buffer size in bytes
Trait Implementations
Auto Trait Implementations
impl !RefUnwindSafe for DavConfig
impl Send for DavConfig
impl Sync for DavConfig
impl Unpin for DavConfig
impl !UnwindSafe for DavConfig
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
fn vzip(self) -> V
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more