Exemplo n.º 1
0
    internal static OSEmailSubscriptionStateChanges parseOSEmailSubscriptionStateChanges(OneSignalPlatform platform, string stateChangesJSONString)
    {
        var stateChangesJson = Json.Deserialize(stateChangesJSONString) as Dictionary <string, object>;

        var emailStateChanges = new OSEmailSubscriptionStateChanges();

        emailStateChanges.to   = platform.parseOSEmailSubscriptionState(stateChangesJson ["to"]);
        emailStateChanges.from = platform.parseOSEmailSubscriptionState(stateChangesJson ["from"]);

        return(emailStateChanges);
    }
Exemplo n.º 2
0
 private void OneSignal_emailSubscriptionObserver(OSEmailSubscriptionStateChanges stateChanges)
 {
     Debug.Log("EMAIL stateChanges.from.status: " + stateChanges.from.emailUserId + ", " + stateChanges.from.emailAddress);
     Debug.Log("EMAIL stateChanges.to.status: " + stateChanges.to.emailUserId + ", " + stateChanges.to.emailAddress);
 }
Exemplo n.º 3
0
    // Called from native SDK
    private void onOSEmailSubscriptionChanged(string stateChangesJSONString)
    {
        OSEmailSubscriptionStateChanges stateChanges = oneSignalPlatform.ParseOSEmailSubscriptionStateChanges(stateChangesJSONString);

        internalEmailSubscriptionObserver(stateChanges);
    }