public abstract class GenericMessageImpl<R> extends ResourceImpl<Message> implements GenericMessage<R>
Modifier and Type | Field and Description |
---|---|
protected com.fasterxml.jackson.databind.JsonNode |
resource |
protected UserProvidedIdentifiers |
resourceUserProvidedIdentifiers |
protected Long |
resourceVersion |
protected Long |
sequenceNumber |
protected String |
type |
Constructor and Description |
---|
GenericMessageImpl(String id,
Long version,
ZonedDateTime createdAt,
ZonedDateTime lastModifiedAt,
com.fasterxml.jackson.databind.JsonNode resource,
Long sequenceNumber,
Long resourceVersion,
String type,
UserProvidedIdentifiers resourceUserProvidedIdentifiers,
Class<R> clazz) |
Modifier and Type | Method and Description |
---|---|
<T> T |
as(Class<T> messageClass) |
boolean |
equals(Object o) |
com.fasterxml.jackson.databind.JsonNode |
getPayload()
Gets the top level fields not mapped by the current message class.
|
Reference<R> |
getResource() |
UserProvidedIdentifiers |
getResourceUserProvidedIdentifiers() |
Long |
getResourceVersion() |
Long |
getSequenceNumber() |
String |
getType() |
int |
hashCode() |
Reference<Message> |
toReference()
Creates a reference to this resource, the reference may not be filled.
|
getCreatedAt, getId, getLastModifiedAt, getVersion
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
referenceOfId, referenceTypeId, typeReference
getCreatedAt, getId, getLastModifiedAt, getVersion
hasSameIdAs, toResourceIdentifier
protected final Long sequenceNumber
protected final com.fasterxml.jackson.databind.JsonNode resource
protected final Long resourceVersion
protected final String type
protected final UserProvidedIdentifiers resourceUserProvidedIdentifiers
public GenericMessageImpl(String id, Long version, ZonedDateTime createdAt, ZonedDateTime lastModifiedAt, com.fasterxml.jackson.databind.JsonNode resource, Long sequenceNumber, Long resourceVersion, String type, UserProvidedIdentifiers resourceUserProvidedIdentifiers, Class<R> clazz)
public Long getResourceVersion()
getResourceVersion
in interface Message
public Long getSequenceNumber()
getSequenceNumber
in interface Message
public UserProvidedIdentifiers getResourceUserProvidedIdentifiers()
getResourceUserProvidedIdentifiers
in interface Message
public Reference<Message> toReference()
Referenceable
toReference
in interface Message
toReference
in interface Referenceable<Message>
toReference
in interface Resource<Message>
public Reference<R> getResource()
getResource
in interface GenericMessage<R>
getResource
in interface Message
public com.fasterxml.jackson.databind.JsonNode getPayload()
Message
getPayload
in interface Message