aboutsummaryrefslogtreecommitdiffstats
path: root/subprojects/viatra-runtime-rete/src/main/java/tools/refinery/viatra/runtime/rete/network/mailbox/FallThroughCapableMailbox.java
blob: 8797e254a17b8254f6605ec46afee4d070bd3aaa (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
/*******************************************************************************
 * Copyright (c) 2010-2019, Tamas Szabo, Istvan Rath and Daniel Varro
 * This program and the accompanying materials are made available under the
 * terms of the Eclipse Public License v. 2.0 which is available at
 * http://www.eclipse.org/legal/epl-v20.html.
 * 
 * SPDX-License-Identifier: EPL-2.0
 *******************************************************************************/
package tools.refinery.viatra.runtime.rete.network.mailbox;

import tools.refinery.viatra.runtime.rete.network.Receiver;
import tools.refinery.viatra.runtime.rete.network.communication.CommunicationTracker;

/**
 * A fall through capable mailbox can directly call the update method of its {@link Receiver} instead of using the
 * standard post-deliver mailbox semantics. If the fall through flag is set to true, the mailbox uses direct delivery,
 * otherwise it operates in the original behavior. The fall through operation is preferable whenever applicable because
 * it improves performance. The fall through flag is controlled by the {@link CommunicationTracker} based on the
 * receiver node type and network topology.
 * 
 * @author Tamas Szabo
 * @since 2.2
 */
public interface FallThroughCapableMailbox extends Mailbox {

    public boolean isFallThrough();

    public void setFallThrough(final boolean fallThrough);

}