38 |
|
|
39 |
package org.omg.CORBA; |
package org.omg.CORBA; |
40 |
|
|
41 |
|
import gnu.CORBA.Minor; |
42 |
|
|
43 |
import java.io.Serializable; |
import java.io.Serializable; |
44 |
|
|
45 |
import org.omg.CORBA.portable.IDLEntity; |
import org.omg.CORBA.portable.IDLEntity; |
110 |
|
|
111 |
/** |
/** |
112 |
* Returns the CompletionStatus, matching the given integer constant |
* Returns the CompletionStatus, matching the given integer constant |
113 |
|
* |
114 |
* @param completion one of COMPLETED_YES, COMPLETED_NO or COMPLEED_MAYBE. |
* @param completion one of COMPLETED_YES, COMPLETED_NO or COMPLEED_MAYBE. |
115 |
* @return one of COMPLETED_YES, COMPLETED_NO or COMPLEED_MAYBE. |
* @return one of COMPLETED_YES, COMPLETED_NO or COMPLEED_MAYBE. |
116 |
* @throws BAD_PARAM if the parameter is not one of these three valid values. |
* @throws BAD_PARAM if the parameter is not one of these three valid values. |
119 |
{ |
{ |
120 |
try |
try |
121 |
{ |
{ |
122 |
return states [ completion ]; |
return states[completion]; |
123 |
} |
} |
124 |
catch (ArrayIndexOutOfBoundsException ex) |
catch (ArrayIndexOutOfBoundsException ex) |
125 |
{ |
{ |
126 |
throw new BAD_OPERATION("Invalid completion status " + completion); |
BAD_OPERATION bad = new BAD_OPERATION("Invalid completion status " |
127 |
|
+ completion); |
128 |
|
bad.minor = Minor.Enumeration; |
129 |
|
throw bad; |
130 |
} |
} |
131 |
} |
} |
132 |
|
|