[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Gzz-commits] gzz/lava/gzz/storm IndexedPool.java PointerBloc...
From: |
Benja Fallenstein |
Subject: |
[Gzz-commits] gzz/lava/gzz/storm IndexedPool.java PointerBloc... |
Date: |
Sat, 16 Nov 2002 09:19:03 -0500 |
CVSROOT: /cvsroot/gzz
Module name: gzz
Changes by: Benja Fallenstein <address@hidden> 02/11/16 09:19:01
Modified files:
lava/gzz/storm : IndexedPool.java PointerBlock.java
Log message:
Thinking about a more general index interface for Storm
CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/lava/gzz/storm/IndexedPool.java.diff?tr1=1.1&tr2=1.2&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/gzz/gzz/lava/gzz/storm/PointerBlock.java.diff?tr1=1.2&tr2=1.3&r1=text&r2=text
Patches:
Index: gzz/lava/gzz/storm/IndexedPool.java
diff -u gzz/lava/gzz/storm/IndexedPool.java:1.1
gzz/lava/gzz/storm/IndexedPool.java:1.2
--- gzz/lava/gzz/storm/IndexedPool.java:1.1 Sat Aug 24 12:51:36 2002
+++ gzz/lava/gzz/storm/IndexedPool.java Sat Nov 16 09:19:00 2002
@@ -32,6 +32,29 @@
* should generally support.
*/
public interface IndexedPool extends StormPool {
+
+ interface Index {}
+
+ interface Indexer {
+ void add(Block b);
+ void remove(Block b);
+ }
+
+ interface IndexType {
+ final class Result {
+ Index index;
+ Indexer indexer;
+
+ public Result(Index index, Indexer indexer) {
+ this.index = index; this.indexer = indexer;
+ }
+ }
+
+ Result create();
+ }
+
+ Index getIndex(IndexType type);
+
/** Get a <code>Pointer</code> instance for a given pointer id.
* The <code>Pointer</code> instance provides information about the
* history of the given pointer inside this pool (what it currently
@@ -41,7 +64,7 @@
* see <code>Pointer</code> javadoc.
* @see Pointer
*/
- Pointer getPointer(String id) throws IOException;
+ //Pointer getPointer(String id) throws IOException;
/** Get a set of <code>BlockId</code>s of diffs
* which are diffs <em>from</em> the version identified
@@ -49,7 +72,7 @@
* diffs are recognized by the
* <code>X-Gzz-Diff-From</code> header.
*/
- Set getDiffsFrom(BlockId id) throws IOException;
+ //Set getDiffsFrom(BlockId id) throws IOException;
/** Get a set of <code>BlockId</code>s of diffs
* which are diffs <em>from</em> the version identified
@@ -57,5 +80,5 @@
* diffs are recognized by the
* <code>X-Gzz-Diff-To</code> header.
*/
- Set getDiffsTo(BlockId id) throws IOException;
+ //Set getDiffsTo(BlockId id) throws IOException;
}
Index: gzz/lava/gzz/storm/PointerBlock.java
diff -u gzz/lava/gzz/storm/PointerBlock.java:1.2
gzz/lava/gzz/storm/PointerBlock.java:1.3
--- gzz/lava/gzz/storm/PointerBlock.java:1.2 Fri Aug 30 12:48:38 2002
+++ gzz/lava/gzz/storm/PointerBlock.java Sat Nov 16 09:19:00 2002
@@ -28,6 +28,11 @@
Pointer getPointer() throws IOException;
BlockId getTarget() throws IOException;
+ /** Get the <code>Block</code> object for the pointer block
+ * represented by this object.
+ */
+ Block getBlock();
+
/** Get the <em>ids</em> of all pointer blocks obsoleted by this one.
* This returns a set of <code>BlockId</code> objects, not of
* <code>PointerBlock</code> objects, because we aren't always able
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Gzz-commits] gzz/lava/gzz/storm IndexedPool.java PointerBloc...,
Benja Fallenstein <=