Пример #1
0
 @Override
 public T next() {
   if (next == null) {
     throw new NoSuchElementException();
   }
   current = next;
   index++;
   next = enumerator.nextObject();
   return current;
 }
Пример #2
0
 @Callback
 @BindSelector("allObjects")
 public static NSArray allObjects(NSEnumerator __self__, Selector __cmd__) {
   return __self__.allObjects();
 }
Пример #3
0
 Iterator(NSEnumerator<T> enumerator) {
   this.enumerator = enumerator;
   index = -1;
   current = null;
   next = enumerator.nextObject();
 }
Пример #4
0
 @Callback
 @BindSelector("nextObject")
 public static NSObject _nextObject(NSEnumerator __self__, Selector __cmd__) {
   return __self__._nextObject();
 }