Toggle navigation
Home
org.apache.ignite.internal.util.lang.GridIterator to org.apache.ignite.internal.util.lang.GridCloseableIterator
No. of Instances - 2
No. of Commits - 2
No. of Projects - {'ignite'}
Hierarchy/Composition: SIBLING
Primitive Info: -
NameSpace: Internal -> Internal
Mapping:
Rename Variable
rowsIterator
to
cacheEntriesIterator
rowsIterator
to
cacheEntriesIterator
Cascading Type Change (Similar)
GridCloseableIteratorAdapter<CacheDataRow>
to
GridCloseableIteratorAdapter<Cache.Entry<K,V>>
Update Anonymous class
{ /** */ private GridCursor<? extends CacheDataRow> cur; /** */ private int curPart; /** */ private CacheDataRow next; @Override protected CacheDataRow onNext(){ CacheDataRow res=next; next=null; return res; } @Override protected boolean onHasNext() throws IgniteCheckedException { if (next != null) return true; while (true) { if (cur == null) { if (dataIt.hasNext()) { CacheDataStore ds=dataIt.next(); curPart=ds.partId(); cur=ds.cursor(); } else break; } if (cur.next()) { next=cur.get(); next.key().partition(curPart); break; } else cur=null; } return next != null; } }
to
{ /** */ private CacheEntryImplEx next; @Override protected Cache.Entry<K,V> onNext(){ CacheEntryImplEx ret=next; next=null; return ret; } @Override protected boolean onHasNext(){ if (next != null) return true; CacheDataRow nextRow=null; if (it.hasNext()) nextRow=it.next(); if (nextRow != null) { KeyCacheObject key=nextRow.key(); CacheObject val=nextRow.value(); Object key0=cctx.unwrapBinaryIfNeeded(key,keepBinary,false); Object val0=cctx.unwrapBinaryIfNeeded(val,keepBinary,false); next=new CacheEntryImplEx(key0,val0,nextRow.version()); return true; } return false; } }