Interface PushNotificationConfig


public interface PushNotificationConfig
Object holding push notification config that will be set in the contact URI
parameters of the Contact header in the REGISTER, if the AccountParams
is configured to allow push notifications, see AccountParams.setPushNotificationAllowed(boolean)
.

This object can be accessed through the AccountParams object, which can
be obtained from your Account object.
  • Method Summary

    Modifier and Type
    Method
    Description
    Instantiate a new push notification parameters with values from source.
    Gets the app's bundle identifier for "contact uri parameter".
    Gets the call_snd for "contact uri parameter".
    Gets the call_str for "contact uri parameter".
    Gets the groupchat_str for "contact uri parameter".
    Gets the msg_snd for "contact uri parameter".
    Gets the msg_str for "contact uri parameter".
    long
    Gets the native pointer used by this class to make native method calls.
    Gets the param for "contact uri parameter".
    Gets the prid for "contact uri parameter".
    Gets the provider for "contact uri parameter".
    Gets the remote token for "contact uri parameter".
    Gets the team id for "contact uri parameter".
    Gets the object stored in this object user's data
    Gets the voip token for "contact uri parameter".
    boolean
    Checks if two Push Notification Configurations are identical.
    void
    setBundleIdentifier(String bundleIdentifier)
    Sets the bundle_identifier for "contact uri parameter".
    void
    setCallSnd(String callSnd)
    Sets the call_snd for "contact uri parameter", specific for remote push
    notification.
    void
    setCallStr(String callStr)
    Sets the call_str for "contact uri parameter", specific for remote push
    notification.
    void
    setGroupChatStr(String groupChatStr)
    Sets the group_chat_str for "contact uri parameter", specific for remote push
    notification.
    void
    setMsgSnd(String msgSnd)
    Sets the msg_snd for "contact uri parameter", specific for remote push
    notification.
    void
    setMsgStr(String msgStr)
    Sets the msg_str for "contact uri parameter", specific for remote push
    notification.
    void
    Sets the param for "contact uri parameter".
    void
    Sets the prid for "contact uri parameter".
    void
    setProvider(String provider)
    Sets the provider for "contact uri parameter".
    void
    setRemotePushInterval(String remotePushInterval)
    Specifies the interval in seconds between to subsequent remote push
    notifications when remote push notifications are used to notify a call invite
    to clients that haven't published any token for VoIP and background push
    notifications.
    void
    setRemoteToken(String remoteToken)
    Sets the remote_token for "contact uri parameter", specific for remote push
    notification.
    void
    setTeamId(String teamId)
    Sets the team id for "contact uri parameter".
    void
    Sets the object to store in this object user's data
    void
    setVoipToken(String voipToken)
    Sets the voip_token for "contact uri parameter", specific for voip push
    notification.
     
  • Method Details

    • getBundleIdentifier

      @Nullable String getBundleIdentifier()
      Gets the app's bundle identifier for "contact uri parameter".

      Returns:
      The app's bundle identifier if set, null otherwise.
    • setBundleIdentifier

      void setBundleIdentifier(@Nullable String bundleIdentifier)
      Sets the bundle_identifier for "contact uri parameter".

      It's not necessary if param is set. See setParam(java.lang.String).
      Parameters:
      bundleIdentifier - The new bundle_identifier set for push notification
      config.
    • getCallSnd

      @NonNull String getCallSnd()
      Gets the call_snd for "contact uri parameter".

      Returns:
      The call_snd, default value "notes_of_the_optimistic.caf".
    • setCallSnd

      void setCallSnd(@NonNull String callSnd)
      Sets the call_snd for "contact uri parameter", specific for remote push
      notification.

      Parameters:
      callSnd - The new call_snd set for push notification config.
    • getCallStr

      @NonNull String getCallStr()
      Gets the call_str for "contact uri parameter".

      Returns:
      The call_str, default value "IC_MSG".
    • setCallStr

      void setCallStr(@NonNull String callStr)
      Sets the call_str for "contact uri parameter", specific for remote push
      notification.

      Parameters:
      callStr - The new call_str set for push notification config.
    • getGroupChatStr

      @NonNull String getGroupChatStr()
      Gets the groupchat_str for "contact uri parameter".

      Returns:
      The groupchat_str, default value "GC_MSG".
    • setGroupChatStr

      void setGroupChatStr(@NonNull String groupChatStr)
      Sets the group_chat_str for "contact uri parameter", specific for remote push
      notification.

      Parameters:
      groupChatStr - The new group_chat_str set for push notification config.
    • getMsgSnd

      @NonNull String getMsgSnd()
      Gets the msg_snd for "contact uri parameter".

      Returns:
      The msg_snd, default value "msg.caf".
    • setMsgSnd

      void setMsgSnd(@NonNull String msgSnd)
      Sets the msg_snd for "contact uri parameter", specific for remote push
      notification.

      Parameters:
      msgSnd - The new msg_snd set for push notification config.
    • getMsgStr

      @NonNull String getMsgStr()
      Gets the msg_str for "contact uri parameter".

      Returns:
      The msg_str, default value "IM_MSG".
    • setMsgStr

      void setMsgStr(@NonNull String msgStr)
      Sets the msg_str for "contact uri parameter", specific for remote push
      notification.

      Parameters:
      msgStr - The new msg_str set for push notification config.
    • getParam

      @Nullable String getParam()
      Gets the param for "contact uri parameter".

      Returns:
      The param if set, null otherwise.
    • setParam

      void setParam(@Nullable String param)
      Sets the param for "contact uri parameter".

      If it's not set, "team_id.bundle_identifier.services" will be used.
      Parameters:
      param - The new param set for push notification config.
    • getPrid

      @Nullable String getPrid()
      Gets the prid for "contact uri parameter".

      Returns:
      The prid if set, null otherwise.
    • setPrid

      void setPrid(@Nullable String prid)
      Sets the prid for "contact uri parameter".

      If it's not set, "voip_token&remote_token" will be used.
      Parameters:
      prid - The new prid set for push notification config.
    • getProvider

      @Nullable String getProvider()
      Gets the provider for "contact uri parameter".

      Returns:
      The provider if set, null otherwise.
    • setProvider

      void setProvider(@Nullable String provider)
      Sets the provider for "contact uri parameter".

      If not set, the default value will be used for "contact uri
      parameter", "firebase" for android or "apns" for ios.
      Parameters:
      provider - The new provider set for push notification config.
    • setRemotePushInterval

      void setRemotePushInterval(@NonNull String remotePushInterval)
      Specifies the interval in seconds between to subsequent remote push
      notifications when remote push notifications are used to notify a call invite
      to clients that haven't published any token for VoIP and background push
      notifications.

      In that case, several PNs are sent subsequently until the call is picked up,
      declined or canceled. This parameter sets a value for
      'pn-call-remote-push-interval' Contact header inside SIP REGISTER requests. A
      value of zero will cause the deactivation of push notification repetitions and
      the sending of the final notification. Thus, only the first push notification
      will be sent. If specified the value must be in [0;30] If not specified
      'pn-call-remote-push-interval' will not be added to Contact header.
      Parameters:
      remotePushInterval - The new remote push interval set for push
      notification config.
    • getRemoteToken

      @Nullable String getRemoteToken()
      Gets the remote token for "contact uri parameter".

      Returns:
      The remote token if set, null otherwise.
    • setRemoteToken

      void setRemoteToken(@Nullable String remoteToken)
      Sets the remote_token for "contact uri parameter", specific for remote push
      notification.

      It's not necessary if prid is set. See setPrid(java.lang.String).
      Parameters:
      remoteToken - The new remote_token set for push notification config.
    • getTeamId

      @Nullable String getTeamId()
      Gets the team id for "contact uri parameter".

      Returns:
      The team id if set, null otherwise.
    • setTeamId

      void setTeamId(@Nullable String teamId)
      Sets the team id for "contact uri parameter".

      It's not necessary if param is set. See setParam(java.lang.String).
      Parameters:
      teamId - The new team id set for push notification config.
    • getVoipToken

      @Nullable String getVoipToken()
      Gets the voip token for "contact uri parameter".

      Returns:
      The voip token if set, null otherwise.
    • setVoipToken

      void setVoipToken(@Nullable String voipToken)
      Sets the voip_token for "contact uri parameter", specific for voip push
      notification.

      It's not necessary if prid is set. See setPrid(java.lang.String).
      Parameters:
      voipToken - The new voip_token set for push notification config.
    • clone

      @NonNull PushNotificationConfig clone()
      Instantiate a new push notification parameters with values from source.

      Returns:
      The newly created PushNotificationConfig object.
    • isEqual

      @NonNull boolean isEqual(@NonNull PushNotificationConfig otherConfig)
      Checks if two Push Notification Configurations are identical.

      Parameters:
      otherConfig - The PushNotificationConfig object to compare to.
      Returns:
      True only if the two configurations are identical.
    • setUserData

      void setUserData(Object data)
      Sets the object to store in this object user's data
      Parameters:
      data - the object to store
    • getUserData

      Object getUserData()
      Gets the object stored in this object user's data
      Returns:
      the object store if any, null otherwise
    • getNativePointer

      long getNativePointer()
      Gets the native pointer used by this class to make native method calls.
      Returns:
      the nativer pointer, as long
    • toString

      String toString()
      Overrides:
      toString in class Object