-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Commonize CustomObject handling for JS/iOS (#315)
Removes separate CustomObject implementations from JS and iOS sourcesets and creates a common one in `nonJvm` sourceset.
- Loading branch information
1 parent
effb8a9
commit 4e27a06
Showing
10 changed files
with
12 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 0 additions & 4 deletions
4
pubnub-kotlin/pubnub-kotlin-api/src/jsMain/kotlin/com/pubnub/kmp/abstractions.js.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,5 @@ | ||
package com.pubnub.kmp | ||
|
||
actual typealias CustomObject = CustomObjectImpl | ||
|
||
class CustomObjectImpl(map: Map<String, Any?> = emptyMap()) : Map<String, Any?> by map | ||
|
||
actual abstract class Uploadable(val fileInput: Any) | ||
|
||
class UploadableImpl(fileInput: Any) : Uploadable(fileInput) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 3 additions & 0 deletions
3
pubnub-kotlin/pubnub-kotlin-api/src/nonJvm/kotlin/com/pubnub/kmp/abstractions.nonJvm.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
package com.pubnub.kmp | ||
|
||
actual class CustomObject(val value: Map<String, Any?> = emptyMap()) : Map<String, Any?> by value |
5 changes: 5 additions & 0 deletions
5
pubnub-kotlin/pubnub-kotlin-api/src/nonJvm/kotlin/com/pubnub/kmp/factories.nonJvm.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
package com.pubnub.kmp | ||
|
||
actual fun createCustomObject(map: Map<String, Any?>): CustomObject { | ||
return CustomObject(map) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters