Record Class MailpitMessagesSummary

java.lang.Object
java.lang.Record
io.micronaut.email.mailpit.client.model.MailpitMessagesSummary
Record Components:
total - Total mailbox messages.
unread - Total unread mailbox messages.
count - Legacy current page message count.
messagesCount - Total messages matching the current query.
messagesUnread - Total unread messages matching the current query.
start - Pagination offset.
tags - All current tags.
messages - Message summaries.

public record MailpitMessagesSummary(long total, long unread, long count, long messagesCount, long messagesUnread, int start, @Nullable List<String> tags, @Nullable List<MailpitMessageSummary> messages) extends Record
Mailpit message list response.
Since:
3.1.0
  • Constructor Details

    • MailpitMessagesSummary

      public MailpitMessagesSummary(long total, long unread, long count, long messagesCount, long messagesUnread, int start, @Nullable List<String> tags, @Nullable List<MailpitMessageSummary> messages)
      Creates an instance of a MailpitMessagesSummary record class.
      Parameters:
      total - the value for the total record component
      unread - the value for the unread record component
      count - the value for the count record component
      messagesCount - the value for the messagesCount record component
      messagesUnread - the value for the messagesUnread record component
      start - the value for the start record component
      tags - the value for the tags record component
      messages - the value for the messages record component
  • Method Details

    • toString

      public final String 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.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • 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.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      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. Reference components are compared with Objects::equals(Object,Object); primitive components are compared with the compare method from their corresponding wrapper classes.
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • total

      public long total()
      Returns the value of the total record component.
      Returns:
      the value of the total record component
    • unread

      public long unread()
      Returns the value of the unread record component.
      Returns:
      the value of the unread record component
    • count

      public long count()
      Returns the value of the count record component.
      Returns:
      the value of the count record component
    • messagesCount

      public long messagesCount()
      Returns the value of the messagesCount record component.
      Returns:
      the value of the messagesCount record component
    • messagesUnread

      public long messagesUnread()
      Returns the value of the messagesUnread record component.
      Returns:
      the value of the messagesUnread record component
    • start

      public int start()
      Returns the value of the start record component.
      Returns:
      the value of the start record component
    • tags

      public @Nullable List<String> tags()
      Returns the value of the tags record component.
      Returns:
      the value of the tags record component
    • messages

      public @Nullable List<MailpitMessageSummary> messages()
      Returns the value of the messages record component.
      Returns:
      the value of the messages record component