public final class ReadMessage
extends java.lang.Object
| Modifier and Type | Method and Description |
|---|---|
static ReadMessage |
fromEvent(ResolvedEvent event) |
static ReadMessage |
fromFirstStreamPosition(long position) |
static ReadMessage |
fromLastAllPosition(long commit,
long prepare) |
static ReadMessage |
fromLastStreamPosition(long position) |
ResolvedEvent |
getEvent()
Returns a resolved event if defined.
|
long |
getFirstStreamPosition()
Returns the first stream position if defined.
|
Position |
getLastAllPosition()
Returns the last $all position if defined.
|
long |
getLastStreamPosition()
Returns the last stream position if defined.
|
boolean |
hasEvent()
If this messages holds a resolved event.
|
boolean |
hasFirstStreamPosition()
If this messages holds the first stream position.
|
boolean |
hasLastAllPosition()
If this messages holds the last $all position.
|
boolean |
hasLastStreamPosition()
If this messages holds the last stream position.
|
public static ReadMessage fromEvent(ResolvedEvent event)
public static ReadMessage fromFirstStreamPosition(long position)
public static ReadMessage fromLastStreamPosition(long position)
public static ReadMessage fromLastAllPosition(long commit, long prepare)
public boolean hasFirstStreamPosition()
public boolean hasLastStreamPosition()
public boolean hasLastAllPosition()
public boolean hasEvent()
public long getFirstStreamPosition()
java.lang.NullPointerException - if not defined.public long getLastStreamPosition()
java.lang.NullPointerException - if not defined.public Position getLastAllPosition()
public ResolvedEvent getEvent()