public class Notification<T>
extends java.lang.Object
implements java.io.Serializable
Constructor and Description |
---|
Notification(long remoteId,
NotificationType<T> type,
long sequence) |
Notification(long remoteId,
NotificationType<T> type,
long sequence,
T data)
Create a notification.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object o) |
T |
getData() |
long |
getRemoteId() |
long |
getSequence() |
NotificationType<T> |
getType() |
int |
hashCode() |
java.lang.String |
toString() |
public Notification(long remoteId, NotificationType<T> type, long sequence)
public Notification(long remoteId, NotificationType<T> type, long sequence, T data)
remoteId
- The remote id of the thing emitting the notification.type
- The type of notification.sequence
- The sequence number.data
- Any user data. May be null.public long getRemoteId()
public NotificationType<T> getType()
public long getSequence()
public T getData()
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object