Package io.micronaut.gcp.pubsub.push
Record Class PushRequest.PushMessage
java.lang.Object
java.lang.Record
io.micronaut.gcp.pubsub.push.PushRequest.PushMessage
- Record Components:
attributes- the message attributesdata- the message data, encoded as a Base64 stringmessageId- the message idpublishTime- the publishing time of the message
- Enclosing class:
- PushRequest
public static record PushRequest.PushMessage(Map<String,String> attributes, String data, @NotBlank String messageId, @NotBlank String publishTime)
extends Record
The body of the deserialized push message.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theattributesrecord component.data()Returns the value of thedatarecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.@NotBlank StringReturns the value of themessageIdrecord component.@NotBlank StringReturns the value of thepublishTimerecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
PushMessage
public PushMessage(Map<String, String> attributes, String data, @NotBlank @NotBlank String messageId, @NotBlank @NotBlank String publishTime) Creates an instance of aPushMessagerecord class.- Parameters:
attributes- the value for theattributesrecord componentdata- the value for thedatarecord componentmessageId- the value for themessageIdrecord componentpublishTime- the value for thepublishTimerecord component
-
-
Method Details
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
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). -
attributes
Returns the value of theattributesrecord component.- Returns:
- the value of the
attributesrecord component
-
data
Returns the value of thedatarecord component.- Returns:
- the value of the
datarecord component
-
messageId
Returns the value of themessageIdrecord component.- Returns:
- the value of the
messageIdrecord component
-
publishTime
Returns the value of thepublishTimerecord component.- Returns:
- the value of the
publishTimerecord component
-