public final class Event extends Object
| Constructor and Description |
|---|
Event(EventLogProto.Event e)
Constructs an event from the protobuf Event type.
|
Event(long when,
String topic,
String content)
This is the constructor for Event.
|
Event(String topic,
String content)
This is the constructor for Event, the timestamp is set to the current time.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object o) |
String |
getContent() |
String |
getTopic() |
long |
getWhen() |
EventLogProto.Event |
toProto()
Converts this object to the protobuf representation.
|
String |
toString() |
public Event(long when,
String topic,
String content)
when - When the even happened, in UNIX nano seconds.topic - The topic of the event, which can be used to filter events on retrieval.content - The content of the event.public Event(EventLogProto.Event e)
e - The event of the protobuf type.public EventLogProto.Event toProto()
public long getWhen()
public String getTopic()
public String getContent()
Copyright © 2018. All rights reserved.