KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > tctest > restart > RestartTestApp


1 /*
2  * All content copyright (c) 2003-2006 Terracotta, Inc., except as may otherwise be noted in a separate copyright notice. All rights reserved.
3  */

4 package com.tctest.restart;
5
6 import EDU.oswego.cs.dl.util.concurrent.CyclicBarrier;
7 import EDU.oswego.cs.dl.util.concurrent.FutureResult;
8
9 public interface RestartTestApp {
10
11   public void setStartBarrier(CyclicBarrier startBarrier);
12   
13   public void setID(int id);
14
15   public int getID();
16
17   /**
18    * Initial, unstarted state
19    */

20   public boolean isInit();
21
22   /**
23    * The app has started
24    */

25   public boolean isStart();
26
27   /**
28    * The app has acquired the lock
29    */

30   public boolean isHolder();
31
32   /**
33    * The app is waiting on the lock
34    */

35   public boolean isWaiter();
36   
37   /**
38    * The app is in the end state.
39    */

40   public boolean isEnd();
41
42   /**
43    * Resets the app to the INIT state.
44    */

45   public void reset();
46
47   public String JavaDoc getStateName();
48
49   public void blockShutdown(FutureResult blocker) throws Exception JavaDoc;
50
51 }
52
Popular Tags