Update of /cvsroot/cweb/bigdata/src/test/com/bigdata/objndx
In directory sc8-pr-cvs4.sourceforge.net:/tmp/cvs-serv2548/src/test/com/bigdata/objndx
Modified Files:
TestKeyBufferSerializer.java TestByteArrayValueSerializer.java
SimpleEntry.java
Log Message:
Added a Sesame 1.x SAIL implementation. This is NOT intended for production use. It is just being done to gain a high-level query language integration for the triple store.
Index: TestByteArrayValueSerializer.java
===================================================================
RCS file: /cvsroot/cweb/bigdata/src/test/com/bigdata/objndx/TestByteArrayValueSerializer.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** TestByteArrayValueSerializer.java 15 Feb 2007 01:34:23 -0000 1.1
--- TestByteArrayValueSerializer.java 12 Apr 2007 23:59:34 -0000 1.2
***************
*** 167,179 ****
final byte[] data;
{
! ByteArrayOutputStream baos = new ByteArrayOutputStream();
!
! DataOutputStream dos = new DataOutputStream(baos);
ser.putValues(dos, values, values.length);
! dos.flush();
! data = baos.toByteArray();
}
--- 167,181 ----
final byte[] data;
{
! // ByteArrayOutputStream baos = new ByteArrayOutputStream();
! //
! // DataOutputStream dos = new DataOutputStream(baos);
!
! DataOutputBuffer dos = new DataOutputBuffer();
ser.putValues(dos, values, values.length);
! // dos.flush();
! data = dos.buf;
}
Index: SimpleEntry.java
===================================================================
RCS file: /cvsroot/cweb/bigdata/src/test/com/bigdata/objndx/SimpleEntry.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -d -r1.9 -r1.10
*** SimpleEntry.java 13 Feb 2007 23:01:10 -0000 1.9
--- SimpleEntry.java 12 Apr 2007 23:59:34 -0000 1.10
***************
*** 47,51 ****
--- 47,53 ----
package com.bigdata.objndx;
+ import java.io.DataInput;
import java.io.DataInputStream;
+ import java.io.DataOutput;
import java.io.DataOutputStream;
import java.io.IOException;
***************
*** 119,123 ****
public Serializer() {}
! public void putValues(DataOutputStream os, Object[] values, int n)
throws IOException {
--- 121,125 ----
public Serializer() {}
! public void putValues(DataOutputBuffer os, Object[] values, int n)
throws IOException {
***************
*** 130,134 ****
}
! public void getValues(DataInputStream is, Object[] values, int n)
throws IOException {
--- 132,136 ----
}
! public void getValues(DataInput is, Object[] values, int n)
throws IOException {
***************
*** 162,166 ****
public NoSerializer() {}
! public void getValues(DataInputStream is, Object[] values, int n) throws IOException {
throw new UnsupportedOperationException();
--- 164,168 ----
public NoSerializer() {}
! public void getValues(DataInput is, Object[] values, int n) throws IOException {
throw new UnsupportedOperationException();
***************
*** 168,172 ****
}
! public void putValues(DataOutputStream os, Object[] values, int n) throws IOException {
throw new UnsupportedOperationException();
--- 170,174 ----
}
! public void putValues(DataOutputBuffer os, Object[] values, int n) throws IOException {
throw new UnsupportedOperationException();
Index: TestKeyBufferSerializer.java
===================================================================
RCS file: /cvsroot/cweb/bigdata/src/test/com/bigdata/objndx/TestKeyBufferSerializer.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -d -r1.1 -r1.2
*** TestKeyBufferSerializer.java 26 Jan 2007 02:39:25 -0000 1.1
--- TestKeyBufferSerializer.java 12 Apr 2007 23:59:34 -0000 1.2
***************
*** 123,137 ****
// serialize.
! ByteArrayOutputStream baos = new ByteArrayOutputStream();
!
! DataOutputStream dos = new DataOutputStream(baos);
KeyBufferSerializer.INSTANCE.putKeys(dos, expected);
! dos.flush();
// de-serialize.
! ByteArrayInputStream bais = new ByteArrayInputStream(baos.toByteArray());
DataInputStream dis = new DataInputStream(bais);
--- 123,138 ----
// serialize.
! // ByteArrayOutputStream baos = new ByteArrayOutputStream();
! //
! // DataOutputStream dos = new DataOutputStream(baos);
! DataOutputBuffer dos = new DataOutputBuffer();
KeyBufferSerializer.INSTANCE.putKeys(dos, expected);
! // dos.flush();
// de-serialize.
! ByteArrayInputStream bais = new ByteArrayInputStream(dos.buf);
DataInputStream dis = new DataInputStream(bais);
***************
*** 152,166 ****
// serialize the mutable key buffer.
! baos = new ByteArrayOutputStream();
! dos = new DataOutputStream(baos);
KeyBufferSerializer.INSTANCE.putKeys(dos, expected2);
! dos.flush();
// de-serialize again.
! bais = new ByteArrayInputStream(baos.toByteArray());
dis = new DataInputStream(bais);
--- 153,167 ----
// serialize the mutable key buffer.
! // baos = new ByteArrayOutputStream();
! dos = new DataOutputBuffer();
KeyBufferSerializer.INSTANCE.putKeys(dos, expected2);
! // dos.flush();
// de-serialize again.
! bais = new ByteArrayInputStream(dos.buf);
dis = new DataInputStream(bais);
|