类 EMSetOfflinePushNew
java.lang.Object
com.easemob.im.api.model.EMSetOfflinePushNew
@Generated(value="org.openapitools.codegen.languages.JavaClientCodegen",
date="2024-02-19T14:46:11.706022+08:00[Asia/Shanghai]")
public class EMSetOfflinePushNew
extends Object
EMSetOfflinePushNew
-
嵌套类概要
嵌套类 -
字段概要
字段 -
构造器概要
构造器 -
方法概要
修饰符和类型方法说明booleanstatic EMSetOfflinePushNewCreate an instance of EMSetOfflinePushNew given an JSON string离线推送免打扰时长,单位为毫秒。每天触发离线推送免打扰的时间段,精确到分钟,格式为 HH:MM-HH:MM,例如 08:30-10:00。getType()离线推送通知方式: - DEFAULT:指定的会话采用 app 的设置。inthashCode()ignoreDuration(BigDecimal ignoreDuration) ignoreInterval(String ignoreInterval) voidsetIgnoreDuration(BigDecimal ignoreDuration) voidsetIgnoreInterval(String ignoreInterval) voidtoJson()Convert an instance of EMSetOfflinePushNew to an JSON stringtoString()static voidvalidateJsonElement(com.google.gson.JsonElement jsonElement) Validates the JSON Element and throws an exception if issues found
-
字段详细资料
-
构造器详细资料
-
EMSetOfflinePushNew
public EMSetOfflinePushNew()
-
-
方法详细资料
-
type
-
getType
离线推送通知方式: - DEFAULT:指定的会话采用 app 的设置。该值仅对单聊或群聊会话有效,对 app 级别无效。 - ALL:接收全部离线消息的推送通知; - AT:只接收提及当前用户的离线消息的推送通知。该字段推荐在群聊中使用。若提及一个或多个用户,需在创建消息时对 ext 字段传 \"em_at_list\":[\"user1\", \"user2\" ...];若提及所有人,对该字段传 \"em_at_list\":\"all\"。 - NONE:不接收离线消息的推送通知 注意:若 app 和指定会话均设置了该参数,则该会话采用自身的设置,其他会话采用 app 的设置- 返回:
- type
-
setType
-
ignoreInterval
-
getIgnoreInterval
每天触发离线推送免打扰的时间段,精确到分钟,格式为 HH:MM-HH:MM,例如 08:30-10:00。该时间为 24 小时制,免打扰时间段的开始时间和结束时间中的小时数和分钟数的取值范围分别为 [00,23] 和 [00,59]。 该参数的设置说明如下: - 该参数仅针对 app 生效,对单聊或群聊不生效。 - 该参数设置后,免打扰模式每天定时触发。例如,开始时间为 08:00,结束时间为 10:00,免打扰模式在每天的 8:00-10:00 内生效。若你在 11:00 设置开始时间为 08:00,结束时间为 12:00,则免打扰模式在当天的 11:00-12:00 生效,以后每天均在 8:00-12:00 生效。 - 若开始时间和结束时间相同,则全天免打扰。 - 若结束时间早于开始时间,则免打扰模式在每天的开始时间到次日的结束时间内生效。例如,开始时间为 10:00,结束时间为 08:00,则免打扰模式的在当天的 10:00 到次日的 8:00 生效。 - 目前仅支持在每天的一个指定时间段内开启免打扰模式,不支持多个免打扰时间段,新的设置会覆盖之前的设置。 - 若不设置该参数,传空字符串。 - 若该参数和 ignoreDuration 均设置,免打扰模式当日在这两个时间段均生效,例如,例如,上午 8:00 将 app 级的 ignoreInterval 设置为 8:00-10:00,ignoreDuration 设置为 14400000 毫秒(4 个小时),则 app 在今天 8:00-12:00 和以后每天 8:00-10:00 处于免打扰模式- 返回:
- ignoreInterval
-
setIgnoreInterval
-
ignoreDuration
-
getIgnoreDuration
离线推送免打扰时长,单位为毫秒。该参数的取值范围为 [0,604800000],0 表示该参数无效,604800000 表示免打扰模式持续 7 天。 - 该参数对 app 和单聊和群聊均生效。 - 与 ignoreInterval 的设置每天生效不同,该参数为一次有效,设置后立即生效,例如,上午 8:00 将 app 层级的 ignoreDuration 设置为 14400000 毫秒(4 个小时),则 app 只在今天 8:00-12:00 处于免打扰模式。 - 若该参数和 ignoreDuration 均设置,免打扰模式当日在这两个时间段均生效,例如,上午 8:00 将 app 级的 ignoreInterval 设置为 8:00-10:00,ignoreDuration 设置为 14400000 毫秒(4 个小时),则 app 在今天 8:00-12:00 和以后每天 8:00-10:00 处于免打扰模式- 返回:
- ignoreDuration
-
setIgnoreDuration
-
equals
-
hashCode
public int hashCode() -
toString
-
validateJsonElement
Validates the JSON Element and throws an exception if issues found- 参数:
jsonElement- JSON Element- 抛出:
IOException- if the JSON Element is invalid with respect to EMSetOfflinePushNew
-
fromJson
Create an instance of EMSetOfflinePushNew given an JSON string- 参数:
jsonString- JSON string- 返回:
- An instance of EMSetOfflinePushNew
- 抛出:
IOException- if the JSON string is invalid with respect to EMSetOfflinePushNew
-
toJson
Convert an instance of EMSetOfflinePushNew to an JSON string- 返回:
- JSON string
-