Small update of the Matrix documentation

This commit is contained in:
Benoit Marty 2022-04-21 16:05:47 +02:00 committed by Benoit Marty
parent a52182490d
commit 96b2254ac1

View File

@ -43,7 +43,8 @@ import javax.inject.Inject
/**
* This is the main entry point to the matrix sdk.
* To get the singleton instance, use getInstance static method.
* <br/>
* See [Companion.createInstance] to create an instance. The app should create and manage the instance itself.
*/
class Matrix private constructor(context: Context, matrixConfiguration: MatrixConfiguration) {
@ -74,9 +75,7 @@ class Matrix private constructor(context: Context, matrixConfiguration: MatrixCo
fun getUserAgent() = userAgentHolder.userAgent
fun authenticationService(): AuthenticationService {
return authenticationService
}
fun authenticationService() = authenticationService
fun rawService() = rawService
@ -84,9 +83,7 @@ class Matrix private constructor(context: Context, matrixConfiguration: MatrixCo
fun homeServerHistoryService() = homeServerHistoryService
fun legacySessionImporter(): LegacySessionImporter {
return legacySessionImporter
}
fun legacySessionImporter() = legacySessionImporter
fun workerFactory(): WorkerFactory = matrixWorkerFactory
@ -143,6 +140,9 @@ class Matrix private constructor(context: Context, matrixConfiguration: MatrixCo
return instance
}
/**
* @return a String with details about the Matrix SDK version
*/
fun getSdkVersion(): String {
return BuildConfig.SDK_VERSION + " (" + BuildConfig.GIT_SDK_REVISION + ")"
}