/interpreter/tags/at2dist090708/test/edu/vub/at/objects/base/BaseClosure.java
Java | 26 lines | 7 code | 4 blank | 15 comment | 0 complexity | b069075821a08cded78e582815550037 MD5 | raw file
1/** 2 * 3 */ 4package edu.vub.at.objects.base; 5 6import edu.vub.at.exceptions.InterpreterException; 7import edu.vub.at.objects.ATObject; 8import edu.vub.at.objects.ATTable; 9 10/** 11 * A minimal interface to which a closure can be coerced such that it can be applied from another Java thread. 12 * 13 * @author smostinc 14 * 15 */ 16public interface BaseClosure { 17 18 /** 19 * Applies the closure to the given arguments, which are wrapped in a table. 20 * 21 * @param args the evaluated arguments. 22 * @return the value of evaluating the method body in the context of the closure. 23 */ 24 public ATObject apply(ATTable args) throws InterpreterException; 25 26}