Skip to content

Commit

Permalink
SqlNormalizedCacheFactory make sqldriver public to support Sqlcipher …
Browse files Browse the repository at this point in the history
…data encryption. (#5973)

* SqlNormalizedCacheFactory make sqldriver public to support Sqlcipher data encryption.

* Add SqlDelight to api dependency and update API dump

---------

Co-authored-by: Yuvaraj Yadav <yuvaraj.yadav@daimlertruck.com>
Co-authored-by: BoD <BoD@JRAF.org>
  • Loading branch information
3 people authored Jun 17, 2024
1 parent 2ace10e commit 8d609cd
Show file tree
Hide file tree
Showing 8 changed files with 9 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ public final class com/apollographql/apollo3/cache/normalized/sql/SqlNormalizedC
public fun <init> (Landroid/content/Context;Ljava/lang/String;Landroidx/sqlite/db/SupportSQLiteOpenHelper$Factory;Lkotlin/jvm/functions/Function1;Z)V
public fun <init> (Landroid/content/Context;Ljava/lang/String;Landroidx/sqlite/db/SupportSQLiteOpenHelper$Factory;Lkotlin/jvm/functions/Function1;ZLjava/lang/Long;)V
public synthetic fun <init> (Landroid/content/Context;Ljava/lang/String;Landroidx/sqlite/db/SupportSQLiteOpenHelper$Factory;Lkotlin/jvm/functions/Function1;ZLjava/lang/Long;ILkotlin/jvm/internal/DefaultConstructorMarker;)V
public fun <init> (Lapp/cash/sqldelight/db/SqlDriver;)V
public fun <init> (Ljava/lang/String;)V
public synthetic fun <init> (Ljava/lang/String;ILkotlin/jvm/internal/DefaultConstructorMarker;)V
public fun create ()Lcom/apollographql/apollo3/cache/normalized/api/NormalizedCache;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ final class com.apollographql.apollo3.cache.normalized.sql/SqlNormalizedCache :
}
final class com.apollographql.apollo3.cache.normalized.sql/SqlNormalizedCacheFactory : com.apollographql.apollo3.cache.normalized.api/NormalizedCacheFactory { // com.apollographql.apollo3.cache.normalized.sql/SqlNormalizedCacheFactory|null[0]
constructor <init>() // com.apollographql.apollo3.cache.normalized.sql/SqlNormalizedCacheFactory.<init>|<init>(){}[0]
constructor <init>(app.cash.sqldelight.db/SqlDriver) // com.apollographql.apollo3.cache.normalized.sql/SqlNormalizedCacheFactory.<init>|<init>(app.cash.sqldelight.db.SqlDriver){}[0]
constructor <init>(kotlin/String? = ...) // com.apollographql.apollo3.cache.normalized.sql/SqlNormalizedCacheFactory.<init>|<init>(kotlin.String?){}[0]
constructor <init>(kotlin/String?, kotlin/String?) // com.apollographql.apollo3.cache.normalized.sql/SqlNormalizedCacheFactory.<init>|<init>(kotlin.String?;kotlin.String?){}[0]
final fun create(): com.apollographql.apollo3.cache.normalized.api/NormalizedCache // com.apollographql.apollo3.cache.normalized.sql/SqlNormalizedCacheFactory.create|create(){}[0]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ public final class com/apollographql/apollo3/cache/normalized/sql/SqlNormalizedC
}

public final class com/apollographql/apollo3/cache/normalized/sql/SqlNormalizedCacheFactory : com/apollographql/apollo3/cache/normalized/api/NormalizedCacheFactory {
public fun <init> (Lapp/cash/sqldelight/db/SqlDriver;)V
public fun <init> (Ljava/lang/String;)V
public synthetic fun <init> (Ljava/lang/String;ILkotlin/jvm/internal/DefaultConstructorMarker;)V
public fun <init> (Ljava/lang/String;Ljava/lang/String;)V
Expand Down
1 change: 1 addition & 0 deletions libraries/apollo-normalized-cache-sqlite/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ kotlin {
api(project(":apollo-api"))
api(project(":apollo-normalized-cache-api"))
api(project(":apollo-normalized-cache"))
api(libs.sqldelight.runtime)
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import app.cash.sqldelight.driver.android.AndroidSqliteDriver
import app.cash.sqldelight.db.SqlDriver
import com.apollographql.apollo3.cache.normalized.api.NormalizedCache

actual class SqlNormalizedCacheFactory internal constructor(
actual class SqlNormalizedCacheFactory actual constructor(
private val driver: SqlDriver,
) : NormalizedCacheFactory() {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import com.apollographql.apollo3.cache.normalized.sql.internal.createDriver
import com.apollographql.apollo3.cache.normalized.sql.internal.createRecordDatabase
import com.apollographql.apollo3.cache.normalized.sql.internal.getSchema

actual class SqlNormalizedCacheFactory internal constructor(
actual class SqlNormalizedCacheFactory actual constructor(
private val driver: SqlDriver,
) : NormalizedCacheFactory() {

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package com.apollographql.apollo3.cache.normalized.sql

import app.cash.sqldelight.db.SqlDriver
import com.apollographql.apollo3.cache.normalized.api.NormalizedCache
import com.apollographql.apollo3.cache.normalized.api.NormalizedCacheFactory

Expand All @@ -15,6 +16,7 @@ import com.apollographql.apollo3.cache.normalized.api.NormalizedCacheFactory
*
*/
expect class SqlNormalizedCacheFactory(name: String? = "apollo.db") : NormalizedCacheFactory {
constructor(driver: SqlDriver)
override fun create(): NormalizedCache
}

Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import app.cash.sqldelight.driver.jdbc.sqlite.JdbcSqliteDriver
import com.apollographql.apollo3.cache.normalized.api.NormalizedCache
import java.util.Properties

actual class SqlNormalizedCacheFactory internal constructor(
actual class SqlNormalizedCacheFactory actual constructor(
private val driver: SqlDriver,
) : NormalizedCacheFactory() {
/**
Expand Down

0 comments on commit 8d609cd

Please sign in to comment.