[Mulgara-svn] r1570 - in branches/mgr-183-project/src/jar/resolver-store/java/org/mulgara/store/statement: xa xa11
andrae at mulgara.org
andrae at mulgara.org
Mon Mar 2 08:11:24 UTC 2009
Author: andrae
Date: 2009-03-02 00:11:23 -0800 (Mon, 02 Mar 2009)
New Revision: 1570
Modified:
branches/mgr-183-project/src/jar/resolver-store/java/org/mulgara/store/statement/xa/TripleAVLFileUnitTest.java
branches/mgr-183-project/src/jar/resolver-store/java/org/mulgara/store/statement/xa11/XA11StatementStoreImpl.java
Log:
refs #183
Missed updating unit-test to reflect new constructor signatures.
Updated XA11 to reflect new constructor signatures.
Modified: branches/mgr-183-project/src/jar/resolver-store/java/org/mulgara/store/statement/xa/TripleAVLFileUnitTest.java
===================================================================
--- branches/mgr-183-project/src/jar/resolver-store/java/org/mulgara/store/statement/xa/TripleAVLFileUnitTest.java 2009-03-02 06:48:40 UTC (rev 1569)
+++ branches/mgr-183-project/src/jar/resolver-store/java/org/mulgara/store/statement/xa/TripleAVLFileUnitTest.java 2009-03-02 08:11:23 UTC (rev 1570)
@@ -165,10 +165,10 @@
* @throws Exception EXCEPTION TO DO
*/
public void testInsert() throws Exception {
- TripleAVLFile.Phase phase0 = tripleAVLFile.new Phase();
+ TripleAVLFile.Phase phase0 = tripleAVLFile.new Phase(0);
tripleAVLFile.clear();
TripleAVLFile.Phase.Token token0 = phase0.use();
- TripleAVLFile.Phase phase1 = tripleAVLFile.new Phase();
+ TripleAVLFile.Phase phase1 = tripleAVLFile.new Phase(1);
phase1.addTriple(1, 2, 3, 1);
phase1.addTriple(1, 2, 4, 2);
@@ -186,10 +186,10 @@
* @throws Exception EXCEPTION TO DO
*/
public void testContains() throws Exception {
- TripleAVLFile.Phase phase0 = tripleAVLFile.new Phase();
+ TripleAVLFile.Phase phase0 = tripleAVLFile.new Phase(0);
tripleAVLFile.clear();
TripleAVLFile.Phase.Token token0 = phase0.use();
- TripleAVLFile.Phase phase1 = tripleAVLFile.new Phase();
+ TripleAVLFile.Phase phase1 = tripleAVLFile.new Phase(1);
assertTrue("Found node in empty tree", !phase1.existsTriple(1, 2, 4, 2));
@@ -210,10 +210,10 @@
* @throws Exception EXCEPTION TO DO
*/
public void testRemove() throws Exception {
- TripleAVLFile.Phase phase0 = tripleAVLFile.new Phase();
+ TripleAVLFile.Phase phase0 = tripleAVLFile.new Phase(0);
tripleAVLFile.clear();
TripleAVLFile.Phase.Token token0 = phase0.use();
- TripleAVLFile.Phase phase1 = tripleAVLFile.new Phase();
+ TripleAVLFile.Phase phase1 = tripleAVLFile.new Phase(1);
phase1.addTriple(1, 2, 3, 1);
phase1.addTriple(1, 2, 4, 2);
@@ -260,10 +260,10 @@
* @throws Exception EXCEPTION TO DO
*/
public void testReinsert() throws Exception {
- TripleAVLFile.Phase phase0 = tripleAVLFile.new Phase();
+ TripleAVLFile.Phase phase0 = tripleAVLFile.new Phase(0);
tripleAVLFile.clear();
TripleAVLFile.Phase.Token token0 = phase0.use();
- TripleAVLFile.Phase phase1 = tripleAVLFile.new Phase();
+ TripleAVLFile.Phase phase1 = tripleAVLFile.new Phase(1);
phase1.addTriple(1, 2, 3, 1);
phase1.addTriple(1, 2, 4, 2);
@@ -300,9 +300,9 @@
* @throws Exception EXCEPTION TO DO
*/
public void testPersist() throws Exception {
- TripleAVLFile.Phase phase0 = tripleAVLFile.new Phase(metaroot, 0);
+ TripleAVLFile.Phase phase0 = tripleAVLFile.new Phase(0, metaroot, 0);
TripleAVLFile.Phase.Token token0 = phase0.use();
- TripleAVLFile.Phase phase1 = tripleAVLFile.new Phase();
+ TripleAVLFile.Phase phase1 = tripleAVLFile.new Phase(1);
assertTrue(phase1.existsTriple(1, 2, 3, 1));
assertTrue(phase1.existsTriple(1, 2, 4, 2));
@@ -320,10 +320,10 @@
* @throws Exception EXCEPTION TO DO
*/
public void testMultiphase() throws Exception {
- TripleAVLFile.Phase phase0 = tripleAVLFile.new Phase();
+ TripleAVLFile.Phase phase0 = tripleAVLFile.new Phase(0);
tripleAVLFile.clear();
TripleAVLFile.Phase.Token token0 = phase0.use();
- TripleAVLFile.Phase phase1 = tripleAVLFile.new Phase();
+ TripleAVLFile.Phase phase1 = tripleAVLFile.new Phase(1);
phase1.addTriple(1, 2, 3, 1);
phase1.addTriple(1, 2, 4, 2);
@@ -336,7 +336,7 @@
assertTrue(phase1.existsTriple(3, 2, 3, 4));
TripleAVLFile.Phase.Token token1 = phase1.use();
- TripleAVLFile.Phase phase2 = tripleAVLFile.new Phase();
+ TripleAVLFile.Phase phase2 = tripleAVLFile.new Phase(2);
phase2.removeTriple(1, 2, 3, 1);
assertTrue(!phase2.existsTriple(1, 2, 3, 1));
@@ -381,10 +381,10 @@
* @throws Exception EXCEPTION TO DO
*/
public void testFindTuples() throws Exception {
- TripleAVLFile.Phase phase0 = tripleAVLFile.new Phase();
+ TripleAVLFile.Phase phase0 = tripleAVLFile.new Phase(0);
tripleAVLFile.clear();
TripleAVLFile.Phase.Token token0 = phase0.use();
- TripleAVLFile.Phase phase1 = tripleAVLFile.new Phase();
+ TripleAVLFile.Phase phase1 = tripleAVLFile.new Phase(1);
phase1.addTriple(1, 2, 3, 1);
phase1.addTriple(1, 2, 4, 2);
@@ -405,10 +405,10 @@
* @throws Exception EXCEPTION TO DO
*/
public void testTuplesContent() throws Exception {
- TripleAVLFile.Phase phase0 = tripleAVLFile.new Phase();
+ TripleAVLFile.Phase phase0 = tripleAVLFile.new Phase(0);
tripleAVLFile.clear();
TripleAVLFile.Phase.Token token0 = phase0.use();
- TripleAVLFile.Phase phase1 = tripleAVLFile.new Phase();
+ TripleAVLFile.Phase phase1 = tripleAVLFile.new Phase(1);
phase1.addTriple(1, 2, 3, 1);
phase1.addTriple(1, 2, 4, 2);
@@ -450,10 +450,10 @@
* @throws Exception EXCEPTION TO DO
*/
public void testLargeTuplesContent() throws Exception {
- TripleAVLFile.Phase phase0 = tripleAVLFile.new Phase();
+ TripleAVLFile.Phase phase0 = tripleAVLFile.new Phase(0);
tripleAVLFile.clear();
TripleAVLFile.Phase.Token token0 = phase0.use();
- TripleAVLFile.Phase phase1 = tripleAVLFile.new Phase();
+ TripleAVLFile.Phase phase1 = tripleAVLFile.new Phase(1);
for (int i = 1; i < 5; i++) {
for (int j = 1; j <= 500; j++) {
@@ -487,10 +487,10 @@
* @throws Exception EXCEPTION TO DO
*/
public void testPrefix() throws Exception {
- TripleAVLFile.Phase phase0 = tripleAVLFile.new Phase();
+ TripleAVLFile.Phase phase0 = tripleAVLFile.new Phase(0);
tripleAVLFile.clear();
TripleAVLFile.Phase.Token token0 = phase0.use();
- TripleAVLFile.Phase phase1 = tripleAVLFile.new Phase();
+ TripleAVLFile.Phase phase1 = tripleAVLFile.new Phase(1);
phase1.addTriple(1, 2, 3, 1);
phase1.addTriple(1, 2, 4, 2);
Modified: branches/mgr-183-project/src/jar/resolver-store/java/org/mulgara/store/statement/xa11/XA11StatementStoreImpl.java
===================================================================
--- branches/mgr-183-project/src/jar/resolver-store/java/org/mulgara/store/statement/xa11/XA11StatementStoreImpl.java 2009-03-02 06:48:40 UTC (rev 1569)
+++ branches/mgr-183-project/src/jar/resolver-store/java/org/mulgara/store/statement/xa11/XA11StatementStoreImpl.java 2009-03-02 08:11:23 UTC (rev 1570)
@@ -1200,7 +1200,7 @@
* @throws IOException Error on the filesystem.
*/
Phase() throws IOException {
- for (int i = 0; i < NR_INDEXES; ++i) tripleAVLFilePhases[i] = tripleAVLFiles[i].new Phase();
+ for (int i = 0; i < NR_INDEXES; ++i) tripleAVLFilePhases[i] = tripleAVLFiles[i].new Phase(i);
currentPhase = this;
dirty = true;
try {
@@ -1234,7 +1234,7 @@
*/
Phase(Block b, int offset) throws IOException {
for (int i = 0; i < NR_INDEXES; ++i) {
- tripleAVLFilePhases[i] = tripleAVLFiles[i].new Phase(b, offset);
+ tripleAVLFilePhases[i] = tripleAVLFiles[i].new Phase(i, b, offset);
offset += TripleAVLFile.Phase.RECORD_SIZE;
}
currentPhase = this;
More information about the Mulgara-svn
mailing list