From 3827aeb9b4315a2074fa1de3824c55b32bbc2d05 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kuba=20Szczodrzy=C5=84ski?= Date: Fri, 20 Sep 2019 19:12:47 +0200 Subject: [PATCH] APIv2: Update endpoints --- .../api/v2/interfaces/ILoginMethod.kt | 18 +++++++++++++++++- .../api/v2/librus/data/LibrusApiGrades.kt | 17 +++++++++++------ .../api/v2/librus/data/LibrusSynergiaGrades.kt | 17 ++++++++++++++++- 3 files changed, 44 insertions(+), 8 deletions(-) diff --git a/app/src/main/java/pl/szczodrzynski/edziennik/api/v2/interfaces/ILoginMethod.kt b/app/src/main/java/pl/szczodrzynski/edziennik/api/v2/interfaces/ILoginMethod.kt index 440a5693..c1834b29 100644 --- a/app/src/main/java/pl/szczodrzynski/edziennik/api/v2/interfaces/ILoginMethod.kt +++ b/app/src/main/java/pl/szczodrzynski/edziennik/api/v2/interfaces/ILoginMethod.kt @@ -1,4 +1,20 @@ +/* + * Copyright (c) Kuba SzczodrzyƄski 2019-9-20. + */ + package pl.szczodrzynski.edziennik.api.v2.interfaces -interface ILoginMethod { +import pl.szczodrzynski.edziennik.App +import pl.szczodrzynski.edziennik.api.interfaces.ProgressCallback +import pl.szczodrzynski.edziennik.datamodels.LoginStore +import pl.szczodrzynski.edziennik.datamodels.Profile + +abstract class ILoginMethod( + val app: App, + val profile: Profile?, + val loginStore: LoginStore, + val callback: ProgressCallback, + val onSuccess: () -> Unit +) { + } \ No newline at end of file diff --git a/app/src/main/java/pl/szczodrzynski/edziennik/api/v2/librus/data/LibrusApiGrades.kt b/app/src/main/java/pl/szczodrzynski/edziennik/api/v2/librus/data/LibrusApiGrades.kt index 261a4476..eae53a75 100644 --- a/app/src/main/java/pl/szczodrzynski/edziennik/api/v2/librus/data/LibrusApiGrades.kt +++ b/app/src/main/java/pl/szczodrzynski/edziennik/api/v2/librus/data/LibrusApiGrades.kt @@ -6,12 +6,17 @@ import pl.szczodrzynski.edziennik.api.v2.models.DataStore import pl.szczodrzynski.edziennik.datamodels.LoginStore import pl.szczodrzynski.edziennik.datamodels.Profile -class LibrusGrades(val app: App, - val profile: Profile, - val loginStore: LoginStore, - val dataStore: DataStore, - val callback: ProgressCallback, - val onSuccess: () -> Unit) { +class LibrusApiGrades(val app: App, + val profile: Profile, + val loginStore: LoginStore, + val dataStore: DataStore, + val callback: ProgressCallback, + val onSuccess: () -> Unit) : EndpointInterface { + override fun sync() { + + } + + init { } diff --git a/app/src/main/java/pl/szczodrzynski/edziennik/api/v2/librus/data/LibrusSynergiaGrades.kt b/app/src/main/java/pl/szczodrzynski/edziennik/api/v2/librus/data/LibrusSynergiaGrades.kt index a1693141..ecf10682 100644 --- a/app/src/main/java/pl/szczodrzynski/edziennik/api/v2/librus/data/LibrusSynergiaGrades.kt +++ b/app/src/main/java/pl/szczodrzynski/edziennik/api/v2/librus/data/LibrusSynergiaGrades.kt @@ -1,4 +1,19 @@ package pl.szczodrzynski.edziennik.api.v2.librus.data -class LibrusSynergiaGrades { +import pl.szczodrzynski.edziennik.App +import pl.szczodrzynski.edziennik.api.interfaces.ProgressCallback +import pl.szczodrzynski.edziennik.api.v2.models.DataStore +import pl.szczodrzynski.edziennik.datamodels.LoginStore +import pl.szczodrzynski.edziennik.datamodels.Profile + +class LibrusSynergiaGrades(val app: App, + val profile: Profile, + val loginStore: LoginStore, + val dataStore: DataStore, + val callback: ProgressCallback, + val onSuccess: () -> Unit) { + + init { + + } } \ No newline at end of file