01: package murlen.util.fscript;
02:
03: /**
04: * <p>FSArrayExtension - simple array extension to plug into FSFastExtension
05: * </p>
06: * <p>
07: * <I>Copyright (C) 2002 </I></p>
08: * <p>
09: * This library is free software; you can redistribute it and/or
10: * modify it under the terms of the GNU Library General Public
11: * License as published by the Free Software Foundation; either
12: * version 2 of the License, or (at your option) any later version.</p>
13: * <p>
14: * This library is distributed in the hope that it will be useful,
15: * but WITHOUT ANY WARRANTY; without even the implied warranty of
16: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
17: * Library General Public License for more details.</p>
18: *
19: * <p>You should have received a copy of the GNU Library General Public
20: * License along with this library; if not, write to the Free
21: * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA </p>
22: *
23: * @author Joachim Van der Auwera
24: *
25: * modifications by Joachim Van der Auwera
26: * 02.08.2002 started
27: */
28: public interface FSArrayExtension {
29:
30: /**
31: * <p>getVar is called whenever a variable is read in FScript that has
32: * not been defined within the script iteslf</p>
33: * <p> This version allows an index variable to be supplied for array like
34: * access</p>
35: * @param name the variable name
36: * @param index the index
37: * @return the value of the variable (as one of FScript's supported object
38: * types)
39: **/
40: public Object getVar(String name, Object index) throws FSException;
41:
42: /**
43: * <p>setVar is called whenever a variable is written to in FScript that has not
44: * been defined within the script itself</p>
45: * <p> This version allows an index variable to be supplied for array like
46: * access</p>
47: * @param name the variable name
48: * @param index the index
49: * @param value the value to assign to the variable
50: **/
51: public void setVar(String name, Object index, Object value)
52: throws FSException;
53: }
|