类 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
  • 字段详细资料

    • SERIALIZED_NAME_TYPE

      public static final String SERIALIZED_NAME_TYPE
      另请参阅:
    • SERIALIZED_NAME_IGNORE_INTERVAL

      public static final String SERIALIZED_NAME_IGNORE_INTERVAL
      另请参阅:
    • SERIALIZED_NAME_IGNORE_DURATION

      public static final String SERIALIZED_NAME_IGNORE_DURATION
      另请参阅:
    • openapiFields

      public static HashSet<String> openapiFields
    • openapiRequiredFields

      public static HashSet<String> openapiRequiredFields
  • 构造器详细资料

    • EMSetOfflinePushNew

      public EMSetOfflinePushNew()
  • 方法详细资料

    • type

      public EMSetOfflinePushNew type(String type)
    • getType

      @Nullable public String getType()
      离线推送通知方式: - DEFAULT:指定的会话采用 app 的设置。该值仅对单聊或群聊会话有效,对 app 级别无效。 - ALL:接收全部离线消息的推送通知; - AT:只接收提及当前用户的离线消息的推送通知。该字段推荐在群聊中使用。若提及一个或多个用户,需在创建消息时对 ext 字段传 \"em_at_list\":[\"user1\", \"user2\" ...];若提及所有人,对该字段传 \"em_at_list\":\"all\"。 - NONE:不接收离线消息的推送通知 注意:若 app 和指定会话均设置了该参数,则该会话采用自身的设置,其他会话采用 app 的设置
      返回:
      type
    • setType

      public void setType(String type)
    • ignoreInterval

      public EMSetOfflinePushNew ignoreInterval(String ignoreInterval)
    • getIgnoreInterval

      @Nullable public String 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

      public void setIgnoreInterval(String ignoreInterval)
    • ignoreDuration

      public EMSetOfflinePushNew ignoreDuration(BigDecimal ignoreDuration)
    • getIgnoreDuration

      @Nullable public BigDecimal 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

      public void setIgnoreDuration(BigDecimal ignoreDuration)
    • equals

      public boolean equals(Object o)
      覆盖:
      equals 在类中 Object
    • hashCode

      public int hashCode()
      覆盖:
      hashCode 在类中 Object
    • toString

      public String toString()
      覆盖:
      toString 在类中 Object
    • validateJsonElement

      public static void validateJsonElement(com.google.gson.JsonElement jsonElement) throws IOException
      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

      public static EMSetOfflinePushNew fromJson(String jsonString) throws IOException
      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

      public String toJson()
      Convert an instance of EMSetOfflinePushNew to an JSON string
      返回:
      JSON string