Package spoon.reflect.visitor.filter
Class VariableScopeFunction
java.lang.Object
spoon.reflect.visitor.filter.VariableScopeFunction
- All Implemented Interfaces:
CtConsumableFunction<CtVariable<?>>
The mapping function, accepting
CtVariable
- CtLocalVariable - local variable declared in body
- CtParameter - method parameter
- CtCatchVariable - try - catch variable
-
Nested Class Summary
-
Field Summary
Modifier and TypeFieldDescriptionprotected CtConsumer<Object>
protected VariableScopeFunction.Visitor
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
apply(CtVariable<?> variable, CtConsumer<Object> outputConsumer)
Evaluates the function on the given input.
-
Field Details
-
visitor
-
outputConsumer
-
-
Constructor Details
-
VariableScopeFunction
public VariableScopeFunction()
-
-
Method Details
-
apply
Description copied from interface:CtConsumableFunction
Evaluates the function on the given input.- Specified by:
apply
in interfaceCtConsumableFunction<CtVariable<?>>
- Parameters:
variable
- the input of the functionoutputConsumer
- the consumer which accepts the results of this function.
-