pub struct Organizer { /* private fields */ }Expand description
Organizer for managing audiobook folder structure
Implementations§
Source§impl Organizer
impl Organizer
Sourcepub fn with_dry_run(root: PathBuf, config: &Config, dry_run: bool) -> Self
pub fn with_dry_run(root: PathBuf, config: &Config, dry_run: bool) -> Self
Create organizer with dry run mode
Sourcepub fn organize_book(&self, book: &BookFolder) -> Result<OrganizeResult>
pub fn organize_book(&self, book: &BookFolder) -> Result<OrganizeResult>
Organize a single book folder
Sourcepub fn organize_batch(&self, books: Vec<BookFolder>) -> Vec<OrganizeResult>
pub fn organize_batch(&self, books: Vec<BookFolder>) -> Vec<OrganizeResult>
Organize multiple books
Sourcepub fn get_target_folder(&self, case: BookCase) -> Option<PathBuf>
pub fn get_target_folder(&self, case: BookCase) -> Option<PathBuf>
Get target folder path for a book case
Auto Trait Implementations§
impl Freeze for Organizer
impl RefUnwindSafe for Organizer
impl Send for Organizer
impl Sync for Organizer
impl Unpin for Organizer
impl UnwindSafe for Organizer
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more