01: /*
02: * Copyright (C) 2004 TiongHiang Lee
03: *
04: * This library is free software; you can redistribute it and/or
05: * modify it under the terms of the GNU Lesser General Public
06: * License as published by the Free Software Foundation; either
07: * version 2.1 of the License, or (at your option) any later version.
08: *
09: * This library is distributed in the hope that it will be useful,
10: * but WITHOUT ANY WARRANTY; without even the implied warranty of
11: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12: * Lesser General Public License for more details.
13: *
14: * You should have received a copy of the GNU Lesser General Public
15: * License along with this library; if not, write to the Free Software
16: * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17: *
18: * Email: thlee@onemindsoft.org
19: */
20:
21: package org.onemind.jxp;
22:
23: /**
24: * Represent a control object in the script language
25: * @author TiongHiang Lee (thlee@onemindsoft.org)
26: *
27: */
28: public class Control {
29:
30: /** reference to an object * */
31: private Object _obj;
32:
33: /** the break control * */
34: public static final Control BREAK = new Control();
35:
36: /** the continue control * */
37: public static final Control CONTINUE = new Control();
38:
39: /** the return control * */
40: public static final Control RETURN = new Control();
41:
42: /** the exit **/
43: public static final Control EXIT = new Control();
44:
45: /**
46: * {@inheritDoc}
47: */
48: private Control() {
49: }
50:
51: /**
52: * {@inheritDoc}
53: * @param obj an object
54: */
55: public Control(Object obj) {
56: _obj = obj;
57: }
58:
59: /**
60: * Get the object
61: * @return the object
62: */
63: public Object getObject() {
64: return _obj;
65: }
66: }
|