Skip to content

Distributed Peer-to-Peer Web Search Engine and Intranet Search Appliance

refactoring/better naming of methods and classes

orbiter75df87832cb0
diff --git a/source/net/yacy/kelondro/rwi/IndexCell.java b/source/net/yacy/kelondro/rwi/IndexCell.java
index b763b19c3..349133d5d 100644
--- a/source/net/yacy/kelondro/rwi/IndexCell.java
+++ b/source/net/yacy/kelondro/rwi/IndexCell.java
@@ -457,7 +457,7 @@ public final class IndexCell<ReferenceType extends Reference> extends AbstractBu
this.ram.references(starttermHash, rot),
new MergeIterator<ReferenceContainer<ReferenceType>>(
this.ram.references(starttermHash, false),
- this.array.wordContainerIterator(starttermHash, false),
+ this.array.referenceContainerIterator(starttermHash, false),
containerOrder,
ReferenceContainer.containerMergeMethod,
true),
@@ -474,7 +474,7 @@ public final class IndexCell<ReferenceType extends Reference> extends AbstractBu
}
return new MergeIterator<ReferenceContainer<ReferenceType>>(
this.ram.references(startTermHash, false),
- this.array.wordContainerIterator(startTermHash, false),
+ this.array.referenceContainerIterator(startTermHash, false),
containerOrder,
ReferenceContainer.containerMergeMethod,
true);
diff --git a/source/net/yacy/kelondro/rwi/ReferenceContainerArray.java b/source/net/yacy/kelondro/rwi/ReferenceContainerArray.java
index 13f8c12c0..9f12e5112 100644
--- a/source/net/yacy/kelondro/rwi/ReferenceContainerArray.java
+++ b/source/net/yacy/kelondro/rwi/ReferenceContainerArray.java
@@ -113,20 +113,16 @@ public final class ReferenceContainerArray<ReferenceType extends Reference> {
* objects in the cache.
* @throws IOException
*/
- public CloneableIterator<ReferenceContainer<ReferenceType>> wordContainerIterator(final byte[] startWordHash, final boolean rot) {
+ public CloneableIterator<ReferenceContainer<ReferenceType>> referenceContainerIterator(final byte[] startWordHash, final boolean rot) {
try {
- return new heapCacheIterator(startWordHash, rot);
+ return new ReferenceContainerIterator(startWordHash, rot);
} catch (IOException e) {
Log.logException(e);
return null;
}
}
- /**
- * cache iterator: iterates objects within the heap cache. This can only be used
- * for write-enabled heaps, read-only heaps do not have a heap cache
- */
- public class heapCacheIterator implements CloneableIterator<ReferenceContainer<ReferenceType>>, Iterable<ReferenceContainer<ReferenceType>> {
+ public class ReferenceContainerIterator implements CloneableIterator<ReferenceContainer<ReferenceType>>, Iterable<ReferenceContainer<ReferenceType>> {
// this class exists, because the wCache cannot be iterated with rotation
// and because every indexContainer Object that is iterated must be returned as top-level-clone
@@ -136,15 +132,15 @@ public final class ReferenceContainerArray<ReferenceType extends Reference> {
private final boolean rot;
protected CloneableIterator<byte[]> iterator;
- public heapCacheIterator(final byte[] startWordHash, final boolean rot) throws IOException {
+ public ReferenceContainerIterator(final byte[] startWordHash, final boolean rot) throws IOException {
this.rot = rot;
this.iterator = array.keys(true, startWordHash);
// The collection's iterator will return the values in the order that their corresponding keys appear in the tree.
}
- public heapCacheIterator clone(final Object secondWordHash) {
+ public ReferenceContainerIterator clone(final Object secondWordHash) {
try {
- return new heapCacheIterator((byte[]) secondWordHash, rot);
+ return new ReferenceContainerIterator((byte[]) secondWordHash, rot);
} catch (IOException e) {
Log.logException(e);
return null;