pub enum Scanner {
Collection {
parent: Option<CollectionId>,
id: CollectionId,
poster_file_name: Option<String>,
},
Movie {
parent: Option<CollectionId>,
id: MovieId,
media_file_name: String,
poster_file_name: Option<String>,
},
Show {
parent: Option<CollectionId>,
id: ShowId,
poster_file_name: Option<String>,
},
Season {
show: ShowId,
season: SeasonNumber,
poster_file_name: Option<String>,
},
Episode {
show: ShowId,
season: SeasonNumber,
episode: EpisodeNumbers,
media_file_name: String,
poster_file_name: Option<String>,
},
}Expand description
The scanner for collections
Variants§
Collection
A scanned collection
Fields
§
parent: Option<CollectionId>The ID of the parent collection (if any)
§
id: CollectionIdThe ID of the collection
Movie
A scanned movie
Fields
§
parent: Option<CollectionId>The ID of the parent collection (if any)
Show
A scanned show
Fields
§
parent: Option<CollectionId>The ID of the parent collection (if any)
Season
A scanned episode
Fields
§
season: SeasonNumberThe season this episode belongs to
Episode
A scanned episode
Implementations§
Source§impl Scanner
impl Scanner
Sourcepub fn scan_detect_folder(
path: &Path,
parent: Option<CollectionId>,
) -> impl Stream<Item = Item>
pub fn scan_detect_folder( path: &Path, parent: Option<CollectionId>, ) -> impl Stream<Item = Item>
Detect the type of a folder and call the correct scanner. Use this only for detecting possibly ambiguous media:
- Collections
- Movies
- Shows
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Scanner
impl RefUnwindSafe for Scanner
impl Send for Scanner
impl Sync for Scanner
impl Unpin for Scanner
impl UnwindSafe for Scanner
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