Skip to content

Commit

Permalink
Added @ObjCName annotation and helper constructor (iOS)
Browse files Browse the repository at this point in the history
  • Loading branch information
jguz-pubnub committed Sep 19, 2024
1 parent e6ce060 commit cdbbff9
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,12 @@ class PubNubImpl(private val pubNubObjC: KMPPubNub) : PubNub {
)
)

companion object {
fun create(kmpPubNub: Any): PubNubImpl {
return PubNubImpl(kmpPubNub as KMPPubNub)
}
}

override val configuration: PNConfiguration = createPNConfiguration(
UserId(pubNubObjC.configObjC().userId()),
"", // todo
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,10 @@ import com.pubnub.api.v2.subscriptions.SubscriptionOptions
import com.pubnub.api.v2.subscriptions.SubscriptionSet
import com.pubnub.kmp.CustomObject
import com.pubnub.kmp.Uploadable
import kotlin.experimental.ExperimentalObjCName

@OptIn(ExperimentalObjCName::class)
@ObjCName("PubNubInterface")
actual interface PubNub {
actual val configuration: PNConfiguration

Expand Down
2 changes: 1 addition & 1 deletion swift
Submodule swift updated 27 files
+21 −0 Documentation/PubNub_8_0_Migration_Guide.md
+12 −12 PubNub.xcodeproj/project.pbxproj
+1 −1 README.md
+27 −1 Sources/PubNub/APIs/Objects+PubNub.swift
+2 −2 Sources/PubNub/EventEngine/Subscribe/Effects/EmitMessagesEffect.swift
+2 −2 Sources/PubNub/EventEngine/Subscribe/Effects/EmitStatusEffect.swift
+1 −1 Sources/PubNub/EventEngine/Subscribe/Effects/SubscribeEffects.swift
+0 −6 Sources/PubNub/Events/New/Subscription.swift
+0 −8 Sources/PubNub/Events/New/SubscriptionListenersContainer.swift
+1 −7 Sources/PubNub/Events/New/SubscriptionSet.swift
+1 −1 Sources/PubNub/Extensions/NSLocking+PubNub.swift
+1 −1 Sources/PubNub/Helpers/Atomic.swift
+12 −0 Sources/PubNub/Helpers/WeakBox.swift
+0 −0 Sources/PubNub/KMP/KMPPubNub+ChannelGroups.swift
+51 −51 Sources/PubNub/KMP/KMPPubNub+Listeners.swift
+0 −0 Sources/PubNub/KMP/KMPPubNub+MessageActions.swift
+0 −0 Sources/PubNub/KMP/KMPPubNub+Presence.swift
+4 −0 Sources/PubNub/KMP/Wrappers/KMPEventListener.swift
+4 −0 Sources/PubNub/KMP/Wrappers/KMPStatusListener.swift
+6 −2 Sources/PubNub/KMP/Wrappers/KMPSubscription.swift
+19 −32 Sources/PubNub/Networking/Request/Operators/AutomaticRetry.swift
+2 −0 Sources/PubNub/Networking/Routers/ObjectsMembershipsRouter.swift
+1 −11 Sources/PubNub/PubNub.swift
+1 −1 Sources/PubNub/PubNubConfiguration.swift
+2 −2 Sources/PubNub/Subscription/ConnectionStatus.swift
+2 −10 Sources/PubNub/Subscription/SubscriptionSession.swift
+25 −87 Tests/PubNubTests/Networking/Operators/AutomaticRetryTests.swift

0 comments on commit cdbbff9

Please sign in to comment.