Skip to content

Commit

Permalink
Merge branch 'feature/field-value-encoding' into track-master-2.1
Browse files Browse the repository at this point in the history
  • Loading branch information
Daeda88 committed Sep 3, 2024
2 parents c060bd5 + ebe3198 commit cd188b6
Show file tree
Hide file tree
Showing 8 changed files with 24 additions and 2 deletions.
1 change: 1 addition & 0 deletions firebase-storage/api/android/firebase-storage.api
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ public final class dev/gitlive/firebase/storage/FirebaseStorage {
public final fun getMaxOperationRetryTime-UwyO8pc ()J
public final fun getMaxUploadRetryTime-UwyO8pc ()J
public final fun getReference ()Ldev/gitlive/firebase/storage/StorageReference;
public final fun getReferenceFromUrl (Ljava/lang/String;)Ldev/gitlive/firebase/storage/StorageReference;
public final fun reference (Ljava/lang/String;)Ldev/gitlive/firebase/storage/StorageReference;
public final fun setMaxOperationRetryTime-LRDsOJo (J)V
public final fun setMaxUploadRetryTime-LRDsOJo (J)V
Expand Down
1 change: 1 addition & 0 deletions firebase-storage/api/jvm/firebase-storage.api
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ public final class dev/gitlive/firebase/storage/FirebaseStorage {
public final fun getMaxOperationRetryTime-UwyO8pc ()J
public final fun getMaxUploadRetryTime-UwyO8pc ()J
public final fun getReference ()Ldev/gitlive/firebase/storage/StorageReference;
public final fun getReferenceFromUrl (Ljava/lang/String;)Ldev/gitlive/firebase/storage/StorageReference;
public final fun reference (Ljava/lang/String;)Ldev/gitlive/firebase/storage/StorageReference;
public final fun setMaxOperationRetryTime-LRDsOJo (J)V
public final fun setMaxUploadRetryTime-LRDsOJo (J)V
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,8 @@ public actual class FirebaseStorage(internal val android: com.google.firebase.st
public actual val reference: StorageReference get() = StorageReference(android.reference)

public actual fun reference(location: String): StorageReference = StorageReference(android.getReference(location))

public actual fun getReferenceFromUrl(fullUrl: String): StorageReference = StorageReference(android.getReferenceFromUrl(fullUrl))
}

public val StorageReference.android: com.google.firebase.storage.StorageReference get() = android
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,16 @@ public expect class FirebaseStorage {
* @return An instance of [StorageReference] at the given child path.
*/
public fun reference(location: String): StorageReference

/**
* Creates a [StorageReference] given a gs:// or https:// URL pointing to a Firebase Storage location.
*
* @param fullUrl A gs:// or http[s]:// URL used to initialize the reference. For example, you can pass
* in a download URL retrieved from getDownloadUrl or the uri retrieved from toString An error is
* thrown if fullUrl is not associated with the FirebaseApp used to initialize this FirebaseStorage.
* @return An instance of [StorageReference] at the given url.
*/
public fun getReferenceFromUrl(fullUrl: String): StorageReference
}

@Deprecated("Deprecated to use Kotlin Duration", replaceWith = ReplaceWith("maxOperationRetryTime"))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,8 @@ public actual class FirebaseStorage(internal val ios: FIRStorage) {
public actual val reference: StorageReference get() = StorageReference(ios.reference())

public actual fun reference(location: String): StorageReference = StorageReference(ios.referenceWithPath(location))

public actual fun getReferenceFromUrl(fullUrl: String): StorageReference = StorageReference(ios.referenceForURL(fullUrl))
}

public val StorageReference.ios: FIRStorageReference get() = ios
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,8 @@ public actual class FirebaseStorage(internal val js: dev.gitlive.firebase.storag
public actual val reference: StorageReference get() = StorageReference(ref(js))

public actual fun reference(location: String): StorageReference = rethrow { StorageReference(ref(js, location)) }

public actual fun getReferenceFromUrl(fullUrl: String): StorageReference = rethrow { StorageReference(ref(js, fullUrl)) }
}

public val StorageReference.js get() = js
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,10 @@ public actual class FirebaseStorage {
public actual fun reference(location: String): StorageReference {
TODO("Not yet implemented")
}

public actual fun getReferenceFromUrl(fullUrl: String): StorageReference {
TODO("Not yet implemented")
}
}

public actual class StorageReference {
Expand Down
4 changes: 2 additions & 2 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ androidx-test-junit = "1.2.1"
androidx-test-runner = "1.6.2"
ben-manes-versions = "0.51.0"
firebase-bom = "33.2.0"
gitlive-firebase-java-sdk = "0.4.5"
gitlive-firebase-java-sdk = "0.4.6"
gson = "2.11.0"
junit = "4.13.2"
kotlin = "2.0.20"
Expand All @@ -20,7 +20,7 @@ firebase-cocoapods = "11.1.0"
ios-deploymentTarget = "13.0"
test-logger-plugin = "4.0.0"
dokka = "1.9.20"
desugar-libs = "2.1.0"
desugar-libs = "2.1.1"

[libraries]
android-gradle-plugin = { module = "com.android.tools.build:gradle", version.ref = "agp" }
Expand Down

0 comments on commit cd188b6

Please sign in to comment.