pub struct SearchHit {
pub item: Item,
pub origin: Option<LibraryServer>,
pub also_on: Vec<TitleCopy>,
pub play_from: MediaId,
}Expand description
Experimental (federation): a search’s item for a client that
names the feature. A title on several servers (the same TMDB, IMDb,
TVDB, MusicBrainz or Plex id; an episode by its show’s, season and
number) is one hit: this server’s copy when it has one, else the copy
the user plays from or last played, else the first online.
Fields§
§item: Item§origin: Option<LibraryServer>The paired server item is from; None for this server’s own.
also_on: Vec<TitleCopy>The title’s copies on other servers (“also on Bob’s Media”), in the order a Play from list shows them; empty for a title on one server.
play_from: MediaIdThe copy that plays: the one on the server the user chose for the
title (SetPlayFrom) while it has one, else item’s own id.
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for SearchHit
impl<'de> Deserialize<'de> for SearchHit
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for SearchHit
Source§impl From<SearchHit> for SearchResult
impl From<SearchHit> for SearchResult
impl StructuralPartialEq for SearchHit
Auto Trait Implementations§
impl Forget for SearchHit
impl Freeze for SearchHit
impl Move for SearchHit
impl RefUnwindSafe for SearchHit
impl Send for SearchHit
impl Sync for SearchHit
impl Unpin for SearchHit
impl UnsafeUnpin for SearchHit
impl UnwindSafe for SearchHit
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