Record Class MessageContext.CacheKey
java.lang.Object
java.lang.Record
net.flectone.pulse.model.event.message.context.MessageContext.CacheKey
- Enclosing class:
MessageContext
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.@NonNull Map<MessageFlag, Boolean> flags()Returns the value of theflagsrecord component.final inthashCode()Returns a hash code value for this object.@NonNull Stringmessage()Returns the value of themessagerecord component.@NonNull UUIDreceiver()Returns the value of thereceiverrecord component.@NonNull UUIDsender()Returns the value of thesenderrecord component.final StringtoString()Returns a string representation of this record class.@Nullable StringReturns the value of theuserMessagerecord component.
-
Constructor Details
-
CacheKey
public CacheKey(@NonNull Map<MessageFlag, Boolean> flags, @NonNull UUID sender, @NonNull UUID receiver, @NonNull String message, @Nullable String userMessage) Creates an instance of aCacheKeyrecord class.- Parameters:
flags- the value for theflagsrecord componentsender- the value for thesenderrecord componentreceiver- the value for thereceiverrecord componentmessage- the value for themessagerecord componentuserMessage- the value for theuserMessagerecord component
-
-
Method Details
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
flags
Returns the value of theflagsrecord component.- Returns:
- the value of the
flagsrecord component
-
sender
Returns the value of thesenderrecord component.- Returns:
- the value of the
senderrecord component
-
receiver
Returns the value of thereceiverrecord component.- Returns:
- the value of the
receiverrecord component
-
message
Returns the value of themessagerecord component.- Returns:
- the value of the
messagerecord component
-
userMessage
Returns the value of theuserMessagerecord component.- Returns:
- the value of the
userMessagerecord component
-