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