1 package org.enhydra.shark.corba; 2 3 import org.omg.WfBase.*; 4 import org.omg.WorkflowModel.WfProcess; 5 import org.omg.WorkflowModel._WfProcessIteratorImplBase; 6 7 13 public class WfProcessIteratorCORBA extends _WfProcessIteratorImplBase { 14 15 org.enhydra.shark.api.client.wfmodel.WfProcessIterator myIterator; 16 17 private Collective __collective; 18 19 protected WfProcessIteratorCORBA(Collective toJoin, 20 org.enhydra.shark.api.client.wfmodel.WfProcessIterator iter) throws BaseException { 21 __collective = toJoin; 22 toJoin.__recruit(this); 23 this.myIterator = iter; 24 } 25 26 public String query_expression() throws BaseException { 27 try { 28 return myIterator.query_expression(); 29 } catch (Exception ex) { 30 throw new BaseException(); 31 } 32 } 33 34 40 public void set_query_expression(String query) throws BaseException, 41 InvalidQuery { 42 try { 43 myIterator.set_query_expression(query); 44 } catch (org.enhydra.shark.api.client.wfbase.InvalidQuery iq) { 45 throw new InvalidQuery(); 46 } catch (Exception ex) { 47 throw new BaseException(); 48 } 49 } 50 51 public NameValue[] names_in_expression() throws BaseException { 52 try { 53 return SharkCORBAUtilities.makeCORBANameValueArray(this._orb(), 54 myIterator.names_in_expression()); 55 } catch (Exception ex) { 56 throw new BaseException(); 57 } 58 } 59 60 public void set_names_in_expression(NameValue[] query) throws BaseException, 61 NameMismatch { 62 try { 63 myIterator.set_names_in_expression(SharkCORBAUtilities.makeMap(query)); 64 } catch (org.enhydra.shark.api.client.wfbase.NameMismatch nm) { 65 throw new NameMismatch(); 66 } catch (Exception ex) { 67 throw new BaseException(); 68 } 69 } 70 71 public String query_grammar() throws BaseException { 72 try { 73 return myIterator.query_grammar(); 74 } catch (Exception ex) { 75 throw new BaseException(); 76 } 77 } 78 79 public void set_query_grammar(String query_grammmar) throws BaseException, 80 GrammarNotSupported { 81 try { 82 myIterator.set_query_grammar(query_grammmar); 83 } catch (org.enhydra.shark.api.client.wfbase.GrammarNotSupported gns) { 84 throw new GrammarNotSupported(); 85 } catch (Exception ex) { 86 throw new BaseException(); 87 } 88 } 89 90 public int how_many() throws BaseException { 91 try { 92 return myIterator.how_many(); 93 } catch (Exception ex) { 94 throw new BaseException(); 95 } 96 } 97 98 public void goto_start() throws BaseException { 99 try { 100 myIterator.goto_start(); 101 } catch (Exception ex) { 102 throw new BaseException(); 103 } 104 } 105 106 public void goto_end() throws BaseException { 107 try { 108 myIterator.goto_end(); 109 } catch (Exception ex) { 110 throw new BaseException(); 111 } 112 } 113 114 public WfProcess get_next_object() throws BaseException { 115 try { 116 return new WfProcessCORBA(__collective, myIterator.get_next_object()); 117 } catch (Exception ex) { 118 throw new BaseException(); 119 } 120 } 121 122 public WfProcess get_previous_object() throws BaseException { 123 try { 124 return new WfProcessCORBA(__collective, 125 myIterator.get_previous_object()); 126 } catch (Exception ex) { 127 throw new BaseException(); 128 } 129 } 130 131 public WfProcess[] get_next_n_sequence(int max_number) throws BaseException { 132 try { 133 return SharkCORBAUtilities.makeCORBAProcesses(__collective, 134 myIterator.get_next_n_sequence(max_number)); 135 } catch (Exception ex) { 136 throw new BaseException(); 137 } 138 } 139 140 public WfProcess[] get_previous_n_sequence(int max_number) throws BaseException { 141 try { 142 return SharkCORBAUtilities.makeCORBAProcesses(__collective, 143 myIterator.get_previous_n_sequence(max_number)); 144 } catch (Exception ex) { 145 throw new BaseException(); 146 } 147 } 148 149 } | Popular Tags |