These code snippets will replace the existing snippets on the documentation pages
- https://getstream.io/chat/docs/event_listening/?language=kotlin
- https://getstream.io/chat/docs/event_listening/?language=java
Specific events
import android.text.SpannableString | |
import android.text.Spanned | |
import android.text.method.LinkMovementMethod | |
import android.text.style.ClickableSpan | |
import android.view.View | |
import android.widget.TextView | |
/* Adds a [clickHandler] to the text starting at index [start] and ending at index [end] */ | |
fun TextView.onClickSpan(start: Int, end: Int, clickHandler: () -> Unit) { | |
movementMethod = LinkMovementMethod.getInstance() |
import android.support.annotation.NonNull; | |
import com.example.app.BuildConfig; | |
import okhttp3.Credentials; | |
import okhttp3.Interceptor; | |
import okhttp3.Request; | |
import okhttp3.Response; | |
import java.io.IOException; | |
public class BasicAuthInterceptor implements Interceptor { |
package co.zsmb.example | |
import kotlinx.coroutines.CompletableDeferred | |
import kotlinx.coroutines.Deferred | |
import retrofit2.Call | |
import retrofit2.CallAdapter | |
import retrofit2.Callback | |
import retrofit2.HttpException | |
import retrofit2.Response | |
import retrofit2.Retrofit |
These code snippets will replace the existing snippets on the documentation pages
Specific events
apply plugin: 'maven-publish' | |
apply plugin: 'signing' | |
task androidSourcesJar(type: Jar) { | |
archiveClassifier.set('sources') | |
if (project.plugins.findPlugin("com.android.library")) { | |
from android.sourceSets.main.java.srcDirs | |
from android.sourceSets.main.kotlin.srcDirs | |
} else { | |
from sourceSets.main.java.srcDirs |