Record Class ConstantExpressions.Truthiness
java.lang.Object
java.lang.Record
com.google.errorprone.bugpatterns.threadsafety.ConstantExpressions.Truthiness
- Enclosing class:
ConstantExpressions
public static record ConstantExpressions.Truthiness(com.google.common.collect.ImmutableSet<ConstantExpressions.ConstantExpression> requiredTrue, com.google.common.collect.ImmutableSet<ConstantExpressions.ConstantExpression> requiredFalse)
extends Record
Represents sets of things known to be true and false if a boolean statement evaluated true.
-
Constructor Summary
ConstructorsConstructorDescriptionTruthiness(com.google.common.collect.ImmutableSet<ConstantExpressions.ConstantExpression> requiredTrue, com.google.common.collect.ImmutableSet<ConstantExpressions.ConstantExpression> requiredFalse) Creates an instance of aTruthinessrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.com.google.common.collect.ImmutableSet<ConstantExpressions.ConstantExpression> Returns the value of therequiredFalserecord component.com.google.common.collect.ImmutableSet<ConstantExpressions.ConstantExpression> Returns the value of therequiredTruerecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
Truthiness
public Truthiness(com.google.common.collect.ImmutableSet<ConstantExpressions.ConstantExpression> requiredTrue, com.google.common.collect.ImmutableSet<ConstantExpressions.ConstantExpression> requiredFalse) Creates an instance of aTruthinessrecord class.- Parameters:
requiredTrue- the value for therequiredTruerecord componentrequiredFalse- the value for therequiredFalserecord 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 withObjects::equals(Object,Object). -
requiredTrue
public com.google.common.collect.ImmutableSet<ConstantExpressions.ConstantExpression> requiredTrue()Returns the value of therequiredTruerecord component.- Returns:
- the value of the
requiredTruerecord component
-
requiredFalse
public com.google.common.collect.ImmutableSet<ConstantExpressions.ConstantExpression> requiredFalse()Returns the value of therequiredFalserecord component.- Returns:
- the value of the
requiredFalserecord component
-