diff options
Diffstat (limited to 'src/interfaces/jdbc/org/postgresql/largeobject')
6 files changed, 58 insertions, 58 deletions
diff --git a/src/interfaces/jdbc/org/postgresql/largeobject/BlobInputStream.java b/src/interfaces/jdbc/org/postgresql/largeobject/BlobInputStream.java index 74c83b98a81..0e508cfd32c 100644 --- a/src/interfaces/jdbc/org/postgresql/largeobject/BlobInputStream.java +++ b/src/interfaces/jdbc/org/postgresql/largeobject/BlobInputStream.java @@ -4,39 +4,39 @@ import java.io.InputStream; import java.io.IOException; import java.sql.SQLException; -/** +/* * This is an initial implementation of an InputStream from a large object. * For now, the bare minimum is implemented. Later (after 7.1) we will overide * the other read methods to optimise them. */ public class BlobInputStream extends InputStream { - /** + /* * The parent LargeObject */ private LargeObject lo; - /** + /* * Buffer used to improve performance */ private byte[] buffer; - /** + /* * Position within buffer */ private int bpos; - /** + /* * The buffer size */ private int bsize; - /** + /* * The mark position */ private int mpos = 0; - /** + /* * @param lo LargeObject to read from */ public BlobInputStream(LargeObject lo) @@ -44,7 +44,7 @@ public class BlobInputStream extends InputStream this(lo, 1024); } - /** + /* * @param lo LargeObject to read from * @param bsize buffer size */ @@ -56,7 +56,7 @@ public class BlobInputStream extends InputStream this.bsize = bsize; } - /** + /* * The minimum required to implement input stream */ public int read() throws java.io.IOException @@ -92,7 +92,7 @@ public class BlobInputStream extends InputStream } - /** + /* * Closes this input stream and releases any system resources associated * with the stream. * @@ -114,7 +114,7 @@ public class BlobInputStream extends InputStream } } - /** + /* * Marks the current position in this input stream. A subsequent call to * the <code>reset</code> method repositions this stream at the last marked * position so that subsequent reads re-read the same bytes. @@ -150,7 +150,7 @@ public class BlobInputStream extends InputStream } } - /** + /* * Repositions this stream to the position at the time the * <code>mark</code> method was last called on this input stream. * NB: If mark is not called we move to the begining. @@ -170,7 +170,7 @@ public class BlobInputStream extends InputStream } } - /** + /* * Tests if this input stream supports the <code>mark</code> and * <code>reset</code> methods. The <code>markSupported</code> method of * <code>InputStream</code> returns <code>false</code>. diff --git a/src/interfaces/jdbc/org/postgresql/largeobject/BlobOutputStream.java b/src/interfaces/jdbc/org/postgresql/largeobject/BlobOutputStream.java index 763e2bbba13..b56de6e5430 100644 --- a/src/interfaces/jdbc/org/postgresql/largeobject/BlobOutputStream.java +++ b/src/interfaces/jdbc/org/postgresql/largeobject/BlobOutputStream.java @@ -4,32 +4,32 @@ import java.io.IOException; import java.io.OutputStream; import java.sql.SQLException; -/** +/* * This implements a basic output stream that writes to a LargeObject */ public class BlobOutputStream extends OutputStream { - /** + /* * The parent LargeObject */ private LargeObject lo; - /** + /* * Buffer */ private byte buf[]; - /** + /* * Size of the buffer (default 1K) */ private int bsize; - /** + /* * Position within the buffer */ private int bpos; - /** + /* * Create an OutputStream to a large object * @param lo LargeObject */ @@ -38,7 +38,7 @@ public class BlobOutputStream extends OutputStream this(lo, 1024); } - /** + /* * Create an OutputStream to a large object * @param lo LargeObject * @param bsize The size of the buffer used to improve performance @@ -68,7 +68,7 @@ public class BlobOutputStream extends OutputStream } } - /** + /* * Flushes this output stream and forces any buffered output bytes * to be written out. The general contract of <code>flush</code> is * that calling it is an indication that, if any bytes previously @@ -92,7 +92,7 @@ public class BlobOutputStream extends OutputStream } } - /** + /* * Closes this output stream and releases any system resources * associated with this stream. The general contract of <code>close</code> * is that it closes the output stream. A closed stream cannot perform diff --git a/src/interfaces/jdbc/org/postgresql/largeobject/LargeObject.java b/src/interfaces/jdbc/org/postgresql/largeobject/LargeObject.java index d701c6122bc..f5eab8310f7 100644 --- a/src/interfaces/jdbc/org/postgresql/largeobject/LargeObject.java +++ b/src/interfaces/jdbc/org/postgresql/largeobject/LargeObject.java @@ -8,7 +8,7 @@ import java.sql.*; import org.postgresql.fastpath.*; -/** +/* * This class implements the large object interface to org.postgresql. * * <p>It provides the basic methods required to run the interface, plus @@ -43,17 +43,17 @@ import org.postgresql.fastpath.*; */ public class LargeObject { - /** + /* * Indicates a seek from the begining of a file */ public static final int SEEK_SET = 0; - /** + /* * Indicates a seek from the current position */ public static final int SEEK_CUR = 1; - /** + /* * Indicates a seek from the end of a file */ public static final int SEEK_END = 2; @@ -66,7 +66,7 @@ public class LargeObject private boolean closed = false; // true when we are closed - /** + /* * This opens a large object. * * <p>If the object does not exist, then an SQLException is thrown. @@ -95,7 +95,7 @@ public class LargeObject close(); } - /** + /* * @return the OID of this LargeObject */ public int getOID() @@ -103,7 +103,7 @@ public class LargeObject return oid; } - /** + /* * This method closes the object. You must not call methods in this * object after this is called. * @exception SQLException if a database-access error occurs. @@ -138,7 +138,7 @@ public class LargeObject } } - /** + /* * Reads some data from the object, and return as a byte[] array * * @param len number of bytes to read @@ -155,7 +155,7 @@ public class LargeObject return fp.getData("loread", args); // This version allows us to break this down into 4k blocks - //if(len<=4048) { + //if (len<=4048) { //// handle as before, return the whole block in one go //FastpathArg args[] = new FastpathArg[2]; //args[0] = new FastpathArg(fd); @@ -165,10 +165,10 @@ public class LargeObject //// return in 4k blocks //byte[] buf=new byte[len]; //int off=0; - //while(len>0) { + //while (len>0) { //int bs=4048; //len-=bs; - //if(len<0) { + //if (len<0) { //bs+=len; //len=0; //} @@ -179,7 +179,7 @@ public class LargeObject //} } - /** + /* * Reads some data from the object into an existing array * * @param buf destination array @@ -197,7 +197,7 @@ public class LargeObject return len; } - /** + /* * Writes an array to the object * * @param buf array to write @@ -211,7 +211,7 @@ public class LargeObject fp.fastpath("lowrite", false, args); } - /** + /* * Writes some data from an array to the object * * @param buf destination array @@ -226,7 +226,7 @@ public class LargeObject write(data); } - /** + /* * Sets the current position within the object. * * <p>This is similar to the fseek() call in the standard C library. It @@ -245,7 +245,7 @@ public class LargeObject fp.fastpath("lo_lseek", false, args); } - /** + /* * Sets the current position within the object. * * <p>This is similar to the fseek() call in the standard C library. It @@ -259,7 +259,7 @@ public class LargeObject seek(pos, SEEK_SET); } - /** + /* * @return the current position within the object * @exception SQLException if a database-access error occurs. */ @@ -270,7 +270,7 @@ public class LargeObject return fp.getInteger("lo_tell", args); } - /** + /* * This method is inefficient, as the only way to find out the size of * the object is to seek to the end, record the current position, then * return to the original position. @@ -289,7 +289,7 @@ public class LargeObject return sz; } - /** + /* * Returns an InputStream from this object. * * <p>This InputStream can then be used in any method that requires an @@ -302,7 +302,7 @@ public class LargeObject return new BlobInputStream(this); } - /** + /* * Returns an OutputStream to this object * * <p>This OutputStream can then be used in any method that requires an diff --git a/src/interfaces/jdbc/org/postgresql/largeobject/LargeObjectManager.java b/src/interfaces/jdbc/org/postgresql/largeobject/LargeObjectManager.java index 03445c01b7a..dec1de55f0a 100644 --- a/src/interfaces/jdbc/org/postgresql/largeobject/LargeObjectManager.java +++ b/src/interfaces/jdbc/org/postgresql/largeobject/LargeObjectManager.java @@ -9,7 +9,7 @@ import java.sql.*; import org.postgresql.fastpath.*; import org.postgresql.util.*; -/** +/* * This class implements the large object interface to org.postgresql. * * <p>It provides methods that allow client code to create, open and delete @@ -61,29 +61,29 @@ public class LargeObjectManager // the fastpath api for this connection private Fastpath fp; - /** + /* * This mode indicates we want to write to an object */ public static final int WRITE = 0x00020000; - /** + /* * This mode indicates we want to read an object */ public static final int READ = 0x00040000; - /** + /* * This mode is the default. It indicates we want read and write access to * a large object */ public static final int READWRITE = READ | WRITE; - /** + /* * This prevents us being created by mere mortals */ private LargeObjectManager() {} - /** + /* * Constructs the LargeObject API. * * <p><b>Important Notice</b> @@ -120,7 +120,7 @@ public class LargeObjectManager DriverManager.println("Large Object initialised"); } - /** + /* * This opens an existing large object, based on its OID. This method * assumes that READ and WRITE access is required (the default). * @@ -133,7 +133,7 @@ public class LargeObjectManager return new LargeObject(fp, oid, READWRITE); } - /** + /* * This opens an existing large object, based on its OID * * @param oid of large object @@ -146,7 +146,7 @@ public class LargeObjectManager return new LargeObject(fp, oid, mode); } - /** + /* * This creates a large object, returning its OID. * * <p>It defaults to READWRITE for the new object's attributes. @@ -161,7 +161,7 @@ public class LargeObjectManager return fp.getInteger("lo_creat", args); } - /** + /* * This creates a large object, returning its OID * * @param mode a bitmask describing different attributes of the new object @@ -175,7 +175,7 @@ public class LargeObjectManager return fp.getInteger("lo_creat", args); } - /** + /* * This deletes a large object. * * @param oid describing object to delete @@ -188,7 +188,7 @@ public class LargeObjectManager fp.fastpath("lo_unlink", false, args); } - /** + /* * This deletes a large object. * * <p>It is identical to the delete method, and is supplied as the C API uses diff --git a/src/interfaces/jdbc/org/postgresql/largeobject/PGblob.java b/src/interfaces/jdbc/org/postgresql/largeobject/PGblob.java index 2959668bac0..12e04e4c14a 100644 --- a/src/interfaces/jdbc/org/postgresql/largeobject/PGblob.java +++ b/src/interfaces/jdbc/org/postgresql/largeobject/PGblob.java @@ -16,11 +16,11 @@ import org.postgresql.Field; import org.postgresql.largeobject.*; import org.postgresql.largeobject.*; -/** +/* * This implements the Blob interface, which is basically another way to * access a LargeObject. * - * $Id: PGblob.java,v 1.2 2001/10/25 05:59:59 momjian Exp $ + * $Id: PGblob.java,v 1.3 2001/11/19 22:33:39 momjian Exp $ * */ public class PGblob implements java.sql.Blob diff --git a/src/interfaces/jdbc/org/postgresql/largeobject/PGclob.java b/src/interfaces/jdbc/org/postgresql/largeobject/PGclob.java index 805ca018901..63d39c07b0f 100644 --- a/src/interfaces/jdbc/org/postgresql/largeobject/PGclob.java +++ b/src/interfaces/jdbc/org/postgresql/largeobject/PGclob.java @@ -16,11 +16,11 @@ import org.postgresql.Field; import org.postgresql.largeobject.*; import org.postgresql.largeobject.*; -/** +/* * This implements the Blob interface, which is basically another way to * access a LargeObject. * - * $Id: PGclob.java,v 1.2 2001/10/25 05:59:59 momjian Exp $ + * $Id: PGclob.java,v 1.3 2001/11/19 22:33:39 momjian Exp $ * */ public class PGclob implements java.sql.Clob |
