Skip to content

Commit

Permalink
Add call IlService.getPageForShow() (#29)
Browse files Browse the repository at this point in the history
- Add `IlService.getPageForShow()`:
`@GET("2.0/{bu}/page/{product}/showPage/{showUrn}")`
- Add `RepresentationType`: `TrendingShowsByTopic` and
`AvailableEpisodes`.
- Fix `ListResult` to be overridable again.
- Pull up version to `0.7.6`

---------

Co-authored-by: Joaquim Stähli <[email protected]>
  • Loading branch information
Loic-Dumas and StaehliJ authored Nov 29, 2023
1 parent aca31b8 commit 89bc7e9
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 2 deletions.
2 changes: 1 addition & 1 deletion buildSrc/src/main/kotlin/Config.kt
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ object Config {

const val major = 0
const val minor = 7
const val patch = 2
const val patch = 6
const val versionName = "$major.$minor.$patch"

const val maven_group = "ch.srg.data.provider"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import kotlinx.serialization.Serializable
* License information is available from the LICENSE file.
*/
abstract class ListResult<T> : Iterable<T> {
internal abstract val data: List<T>?
protected abstract val data: List<T>?
abstract val next: String?

val list: List<T>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,6 @@ object RepresentationType {
const val ExpiringSoon = "ExpiringSoon"
const val MyProgram = "MyProgram"
const val ShowAccess = "ShowAccess"
const val TrendingShowsByTopic = "TrendingShowsByTopic"
const val AvailableEpisodes = "AvailableEpisodes"
}
Original file line number Diff line number Diff line change
Expand Up @@ -440,6 +440,14 @@ interface IlService {
@Query("isPublished") isPublished: Boolean? = null
): Page

@GET("2.0/{bu}/page/{product}/showPage/{showUrn}")
suspend fun getPageForShow(
@Path("bu") bu: Bu,
@Path("product") product: String,
@Path("showUrn") showUrn: String,
@Query("isPublished") isPublished: Boolean? = null
): Page

@GET("2.0/{bu}/section/{sectionId}")
suspend fun getSection(
@Path("bu") bu: Bu,
Expand Down

0 comments on commit 89bc7e9

Please sign in to comment.