diff options
author | Clyhtsuriva <aimeric@adjutor.xyz> | 2021-02-22 20:03:25 +0100 |
---|---|---|
committer | Clyhtsuriva <aimeric@adjutor.xyz> | 2021-02-22 20:03:25 +0100 |
commit | 4012256bf91ccf02eb1871229f755beb26dad3de (patch) | |
tree | ae8521428bdde7750294d25c8e49a93df9e95f26 /app/src/main/java/xyz/adjutor/aniki/manga | |
parent | 893c9110c99cff286011e3d35acb39ba65a97476 (diff) | |
parent | 494455de615340599cf2cdba0f3f199a47bf5a66 (diff) |
Merge branch 'feature/elements_detail' into developrelease/2.0
Diffstat (limited to 'app/src/main/java/xyz/adjutor/aniki/manga')
-rw-r--r-- | app/src/main/java/xyz/adjutor/aniki/manga/MangaApi.kt | 12 | ||||
-rw-r--r-- | app/src/main/java/xyz/adjutor/aniki/manga/RestMangaResponse.kt | 16 |
2 files changed, 28 insertions, 0 deletions
diff --git a/app/src/main/java/xyz/adjutor/aniki/manga/MangaApi.kt b/app/src/main/java/xyz/adjutor/aniki/manga/MangaApi.kt new file mode 100644 index 0000000..419d510 --- /dev/null +++ b/app/src/main/java/xyz/adjutor/aniki/manga/MangaApi.kt @@ -0,0 +1,12 @@ +package xyz.adjutor.aniki.manga + +import retrofit2.Call +import retrofit2.http.GET +import retrofit2.http.Path + +interface MangaApi { + + @GET("v3/manga/{id}") + fun getMangaData(@Path("id") id: String): Call<RestMangaResponse> + +}
\ No newline at end of file diff --git a/app/src/main/java/xyz/adjutor/aniki/manga/RestMangaResponse.kt b/app/src/main/java/xyz/adjutor/aniki/manga/RestMangaResponse.kt new file mode 100644 index 0000000..00b0dce --- /dev/null +++ b/app/src/main/java/xyz/adjutor/aniki/manga/RestMangaResponse.kt @@ -0,0 +1,16 @@ +package xyz.adjutor.aniki.manga + +import com.google.gson.annotations.SerializedName + +class RestMangaResponse{ //only kept the infos I didn't have and that were interesting to me. + + @SerializedName("mal_id") + var mal_id: Int? = null + @SerializedName("chapters") + var chapters: Int? = null + @SerializedName("synopsis") + var synopsis: String? = null + @SerializedName("background") + var background: String? = null //a bit of background story about the manga + +} |