public class VersionedAggregateIdentifier extends Object
Constructor and Description |
---|
VersionedAggregateIdentifier(Object identifier,
Long version)
Initializes a VersionedAggregateIdentifier with the given
identifier and version . |
VersionedAggregateIdentifier(String identifier,
Long version)
Deprecated.
In favor of
VersionedAggregateIdentifier(Object, Long) , since
the identifier can be a non-String . |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object o) |
String |
getIdentifier()
Returns the string representation of the identifier of the targeted Aggregate.
|
Object |
getIdentifierValue()
Returns the object representation of the identifier of the targeted Aggregate.
|
Long |
getVersion()
Returns the version of the targeted Aggregate, or
null if the version is irrelevant. |
int |
hashCode() |
@Deprecated public VersionedAggregateIdentifier(String identifier, Long version)
VersionedAggregateIdentifier(Object, Long)
, since
the identifier
can be a non-String
.identifier
and version
.identifier
- The non-null string identifier of the targeted aggregate.version
- The expected version of the targeted aggregate, or null
if the version is irrelevant.public VersionedAggregateIdentifier(@Nonnull Object identifier, Long version)
identifier
and version
.identifier
- The non-null identifier of the targeted aggregate.version
- The expected version of the targeted aggregate, or null
if the version is irrelevant.@Nonnull public String getIdentifier()
null
.@Nonnull public Object getIdentifierValue()
null
.public Long getVersion()
null
if the version is irrelevant.Copyright © 2010–2023. All rights reserved.