Record Class DistributedMultiMap.MultiMapStats
java.lang.Object
java.lang.Record
com.loomcache.server.datastructures.DistributedMultiMap.MultiMapStats
- Enclosing class:
DistributedMultiMap
public static record DistributedMultiMap.MultiMapStats(int keyCount, int valueCount, double avgValuesPerKey)
extends Record
Compact stats record used by enhanced tests (keyCount, valueCount, avgValuesPerKey).
- Since:
- 1.0
-
Constructor Summary
ConstructorsConstructorDescriptionMultiMapStats(int keyCount, int valueCount, double avgValuesPerKey) Creates an instance of aMultiMapStatsrecord class. -
Method Summary
Modifier and TypeMethodDescriptiondoubleReturns the value of theavgValuesPerKeyrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.intkeyCount()Returns the value of thekeyCountrecord component.final StringtoString()Returns a string representation of this record class.intReturns the value of thevalueCountrecord component.
-
Constructor Details
-
MultiMapStats
public MultiMapStats(int keyCount, int valueCount, double avgValuesPerKey) Creates an instance of aMultiMapStatsrecord class.- Parameters:
keyCount- the value for thekeyCountrecord componentvalueCount- the value for thevalueCountrecord componentavgValuesPerKey- the value for theavgValuesPerKeyrecord 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. -
keyCount
public int keyCount()Returns the value of thekeyCountrecord component.- Returns:
- the value of the
keyCountrecord component
-
valueCount
public int valueCount()Returns the value of thevalueCountrecord component.- Returns:
- the value of the
valueCountrecord component
-
avgValuesPerKey
public double avgValuesPerKey()Returns the value of theavgValuesPerKeyrecord component.- Returns:
- the value of the
avgValuesPerKeyrecord component
-