[−][src]Struct gcsf::Config
Provides a few properties of the file system that can be configured. Includes sensible defaults for the absent values.
Fields
debug: Option<bool>
mount_check: Option<bool>
cache_max_seconds: Option<u64>
cache_max_items: Option<u64>
cache_statfs_seconds: Option<u64>
sync_interval: Option<u64>
mount_options: Option<Vec<String>>
config_dir: Option<PathBuf>
session_name: Option<String>
rename_identical_files: Option<bool>
skip_trash: Option<bool>
Methods
impl Config
[src]
pub fn debug(&self) -> bool
[src]
Whether to show additional logging info.
pub fn mount_check(&self) -> bool
[src]
Whether to perform a mount check before creating the file system and fail early if it fails.
pub fn cache_max_seconds(&self) -> Duration
[src]
How long to cache the contents of a file after it has been accessed.
pub fn cache_max_items(&self) -> u64
[src]
How how many files to cache.
pub fn cache_statfs_seconds(&self) -> Duration
[src]
How long to cache the size and capacity of the filesystem. These are the values reported by df
.
pub fn sync_interval(&self) -> Duration
[src]
How many seconds to wait before checking for remote changes and updating them locally.
pub fn mount_options(&self) -> Vec<String>
[src]
pub fn session_name(&self) -> &String
[src]
pub fn token_file(&self) -> PathBuf
[src]
The path to the token file which authorizes access to a Drive account.
pub fn config_dir(&self) -> &PathBuf
[src]
pub fn authorize_using_code(&self) -> bool
[src]
If set to true, Google Drive will provide a code after logging in and authorizing GCSF. This code must be copied and pasted into GCSF in order to complete the process. Useful for running GCSF on a remote (headless) server.
If set to false, Google Drive will attempt to communicate with GCSF directly. This is usually faster and more convenient.
pub fn rename_identical_files(&self) -> bool
[src]
If set to true, all files with identical name will get an increasing number attached to the suffix. The mount-time also rises dramatically with higher file counts. Not recommended.
pub fn skip_trash(&self) -> bool
[src]
If set to true, deleted files and folder will not be moved to Trash Folder, instead they get deleted permanently.
Trait Implementations
impl Default for Config
[src]
impl Clone for Config
[src]
fn clone(&self) -> Config
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl Debug for Config
[src]
impl<'de> Deserialize<'de> for Config
[src]
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
[src]
__D: Deserializer<'de>,
Auto Trait Implementations
Blanket Implementations
impl<T> From for T
[src]
impl<T, U> Into for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
impl<T, U> TryFrom for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = !
try_from
)The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T> Borrow for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
try_from
)The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> DeserializeOwned for T where
T: Deserialize<'de>,
[src]
T: Deserialize<'de>,
impl<T> Typeable for T where
T: Any,
T: Any,