Record Class DistributedTopic.TopicStatistics
java.lang.Object
java.lang.Record
com.loomcache.server.datastructures.DistributedTopic.TopicStatistics
- Enclosing class:
DistributedTopic<T>
public static record DistributedTopic.TopicStatistics(long totalPublished, long totalDelivered, long totalFiltered, int subscriberCount, long avgDeliveryTimeNs)
extends Record
- Since:
- 1.0
-
Constructor Summary
ConstructorsConstructorDescriptionTopicStatistics(long totalPublished, long totalDelivered, long totalFiltered, int subscriberCount, long avgDeliveryTimeNs) Creates an instance of aTopicStatisticsrecord class. -
Method Summary
Modifier and TypeMethodDescriptionlongReturns the value of theavgDeliveryTimeNsrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.intReturns the value of thesubscriberCountrecord component.final StringtoString()Returns a string representation of this record class.longReturns the value of thetotalDeliveredrecord component.longReturns the value of thetotalFilteredrecord component.longReturns the value of thetotalPublishedrecord component.
-
Constructor Details
-
TopicStatistics
public TopicStatistics(long totalPublished, long totalDelivered, long totalFiltered, int subscriberCount, long avgDeliveryTimeNs) Creates an instance of aTopicStatisticsrecord class.- Parameters:
totalPublished- the value for thetotalPublishedrecord componenttotalDelivered- the value for thetotalDeliveredrecord componenttotalFiltered- the value for thetotalFilteredrecord componentsubscriberCount- the value for thesubscriberCountrecord componentavgDeliveryTimeNs- the value for theavgDeliveryTimeNsrecord 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 with thecomparemethod from their corresponding wrapper classes. -
totalPublished
public long totalPublished()Returns the value of thetotalPublishedrecord component.- Returns:
- the value of the
totalPublishedrecord component
-
totalDelivered
public long totalDelivered()Returns the value of thetotalDeliveredrecord component.- Returns:
- the value of the
totalDeliveredrecord component
-
totalFiltered
public long totalFiltered()Returns the value of thetotalFilteredrecord component.- Returns:
- the value of the
totalFilteredrecord component
-
subscriberCount
public int subscriberCount()Returns the value of thesubscriberCountrecord component.- Returns:
- the value of the
subscriberCountrecord component
-
avgDeliveryTimeNs
public long avgDeliveryTimeNs()Returns the value of theavgDeliveryTimeNsrecord component.- Returns:
- the value of the
avgDeliveryTimeNsrecord component
-