Package ru.objectsfill.core
Record Class RandomValueFieldSetterCallback
java.lang.Object
java.lang.Record
ru.objectsfill.core.RandomValueFieldSetterCallback
- All Implemented Interfaces:
FieldCallback
A necessary class for reflection to traverse fields.
-
Constructor Summary
ConstructorsConstructorDescriptionCreates an instance of aRandomValueFieldSetterCallbackrecord class. -
Method Summary
Modifier and TypeMethodDescriptionvoidOverrides the method for field traversal.final booleanIndicates whether some other object is "equal to" this one.fill()Returns the value of thefillrecord component.final inthashCode()Returns a hash code value for this object.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
RandomValueFieldSetterCallback
Creates an instance of aRandomValueFieldSetterCallbackrecord class.- Parameters:
fill- the value for thefillrecord component
-
-
Method Details
-
doWith
Overrides the method for field traversal.- Specified by:
doWithin interfaceFieldCallback- Parameters:
field- The field to process.- Throws:
IllegalAccessException- If the field is inaccessible.
-
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). -
fill
Returns the value of thefillrecord component.- Returns:
- the value of the
fillrecord component
-