Record Class ConstantExpressions.ConstantExpression.PureMethodInvocation
java.lang.Object
java.lang.Record
com.google.errorprone.bugpatterns.threadsafety.ConstantExpressions.ConstantExpression.PureMethodInvocation
- All Implemented Interfaces:
ConstantExpressions.ConstantExpression
- Enclosing interface:
ConstantExpressions.ConstantExpression
public static record ConstantExpressions.ConstantExpression.PureMethodInvocation(com.sun.tools.javac.code.Symbol symbol, com.google.common.collect.ImmutableList<ConstantExpressions.ConstantExpression> arguments, Optional<ConstantExpressions.ConstantExpression> receiver)
extends Record
implements ConstantExpressions.ConstantExpression
Represents both a constant method call or a constant field/local access, depending on the
actual type of
symbol.-
Nested Class Summary
Nested classes/interfaces inherited from interface ConstantExpressions.ConstantExpression
ConstantExpressions.ConstantExpression.ConstantEquals, ConstantExpressions.ConstantExpression.Literal, ConstantExpressions.ConstantExpression.PureMethodInvocation -
Constructor Summary
ConstructorsConstructorDescriptionPureMethodInvocation(com.sun.tools.javac.code.Symbol symbol, com.google.common.collect.ImmutableList<ConstantExpressions.ConstantExpression> arguments, Optional<ConstantExpressions.ConstantExpression> receiver) Creates an instance of aPureMethodInvocationrecord class. -
Method Summary
Modifier and TypeMethodDescriptionvoidcom.google.common.collect.ImmutableList<ConstantExpressions.ConstantExpression> Returns the value of theargumentsrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.receiver()Returns the value of thereceiverrecord component.com.sun.tools.javac.code.Symbolsymbol()Returns the value of thesymbolrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
PureMethodInvocation
public PureMethodInvocation(com.sun.tools.javac.code.Symbol symbol, com.google.common.collect.ImmutableList<ConstantExpressions.ConstantExpression> arguments, Optional<ConstantExpressions.ConstantExpression> receiver) Creates an instance of aPureMethodInvocationrecord class.- Parameters:
symbol- the value for thesymbolrecord componentarguments- the value for theargumentsrecord componentreceiver- the value for thereceiverrecord component
-
-
Method Details
-
accept
- Specified by:
acceptin interfaceConstantExpressions.ConstantExpression
-
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). -
symbol
public com.sun.tools.javac.code.Symbol symbol()Returns the value of thesymbolrecord component.- Returns:
- the value of the
symbolrecord component
-
arguments
Returns the value of theargumentsrecord component.- Returns:
- the value of the
argumentsrecord component
-
receiver
Returns the value of thereceiverrecord component.- Returns:
- the value of the
receiverrecord component
-