Trait dav_server::fs::DavMetaData
source · [−]pub trait DavMetaData: Debug + BoxCloneMd + Send + Sync {
fn len(&self) -> u64;
fn modified(&self) -> FsResult<SystemTime>;
fn is_dir(&self) -> bool;
fn etag(&self) -> Option<String> { ... }
fn is_file(&self) -> bool { ... }
fn is_symlink(&self) -> bool { ... }
fn accessed(&self) -> FsResult<SystemTime> { ... }
fn created(&self) -> FsResult<SystemTime> { ... }
fn status_changed(&self) -> FsResult<SystemTime> { ... }
fn executable(&self) -> FsResult<bool> { ... }
fn is_empty(&self) -> bool { ... }
}Expand description
File metadata. Basically type, length, and some timestamps.
Required Methods
sourcefn modified(&self) -> FsResult<SystemTime>
fn modified(&self) -> FsResult<SystemTime>
Modified timestamp.
Provided Methods
sourcefn etag(&self) -> Option<String>
fn etag(&self) -> Option<String>
Simplistic implementation of etag()
Returns a simple etag that basically is \<length\>-\<timestamp_in_ms\>
with the numbers in hex. Enough for most implementations.
sourcefn is_symlink(&self) -> bool
fn is_symlink(&self) -> bool
Is this a symbolic link. Default: false.
sourcefn accessed(&self) -> FsResult<SystemTime>
fn accessed(&self) -> FsResult<SystemTime>
Last access time. Default: FsError::NotImplemented.
sourcefn created(&self) -> FsResult<SystemTime>
fn created(&self) -> FsResult<SystemTime>
Creation time. Default: FsError::NotImplemented.
sourcefn status_changed(&self) -> FsResult<SystemTime>
fn status_changed(&self) -> FsResult<SystemTime>
Inode change time (ctime). Default: FsError::NotImplemented.
sourcefn executable(&self) -> FsResult<bool>
fn executable(&self) -> FsResult<bool>
Is file executable (unix: has “x” mode bit). Default: FsError::NotImplemented.
fn is_empty(&self) -> bool
Trait Implementations
sourceimpl Clone for Box<dyn DavMetaData>
impl Clone for Box<dyn DavMetaData>
sourcefn clone(&self) -> Box<dyn DavMetaData>
fn clone(&self) -> Box<dyn DavMetaData>
Returns a copy of the value. Read more
1.0.0 · sourceconst fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read more