Annotation Interface Bind.DefaultExpression
- Enclosing class:
Bind
Defines a default bind expression for a given type. When a type defines a default bind
expression, specialization methods can declare bind parameters of the type without specifying
a
bind expression
; the DSL will automatically use the
default expression
for the type.
Usage example:
@Bind.DefaultExpression("get($node)") public final class MyLanguageContext { // ... public static MyLanguageContext get(Node node) { // ... } } abstract static class NodeWithBinding extends Node { abstract Object execute(); @Specialization Object perform(@Bind("MyLanguageContext.get($node)") MyLanguageContext boundWithExplicitExpression, @Bind MyLanguageContext boundWithDefaultExpression) { // ... } }
- Since:
- 24.2
-
Required Element Summary
Required Elements
-
Element Details
-
value
-