Record Class DispatcherWinner.Selection
java.lang.Object
java.lang.Record
org.ek9lang.compiler.support.DispatcherWinner.Selection
- Record Components:
handler- the handler that will be selected at runtimecost- zero when the handler names this exact type, higher the further up the hierarchy the match was made
- Enclosing class:
DispatcherWinner
A winning handler and the assignment cost it won at.
-
Constructor Summary
ConstructorsConstructorDescriptionSelection(MethodSymbol handler, double cost) Creates an instance of aSelectionrecord class. -
Method Summary
Modifier and TypeMethodDescriptiondoublecost()Returns the value of thecostrecord component.final booleanIndicates whether some other object is "equal to" this one.handler()Returns the value of thehandlerrecord component.final inthashCode()Returns a hash code value for this object.booleanisDirect()True when the handler names this exact type rather than a supertype it is assignable to.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
Method Details
-
isDirect
public boolean isDirect()True when the handler names this exact type rather than a supertype it is assignable to.- Returns:
- whether the match was exact
-
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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with thecomparemethod from their corresponding wrapper classes. -
handler
-
cost
-