Skip to content

Commit 736cb3c

Browse files
committed
ST6RI-913 Implemented EOperandList.iterator to return an empty iterator.
1 parent b2c66a5 commit 736cb3c

1 file changed

Lines changed: 29 additions & 14 deletions

File tree

org.omg.sysml/src/org/omg/sysml/util/OperandEList.java

Lines changed: 29 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
package org.omg.sysml.util;
2323

2424
import java.util.Collection;
25+
import java.util.Collections;
2526
import java.util.Iterator;
2627
import java.util.List;
2728
import java.util.ListIterator;
@@ -176,43 +177,53 @@ public boolean contains(Object o) {
176177

177178
@Override
178179
public Iterator<Expression> iterator() {
179-
throw new UnsupportedOperationException(); }
180+
return Collections.emptyIterator();
181+
}
180182

181183
@Override
182184
public Object[] toArray() {
183-
throw new UnsupportedOperationException(); }
185+
throw new UnsupportedOperationException();
186+
}
184187

185188
@Override
186189
public <T> T[] toArray(T[] a) {
187-
throw new UnsupportedOperationException(); }
190+
throw new UnsupportedOperationException();
191+
}
188192

189193
@Override
190194
public boolean add(Expression e) {
191-
throw new UnsupportedOperationException(); }
195+
throw new UnsupportedOperationException();
196+
}
192197

193198
@Override
194199
public boolean containsAll(Collection<?> c) {
195-
throw new UnsupportedOperationException(); }
200+
throw new UnsupportedOperationException();
201+
}
196202

197203
@Override
198204
public boolean addAll(Collection<? extends Expression> c) {
199-
throw new UnsupportedOperationException(); }
205+
throw new UnsupportedOperationException();
206+
}
200207

201208
@Override
202209
public boolean addAll(int index, Collection<? extends Expression> c) {
203-
throw new UnsupportedOperationException(); }
210+
throw new UnsupportedOperationException();
211+
}
204212

205213
@Override
206214
public boolean removeAll(Collection<?> c) {
207-
throw new UnsupportedOperationException(); }
215+
throw new UnsupportedOperationException();
216+
}
208217

209218
@Override
210219
public boolean retainAll(Collection<?> c) {
211-
throw new UnsupportedOperationException(); }
220+
throw new UnsupportedOperationException();
221+
}
212222

213223
@Override
214224
public Expression set(int index, Expression element) {
215-
throw new UnsupportedOperationException(); }
225+
throw new UnsupportedOperationException();
226+
}
216227

217228
@Override
218229
public void add(int index, Expression element) {
@@ -231,17 +242,21 @@ public int lastIndexOf(Object o) {
231242

232243
@Override
233244
public ListIterator<Expression> listIterator() {
234-
throw new UnsupportedOperationException(); }
245+
throw new UnsupportedOperationException();
246+
}
235247

236248
@Override
237249
public ListIterator<Expression> listIterator(int index) {
238-
throw new UnsupportedOperationException(); }
250+
throw new UnsupportedOperationException();
251+
}
239252

240253
@Override
241254
public List<Expression> subList(int fromIndex, int toIndex) {
242-
throw new UnsupportedOperationException(); }
255+
throw new UnsupportedOperationException();
256+
}
243257

244258
@Override
245259
public Expression basicGet(int index) {
246-
throw new UnsupportedOperationException(); }
260+
throw new UnsupportedOperationException();
261+
}
247262
}

0 commit comments

Comments
 (0)