Record Class SingleValueBin<D extends BinDefinition>
java.lang.Object
java.lang.Record
org.graylog.plugins.views.search.engine.monitoring.data.histogram.SingleValueBin<D>
- All Implemented Interfaces:
Bin<D>
public record SingleValueBin<D extends BinDefinition>(D extends BinDefinition binDefinition, Number value)
extends Record
implements Bin<D>
-
Field Summary
Fields inherited from interface org.graylog.plugins.views.search.engine.monitoring.data.histogram.Bin
MULTI_BIN_TYPE, SINGLE_BIN_TYPE, TYPE -
Constructor Summary
ConstructorsConstructorDescriptionSingleValueBin(D binDefinition, Number value) Creates an instance of aSingleValueBinrecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thebinDefinitionrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.final StringtoString()Returns a string representation of this record class.value()Returns the value of thevaluerecord component.
-
Constructor Details
-
SingleValueBin
Creates an instance of aSingleValueBinrecord class.- Parameters:
binDefinition- the value for thebinDefinitionrecord componentvalue- the value for thevaluerecord component
-
-
Method Details
-
toDataLine
- Specified by:
toDataLinein interfaceBin<D extends BinDefinition>
-
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). -
binDefinition
Returns the value of thebinDefinitionrecord component.- Specified by:
binDefinitionin interfaceBin<D extends BinDefinition>- Returns:
- the value of the
binDefinitionrecord component
-
value
Returns the value of thevaluerecord component.- Returns:
- the value of the
valuerecord component
-