Module nl.jqno.equalsverifier
Class EnumValueProvider
java.lang.Object
nl.jqno.equalsverifier.internal.valueproviders.EnumValueProvider
- All Implemented Interfaces:
ValueProvider
A ValueProvider for enums.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprovide(TypeTag tag, Attributes attributes) Returns a tuple of two different prefabricated values of the specified type.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface nl.jqno.equalsverifier.internal.valueproviders.ValueProvider
provideOrThrow
-
Constructor Details
-
EnumValueProvider
public EnumValueProvider()
-
-
Method Details
-
provide
Returns a tuple of two different prefabricated values of the specified type.}- Specified by:
providein interfaceValueProvider- Type Parameters:
T- The returned tuple will have this generic type.- Parameters:
tag- A description of the desired type, including generic parameters.attributes- The attributes of the field that the provided values must be linked to.- Returns:
- A tuple of two different values of the given type, or an empty Optional if none could be found.
-