Package eu.bandm.tools.ramus.runtime2
Class Reducer.Context<D>
java.lang.Object
eu.bandm.tools.ramus.runtime2.Reducer.Context<D>
- All Implemented Interfaces:
MessageReceiver<SimpleMessage<D>>
,Environment
- Enclosing class:
Reducer
public static class Reducer.Context<D>
extends Object
implements MessageReceiver<SimpleMessage<D>>, Environment
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription<X> X
abort()
Aborts the current creation of an AST node.<K,
V> V compute
(Object varKey, K mapKey, BiFunction<? super K, ? super V, ? extends V> remappingFunction) <K,
V> V computeIfAbsent
(Object varKey, K mapKey, Function<? super K, ? extends V> fun) void
void
getValue()
void
void
void
pop()
void
push()
void
void
receive
(SimpleMessage<D> message) Receive the given message.void
void
void
void
void
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface eu.bandm.tools.message.MessageReceiver
ifSubcriticalThen, ifSubcriticalThen, ifSubcriticalThenElse
-
Constructor Details
-
Context
-
-
Method Details
-
getMessages
-
getLocation
-
receive
Description copied from interface:MessageReceiver
Receive the given message.- Specified by:
receive
in interfaceMessageReceiver<D>
- Parameters:
message
- the message to receive.
-
warning
-
warning
-
warning
-
warning
-
error
-
error
-
hint
-
hint
-
getValue
- Specified by:
getValue
in interfaceEnvironment
-
get
- Specified by:
get
in interfaceEnvironment
-
setValue
-
put
-
push
public void push() -
pop
public void pop() -
compute
public <K,V> V compute(Object varKey, K mapKey, BiFunction<? super K, ? super V, ? extends V> remappingFunction) -
computeIfAbsent
-
abort
Aborts the current creation of an AST node.This method never returns. It is suitable to use as the argument of a
return
instruction.- Throws:
Reducer.Abort
- always
-