KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > enhydra > shark > api > client > wfmodel > workflow_stateType


1 package org.enhydra.shark.api.client.wfmodel;
2
3 /**
4  * Used to describe sets of states of various workflow objects.
5  * An execution object is either in state ?open? (i.e., it is active)
6  * or in state ?closed? ( i.e., it has finished execution).
7  * <p>
8  * open - To reflect that the object is active and not finished.
9  * closed - Reflects that the object is finished and inactive.
10  */

11 public class workflow_stateType
12 {
13    private int __value;
14    private static int __size = 2;
15    private static workflow_stateType[] __array = new workflow_stateType [__size];
16
17    public static final int _open = 0;
18    public static final workflow_stateType open = new workflow_stateType(_open);
19    public static final int _closed = 1;
20    public static final workflow_stateType closed = new workflow_stateType(_closed);
21
22    public int value ()
23    {
24       return __value;
25    }
26
27    public static workflow_stateType from_int (int value)
28    {
29       if (value >= 0 && value < __size)
30          return __array[value];
31       else
32          throw new org.omg.CORBA.BAD_PARAM JavaDoc ();
33    }
34
35    protected workflow_stateType (int value)
36    {
37       __value = value;
38       __array[__value] = this;
39    }
40 } // class workflow_stateType
41
Popular Tags