org.axonframework.eventstore.jpa
Class AbstractEventEntry

java.lang.Object
  extended by org.axonframework.eventstore.jpa.AbstractEventEntryData<byte[]>
      extended by org.axonframework.eventstore.jpa.AbstractEventEntry
All Implemented Interfaces:
SerializedDomainEventData<byte[]>
Direct Known Subclasses:
DomainEventEntry, SnapshotEventEntry

@MappedSuperclass
public abstract class AbstractEventEntry
extends AbstractEventEntryData<byte[]>

Data needed by different types of event logs.

Since:
0.5
Author:
Allard Buijze

Nested Class Summary
 
Nested classes/interfaces inherited from class org.axonframework.eventstore.jpa.AbstractEventEntryData
AbstractEventEntryData.PK
 
Constructor Summary
protected AbstractEventEntry()
          Default constructor, as required by JPA specification.
protected AbstractEventEntry(String type, DomainEventMessage event, org.joda.time.DateTime timestamp, SerializedObject<byte[]> payload, SerializedObject<byte[]> metaData)
          Initialize an Event entry for the given event.
protected AbstractEventEntry(String type, DomainEventMessage event, SerializedObject<byte[]> payload, SerializedObject<byte[]> metaData)
          Initialize an Event entry for the given event.
 
Method Summary
 SerializedObject<byte[]> getMetaData()
          Returns the serialized data of the MetaData of the serialized Event.
 SerializedObject<byte[]> getPayload()
          Returns the serialized data of the Event Message's payload.
 
Methods inherited from class org.axonframework.eventstore.jpa.AbstractEventEntryData
getAggregateIdentifier, getEventIdentifier, getPayloadType, getSequenceNumber, getTimestamp, getType
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractEventEntry

protected AbstractEventEntry(String type,
                             DomainEventMessage event,
                             SerializedObject<byte[]> payload,
                             SerializedObject<byte[]> metaData)
Initialize an Event entry for the given event.

Parameters:
type - The type identifier of the aggregate root the event belongs to
event - The event to store in the EventStore
payload - The serialized payload of the Event
metaData - The serialized metaData of the Event

AbstractEventEntry

protected AbstractEventEntry(String type,
                             DomainEventMessage event,
                             org.joda.time.DateTime timestamp,
                             SerializedObject<byte[]> payload,
                             SerializedObject<byte[]> metaData)
Initialize an Event entry for the given event.

Parameters:
type - The type identifier of the aggregate root the event belongs to
event - The event to store in the EventStore
timestamp - The timestamp to store
payload - The serialized payload of the Event
metaData - The serialized metaData of the Event

AbstractEventEntry

protected AbstractEventEntry()
Default constructor, as required by JPA specification. Do not use directly!

Method Detail

getPayload

public SerializedObject<byte[]> getPayload()
Description copied from interface: SerializedDomainEventData
Returns the serialized data of the Event Message's payload.

Returns:
the serialized data of the Event Message's payload

getMetaData

public SerializedObject<byte[]> getMetaData()
Description copied from interface: SerializedDomainEventData
Returns the serialized data of the MetaData of the serialized Event.

Returns:
the serialized data of the MetaData of the serialized Event


Copyright © 2010-2016. All Rights Reserved.