IMSDK
IM features a comprehensive suite of solutions including global access, one-to-one chat, group chat, message push, profile and relationship chain hosting, and account authentication. It also provides complete app access and backend management APIs.
V2TIMOfflinePushInfo

Public Member Functions

 V2TIMOfflinePushInfo ()
 
String getTitle ()
 
void setTitle (String title)
 
String getDesc ()
 
void setDesc (String description)
 
void setExt (byte[] ext)
 
byte[] getExt ()
 
void disablePush (boolean disable)
 
boolean isDisablePush ()
 
void setIOSSound (String sound)
 
void setIgnoreIOSBadge (boolean ignoreIOSBadge)
 
void setAndroidOPPOChannelID (String channelID)
 
void setAndroidVIVOClassification (int classification)
 

Static Public Attributes

static final String IOS_OFFLINE_PUSH_NO_SOUND = "push.no_sound"
 
static final String IOS_OFFLINE_PUSH_DEFAULT_SOUND = "default"
 

Constructor & Destructor Documentation

◆ V2TIMOfflinePushInfo()

Member Function Documentation

◆ getTitle()

String getTitle ( )
inline

Get the offline push notification title

Returns
Notification title

◆ setTitle()

void setTitle ( String  title)
inline

Set the offline push display title

Parameters
titleNotification bar title

◆ getDesc()

String getDesc ( )
inline

Get the offline push notification content

Returns
Notification content

◆ setDesc()

void setDesc ( String  description)
inline

Set the offline push display content

Attention
This field must be set for custom message offline push.
Parameters
descriptionNotification bar content

◆ setExt()

void setExt ( byte[]  ext)
inline

Set the extended field passed through by offline push

Parameters
extNotification bar passthrough message

◆ getExt()

byte [] getExt ( )
inline

Get the extended field passed through by offline push

◆ disablePush()

void disablePush ( boolean  disable)
inline

Whether to disable push (push enabled by default)

Parameters
disabletrue: disable; false: enable

◆ isDisablePush()

boolean isDisablePush ( )
inline

Get the offline push disablement status

Returns
Disabled. true: disabled; false: enabled

◆ setIOSSound()

void setIOSSound ( String  sound)
inline

Offline push sound setting (valid only for iOS) When sound is IOS_OFFLINE_PUSH_NO_SOUND, no sound is played when a message is received. When sound is IOS_OFFLINE_PUSH_DEFAULT_SOUND, the system alert sound is played when a message is received. To customize iOSSound, link the audio file to the Xcode project and set iOSSound to the audio filename (with the extension name).

Parameters
soundiOS Sound path

◆ setIgnoreIOSBadge()

void setIgnoreIOSBadge ( boolean  ignoreIOSBadge)
inline

Whether to ignore the badge count for offline push (valid only for iOS) If this parameter is set to true, the unread message count on the app badge will not increase when the message is received by the iOS device.

Parameters
ignoreIOSBadgeiOS Status of the unread message count on the app badge. true: ignore; false: enable

◆ setAndroidOPPOChannelID()

void setAndroidOPPOChannelID ( String  channelID)
inline

Offline push channel ID for OPPO phones that run Android 8.0 or later

Parameters
channelIDOPPO phone channel ID

◆ setAndroidVIVOClassification()

void setAndroidVIVOClassification ( int  classification)
inline

Offline push setting for vivo phones

Parameters
classificationOffline push message classification for vivo phones. 0: operation message; 1: system message. The default value is 1.

Field Documentation

◆ IOS_OFFLINE_PUSH_NO_SOUND

final String IOS_OFFLINE_PUSH_NO_SOUND = "push.no_sound"
static

◆ IOS_OFFLINE_PUSH_DEFAULT_SOUND

final String IOS_OFFLINE_PUSH_DEFAULT_SOUND = "default"
static