diff options
Diffstat (limited to 'subprojects/viatra-runtime-rete/src/main/java/tools/refinery/viatra/runtime/rete/single/TransparentNode.java')
-rw-r--r-- | subprojects/viatra-runtime-rete/src/main/java/tools/refinery/viatra/runtime/rete/single/TransparentNode.java | 48 |
1 files changed, 48 insertions, 0 deletions
diff --git a/subprojects/viatra-runtime-rete/src/main/java/tools/refinery/viatra/runtime/rete/single/TransparentNode.java b/subprojects/viatra-runtime-rete/src/main/java/tools/refinery/viatra/runtime/rete/single/TransparentNode.java new file mode 100644 index 00000000..6c21a966 --- /dev/null +++ b/subprojects/viatra-runtime-rete/src/main/java/tools/refinery/viatra/runtime/rete/single/TransparentNode.java | |||
@@ -0,0 +1,48 @@ | |||
1 | /******************************************************************************* | ||
2 | * Copyright (c) 2004-2008 Gabor Bergmann and Daniel Varro | ||
3 | * This program and the accompanying materials are made available under the | ||
4 | * terms of the Eclipse Public License v. 2.0 which is available at | ||
5 | * http://www.eclipse.org/legal/epl-v20.html. | ||
6 | * | ||
7 | * SPDX-License-Identifier: EPL-2.0 | ||
8 | *******************************************************************************/ | ||
9 | |||
10 | package tools.refinery.viatra.runtime.rete.single; | ||
11 | |||
12 | import java.util.Collection; | ||
13 | import java.util.Map; | ||
14 | |||
15 | import tools.refinery.viatra.runtime.matchers.tuple.Tuple; | ||
16 | import tools.refinery.viatra.runtime.matchers.util.Direction; | ||
17 | import tools.refinery.viatra.runtime.matchers.util.timeline.Timeline; | ||
18 | import tools.refinery.viatra.runtime.rete.network.ReteContainer; | ||
19 | import tools.refinery.viatra.runtime.rete.network.communication.Timestamp; | ||
20 | |||
21 | /** | ||
22 | * Simply propagates everything. Might be used to join or fork. | ||
23 | * | ||
24 | * @author Gabor Bergmann | ||
25 | */ | ||
26 | public class TransparentNode extends SingleInputNode { | ||
27 | |||
28 | public TransparentNode(final ReteContainer reteContainer) { | ||
29 | super(reteContainer); | ||
30 | } | ||
31 | |||
32 | @Override | ||
33 | public void update(final Direction direction, final Tuple updateElement, final Timestamp timestamp) { | ||
34 | propagateUpdate(direction, updateElement, timestamp); | ||
35 | |||
36 | } | ||
37 | |||
38 | @Override | ||
39 | public void pullInto(final Collection<Tuple> collector, final boolean flush) { | ||
40 | propagatePullInto(collector, flush); | ||
41 | } | ||
42 | |||
43 | @Override | ||
44 | public void pullIntoWithTimeline(final Map<Tuple, Timeline<Timestamp>> collector, final boolean flush) { | ||
45 | propagatePullIntoWithTimestamp(collector, flush); | ||
46 | } | ||
47 | |||
48 | } | ||