File tree Expand file tree Collapse file tree 7 files changed +19
-21
lines changed
Examples/OneSignalDemo/app/src/main/java/com/onesignal/sdktest/application
core/src/main/java/com/onesignal/user Expand file tree Collapse file tree 7 files changed +19
-21
lines changed Original file line number Diff line number Diff line change 8
8
import androidx .multidex .MultiDexApplication ;
9
9
10
10
import com .onesignal .OneSignal ;
11
- import com .onesignal .inAppMessages .IInAppMessage ;
12
11
import com .onesignal .inAppMessages .IInAppMessageClickListener ;
13
12
import com .onesignal .inAppMessages .IInAppMessageClickEvent ;
14
13
import com .onesignal .inAppMessages .IInAppMessageDidDismissEvent ;
26
25
import com .onesignal .sdktest .constant .Text ;
27
26
import com .onesignal .sdktest .notification .OneSignalNotificationSender ;
28
27
import com .onesignal .sdktest .util .SharedPreferenceUtil ;
29
- import com .onesignal .user .IUserStateObserver ;
30
- import com .onesignal .user .UserChangedState ;
31
- import com .onesignal .user .UserState ;
28
+ import com .onesignal .user .state . IUserStateObserver ;
29
+ import com .onesignal .user .state . UserChangedState ;
30
+ import com .onesignal .user .state . UserState ;
32
31
33
32
import org .json .JSONObject ;
34
33
Original file line number Diff line number Diff line change 1
1
package com.onesignal.user
2
2
3
3
import com.onesignal.OneSignal
4
+ import com.onesignal.user.state.IUserStateObserver
4
5
import com.onesignal.user.subscriptions.IPushSubscription
5
6
6
7
/* *
@@ -26,12 +27,12 @@ interface IUserManager {
26
27
val pushSubscription: IPushSubscription
27
28
28
29
/* *
29
- * onesignalId, null if this is current unavailable
30
+ * onesignalId, empty if this is current unavailable
30
31
*/
31
32
val onesignalId: String
32
33
33
34
/* *
34
- * externalId, null if this is current unavailable
35
+ * externalId, empty if this is current unavailable
35
36
*/
36
37
val externalId: String
37
38
Original file line number Diff line number Diff line change @@ -9,16 +9,16 @@ import com.onesignal.core.internal.language.ILanguageContext
9
9
import com.onesignal.debug.LogLevel
10
10
import com.onesignal.debug.internal.logging.Logging
11
11
import com.onesignal.user.IUserManager
12
- import com.onesignal.user.IUserStateObserver
13
- import com.onesignal.user.UserChangedState
14
- import com.onesignal.user.UserState
15
12
import com.onesignal.user.internal.backend.IdentityConstants
16
13
import com.onesignal.user.internal.identity.IdentityModel
17
14
import com.onesignal.user.internal.identity.IdentityModelStore
18
15
import com.onesignal.user.internal.properties.PropertiesModel
19
16
import com.onesignal.user.internal.properties.PropertiesModelStore
20
17
import com.onesignal.user.internal.subscriptions.ISubscriptionManager
21
18
import com.onesignal.user.internal.subscriptions.SubscriptionList
19
+ import com.onesignal.user.state.IUserStateObserver
20
+ import com.onesignal.user.state.UserChangedState
21
+ import com.onesignal.user.state.UserState
22
22
import com.onesignal.user.subscriptions.IPushSubscription
23
23
24
24
internal open class UserManager (
@@ -259,6 +259,5 @@ internal open class UserManager(
259
259
it.onUserStateChange(UserChangedState (newUserState))
260
260
}
261
261
}
262
- Logging .debug(args.property)
263
262
}
264
263
}
Original file line number Diff line number Diff line change 1
- package com.onesignal.user
1
+ package com.onesignal.user.state
2
2
3
3
/* *
4
- * A user state changed handler . Implement this interface and provide the implementation
5
- * to be notified when the user has changed.
4
+ * A user state changed observer . Implement this interface and provide the implementation
5
+ * to be notified when the user state has changed.
6
6
*/
7
7
interface IUserStateObserver {
8
8
/* *
Original file line number Diff line number Diff line change 1
- package com.onesignal.user
1
+ package com.onesignal.user.state
2
2
3
3
import org.json.JSONObject
4
4
Original file line number Diff line number Diff line change 1
- package com.onesignal.user
1
+ package com.onesignal.user.state
2
2
3
3
import org.json.JSONObject
4
4
@@ -13,10 +13,9 @@ class UserState(
13
13
*/
14
14
val onesignalId : String ,
15
15
/* *
16
- * The external identifier that you use to identify users. This will be an empty string
17
- * until the user has been successfully logged in on the backend and assigned an ID.
18
- * Use [addObserver] to be notified when the [externalId] has
19
- * been successfully assigned.
16
+ * The external identifier that you use to identify users. Use [addObserver] to be notified
17
+ * when the [externalId] has been successfully assigned. This will be an empty string if no
18
+ * external identifier has been assigned to the associated [onesignalId].
20
19
*/
21
20
val externalId : String ,
22
21
) {
Original file line number Diff line number Diff line change 20
20
void onPushSubscriptionChange(com.onesignal.user.subscriptions.PushSubscriptionChangedState);
21
21
}
22
22
23
- -keep class ** implements com.onesignal.user.IUserStateObserver {
24
- void onUserStateChange(com.onesignal.user.UserChangedState);
23
+ -keep class ** implements com.onesignal.user.state. IUserStateObserver {
24
+ void onUserStateChange(com.onesignal.user.state. UserChangedState);
25
25
}
26
26
27
27
-keep class ** implements com.onesignal.notifications.INotificationServiceExtension{
You can’t perform that action at this time.
0 commit comments