24 lines
864 B
Kotlin
24 lines
864 B
Kotlin
package pl.edu.amu.wmi.socialaggregator.socialplatforms
|
|
|
|
import android.content.Context
|
|
import android.content.Intent
|
|
import android.graphics.Bitmap
|
|
import io.reactivex.Single
|
|
import io.reactivex.subjects.PublishSubject
|
|
import pl.edu.amu.wmi.socialaggregator.viewholders.SocialWithButtonRecycler
|
|
|
|
interface SocialPlatform {
|
|
|
|
fun getName(): String
|
|
fun login(context: Context)
|
|
fun logout(context: Context)
|
|
fun isLoggedIn(context: Context): Boolean
|
|
fun addPost(publishSubject: PublishSubject<Any>,
|
|
context: Context, text: String, images: List<Bitmap>,
|
|
imagePaths: List<String>)
|
|
|
|
fun getPosts(context: Context): Single<List<Post>>
|
|
fun getLogo(): Int
|
|
fun handleButtonView(context: Context): (SocialWithButtonRecycler.ViewHolder) -> Unit = {}
|
|
fun onActivityResult(requestCode: Int, resultCode: Int, data: Intent?) {}
|
|
} |