01: /*
02: * JOnAS: Java(TM) Open Application Server
03: * Copyright (C) 1999 Bull S.A.
04: * Contact: jonas-team@objectweb.org
05: *
06: * This library is free software; you can redistribute it and/or
07: * modify it under the terms of the GNU Lesser General Public
08: * License as published by the Free Software Foundation; either
09: * version 2.1 of the License, or any later version.
10: *
11: * This library is distributed in the hope that it will be useful,
12: * but WITHOUT ANY WARRANTY; without even the implied warranty of
13: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14: * Lesser General Public License for more details.
15: *
16: * You should have received a copy of the GNU Lesser General Public
17: * License along with this library; if not, write to the Free Software
18: * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
19: * USA
20: *
21: * --------------------------------------------------------------------------
22: * $Id: Simple.java 8456 2006-06-13 08:28:03Z durieuxp $
23: * --------------------------------------------------------------------------
24: */
25:
26: // Simple.java
27: package org.objectweb.jonas.jtests.beans.transacted;
28:
29: import java.rmi.RemoteException;
30: import javax.ejb.EJBObject;
31: import javax.ejb.TimerHandle;
32:
33: /**
34: * This interface is implemented by different types of beans (EB,SL)
35: */
36: public interface Simple extends EJBObject {
37: // every method returns true if called inside a tx, false if not.
38: public boolean opwith_notsupported() throws RemoteException;// TX_NOT_SUPPORTED
39:
40: public boolean opwith_requires_new() throws RemoteException;// TX_REQUIRES_NEW
41:
42: public boolean opwith_required() throws RemoteException; // TX_REQUIRED
43:
44: public boolean opwith_mandatory() throws RemoteException; // TX_MANDATORY
45:
46: public boolean opwith_supports() throws RemoteException; // TX_SUPPORTS
47:
48: public boolean supports_call_required() throws RemoteException; // TX_SUPPORTS
49:
50: public boolean opwith_never() throws RemoteException; // TX_NEVER
51:
52: public boolean required_call_requires_new() throws RemoteException; // TX_REQUIRED
53:
54: public boolean call_requires_new_on(Simple other)
55: throws RemoteException; // TX_REQUIRED
56:
57: public int setTimer(int dur, int period) throws RemoteException;
58:
59: public int setTimer(java.util.Date date, int period)
60: throws RemoteException;
61:
62: public int setTimerGetHandle(int dur, int period)
63: throws RemoteException;
64:
65: public void cancelTimer(int id) throws RemoteException;
66:
67: public void cancelTimers() throws RemoteException;
68:
69: public long getTimeRemaining(int id) throws RemoteException;
70:
71: public int getTimerCount() throws RemoteException;
72:
73: public int getTimerNumber() throws RemoteException;
74:
75: public TimerHandle getTimerHandle(int id) throws RemoteException;
76:
77: public void startInfoTimer(int dur, String inform)
78: throws RemoteException; // TX_REQUIRED
79: }
|