目录

SampleEvent

java.lang.Object

|---com.huawei.hihealth.CommonParam

|---|---com.huawei.hihealth.model.SampleEvent

public class SampleEvent
extends CommonParam

事件通知类

Since:

2022-04-07

Nested Class Summary

Modifier and Type

Class and Description

static class

SampleEvent.Type 事件通知类型枚举

Nested classes/interfaces inherited from interface android.os.Parcelable

android.os.Parcelable.ClassLoaderCreator, android.os.Parcelable.Creator

Field Summary

Modifier and Type

Field and Description

static java.lang.String

SEPARATOR eventType分隔符

Fields inherited from interface android.os.Parcelable

CONTENTS_FILE_DESCRIPTOR, PARCELABLE_WRITE_RETURN_VALUE

Constructor Summary

Constructor and Description

SampleEvent(SampleEvent.Type type, java.lang.String subType, java.lang.String subscriptionId, long eventTime, java.util.List metaDatas) 构造函数

Method Summary

Modifier and Type

Method and Description

long

getEventTime() 获取事件通知时间

java.util.List

getMetaData() 获取消息元数据列表

java.lang.String

getSubscriptionId() 获取订阅记录id

java.lang.String

getSubType() 获取事件通知子类别

SampleEvent.Type

getType() 获取事件通知类别

Methods inherited from class com.huawei.hihealth.CommonParam

getBoolean, getDouble, getInt, getString, putBoolean, putDouble, putInt, putString

Methods inherited from class java.lang.Object

equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Methods inherited from interface android.os.Parcelable

describeContents, writeToParcel

Field Detail

[h2]SEPARATOR

public static final java.lang.String SEPARATOR

eventType分隔符

See Also:

Constant Field Values

Constructor Detail

[h2]SampleEvent

public SampleEvent(SampleEvent.Type type, java.lang.String subType, java.lang.String subscriptionId, long eventTime, java.util.List metaDatas)

构造函数

Parameters:

Parameter Name

Parameter Description

type

事件类别

subType

事件子类别

subscriptionId

订阅记录id

eventTime

事件发生时间

metaDatas

事件消息元数据列表

Method Detail

[h2]getSubscriptionId

public java.lang.String getSubscriptionId()

获取订阅记录id

Returns:

订阅记录id

[h2]getType

public SampleEvent.Type getType()

获取事件通知类别

Returns:

事件类别

[h2]getSubType

public java.lang.String getSubType()

获取事件通知子类别

Returns:

事件子类别

[h2]getMetaData

public java.util.List getMetaData()

获取消息元数据列表

Returns:

消息元数据列表

[h2]getEventTime

public long getEventTime()

获取事件通知时间

Returns:

通知时间