You've already forked flix
Expose TmdbId
This commit is contained in:
Generated
+1
-1
@@ -238,7 +238,7 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "flix-tmdb"
|
name = "flix-tmdb"
|
||||||
version = "0.0.1"
|
version = "0.0.2"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"chrono",
|
"chrono",
|
||||||
"reqwest",
|
"reqwest",
|
||||||
|
|||||||
+1
-1
@@ -35,7 +35,7 @@ strip = "debuginfo"
|
|||||||
|
|
||||||
[workspace.dependencies]
|
[workspace.dependencies]
|
||||||
flix = { path = "crates/flix", version = "=0.0.1", default-features = false }
|
flix = { path = "crates/flix", version = "=0.0.1", default-features = false }
|
||||||
flix-tmdb = { path = "crates/tmdb", version = "=0.0.1", default-features = false }
|
flix-tmdb = { path = "crates/tmdb", version = "=0.0.2", default-features = false }
|
||||||
|
|
||||||
anyhow = { version = "^1", default-features = false }
|
anyhow = { version = "^1", default-features = false }
|
||||||
chrono = { version = "^0.4", default-features = false }
|
chrono = { version = "^0.4", default-features = false }
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
[package]
|
[package]
|
||||||
name = "flix-tmdb"
|
name = "flix-tmdb"
|
||||||
version = "0.0.1"
|
version = "0.0.2"
|
||||||
|
|
||||||
categories = []
|
categories = []
|
||||||
description = "Clients and models for fetching data from TMDB"
|
description = "Clients and models for fetching data from TMDB"
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
# flix
|
# flix
|
||||||
|
|
||||||
[](https://crates.io/crates/flix)
|
[](https://crates.io/crates/flix-tmdb)
|
||||||
|
|
||||||
A library providing clients and models for fetching data from TMDB
|
A library providing clients and models for fetching data from TMDB
|
||||||
|
|||||||
@@ -18,8 +18,11 @@ pub enum Collection {}
|
|||||||
pub enum Movie {}
|
pub enum Movie {}
|
||||||
pub enum Show {}
|
pub enum Show {}
|
||||||
|
|
||||||
type Inner = i32;
|
/// The inner type of TmdbId
|
||||||
|
pub type Inner = i32;
|
||||||
|
|
||||||
|
/// Wraps an ID from TMDB, the generic parameter is to enforce that
|
||||||
|
/// IDs for different types of media are not interchangeable
|
||||||
#[derive(serde::Serialize, serde::Deserialize)]
|
#[derive(serde::Serialize, serde::Deserialize)]
|
||||||
#[serde(transparent)]
|
#[serde(transparent)]
|
||||||
#[repr(transparent)]
|
#[repr(transparent)]
|
||||||
@@ -30,7 +33,8 @@ pub struct TmdbId<T> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
impl<T> TmdbId<T> {
|
impl<T> TmdbId<T> {
|
||||||
pub fn inner(&self) -> Inner {
|
/// Extract the inner value
|
||||||
|
pub fn inner(self) -> Inner {
|
||||||
self.inner
|
self.inner
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,3 +15,4 @@ pub use serde::*;
|
|||||||
pub use show::*;
|
pub use show::*;
|
||||||
|
|
||||||
pub use id::{CollectionId, MovieGenreId, MovieId, ShowGenreId, ShowId};
|
pub use id::{CollectionId, MovieGenreId, MovieId, ShowGenreId, ShowId};
|
||||||
|
pub use id::{Inner as TmdbIdInner, TmdbId};
|
||||||
|
|||||||
Reference in New Issue
Block a user