[MOBY-guts] biomoby commit
Paul Gordon
gordonp at dev.open-bio.org
Mon Jan 14 22:55:43 UTC 2008
gordonp
Mon Jan 14 17:55:42 EST 2008
Update of /home/repository/moby/moby-live/Java/src/main/ca/ucalgary/seahawk/util
In directory dev.open-bio.org:/tmp/cvs-serv8798/src/main/ca/ucalgary/seahawk/util
Modified Files:
MinJarMaker.java
Log Message:
Added verbose class loading option with -Dverbose.class=true
moby-live/Java/src/main/ca/ucalgary/seahawk/util MinJarMaker.java,1.7,1.8
===================================================================
RCS file: /home/repository/moby/moby-live/Java/src/main/ca/ucalgary/seahawk/util/MinJarMaker.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- /home/repository/moby/moby-live/Java/src/main/ca/ucalgary/seahawk/util/MinJarMaker.java 2007/12/14 23:38:06 1.7
+++ /home/repository/moby/moby-live/Java/src/main/ca/ucalgary/seahawk/util/MinJarMaker.java 2008/01/14 22:55:42 1.8
@@ -23,6 +23,8 @@
*/
public class MinJarMaker extends ClassLoader implements Runnable{
+ public static String VERBOSE = "verbose.class";
+
// The JAR file we want to create
protected String jarfile;
@@ -299,6 +301,9 @@
throw new IOException( "Could only read "+r+" of "+len+" bytes from "+classFile );
}
fin.close();
+ if(Boolean.getBoolean(VERBOSE)){
+ System.err.println("[Loaded " + name + " from " + classFile.getCanonicalPath() + "]");
+ }
return data;
}
else{
@@ -328,6 +333,9 @@
classBytes = new byte[(int) classSize]; //classes better not be bigger than 2 GB!
// Slurp it up in one shot
classStream.read(classBytes, 0, (int) classSize);
+ if(Boolean.getBoolean(VERBOSE)){
+ System.err.println("[Loaded " + name + " from " + f.getCanonicalPath() + "]");
+ }
return classBytes;
}
else{
@@ -339,6 +347,9 @@
r = classStream.read(byteBufferChunk, 0, 1024)){
byteBuffer.write(byteBufferChunk, 0, r);
}
+ if(Boolean.getBoolean(VERBOSE)){
+ System.err.println("[Loaded " + name + " from " + f.getCanonicalPath() + "]");
+ }
return byteBuffer.toByteArray();
}
}
More information about the MOBY-guts
mailing list