[Biojava-l] Re: Biojava-l Digest, Vol 8, Issue 6

Schreiber, Mark mark.schreiber at agresearch.co.nz
Tue Aug 12 23:03:37 EDT 2003


Hi -
 
Sounds great! Thomas Down also mentioned that he might know of someone who could help out. (Thomas could you put these people in touch with each other??)
 
Let me know when you need me to put pages up or set up links.
 
- Mark
 

	-----Original Message----- 
	From: wux at mail.cbi.pku.edu.cn [mailto:wux at mail.cbi.pku.edu.cn] 
	Sent: Tue 12/08/2003 2:21 p.m. 
	To: biojava-l at biojava.org 
	Cc: 
	Subject: [Biojava-l] Re: Biojava-l Digest, Vol 8, Issue 6
	
	

	Dear biojava-l-request:
	
	  Hi, Mark, We are the center of bioinformatics of Peking University (Beijing,P.R. China) which is national node of
	EMBnet.  I would like to do  the chinese version of biojava in Anger if you agree . 
	
	======= 2003-08-11 您在来信中写道:=======
	
	>Send Biojava-l mailing list submissions to
	>       biojava-l at biojava.org
	>
	>To subscribe or unsubscribe via the World Wide Web, visit
	>       http://biojava.org/mailman/listinfo/biojava-l
	>or, via email, send a message with subject or body 'help' to
	>       biojava-l-request at biojava.org
	>
	>You can reach the person managing the list at
	>       biojava-l-owner at biojava.org
	>
	>When replying, please edit your Subject line so it is more specific
	>than "Re: Contents of Biojava-l digest..."
	>
	>
	>Today's Topics:
	>
	>   1. RE: problems installing biojava on Windows 2000 (Matthew Pocock)
	>   2. biojava-acedb (Suman Kanuganti)
	>   3. Re: biojava-acedb (Suman Kanuganti)
	>   4. Announcing: BJIA in Japanese (Schreiber, Mark)
	>   5. RE: Re: biojava-acedb (Francois Pepin)
	>   6. Running apps with Java (Schreiber, Mark)
	>   7. Re: Running apps with Java (Thomas Down)
	>   8. Re: Running apps with Java (Francois Pepin)
	>   9. Re: Running apps with Java (Patrick McConnell)
	>
	>
	>----------------------------------------------------------------------
	>
	>Message: 1
	>Date: Sun, 10 Aug 2003 18:43:48 +0100 (BST)
	>From: Matthew Pocock <matthew_pocock at yahoo.co.uk>
	>Subject: RE: [Biojava-l] problems installing biojava on Windows 2000
	>To: David Millis <dmillis at mindspring.com>,     "'Schreiber, Mark'"
	>       <mark.schreiber at agresearch.co.nz>
	>Cc: biojava-l at biojava.org
	>Message-ID: <20030810174348.92714.qmail at web14915.mail.yahoo.com>
	>Content-Type: text/plain; charset=iso-8859-1
	>
	>Since 1.4 seems to come bundled with net-beans now,
	>should we update the docs to say how to get biojava
	>working in netbeans? Love it or hate it, everyone is
	>going to have it.
	>
	>Matthew
	>
	> --- David Millis <dmillis at mindspring.com> wrote: >
	>Mark -
	>>
	>> Thanks for your response to my message.
	>>
	>> I am using the netBeans 3.5 IDE for editing and
	>> compiling Java files. I
	>> have found that if I mount the
	>> biojava-1.30-jdk14.jar archive inside the
	>> IDE, the Java compiler is able to find all the files
	>> it needs, even if I
	>> don't edit the Windows PATH variable. I have finally
	>> been able to get
	>> one of the example from "BioJava In Anger" to
	>> compile without any
	>> errors. This is so much easier than trying to get
	>> the PATH variable set
	>> exactly right in Windows that I will just use this
	>> strategy.
	>>
	>> David Millis.
	>>
	>> -----Original Message-----
	>> From: Schreiber, Mark
	>> [mailto:mark.schreiber at agresearch.co.nz]
	>> Sent: Thursday, August 07, 2003 5:44 PM
	>> To: David Millis; biojava-l at biojava.org
	>> Subject: RE: [Biojava-l] problems installing biojava
	>> on Windows 2000
	>>
	>> Hi -
	>>
	>> Your class path looks OK but you can check that it
	>> has actually been set
	>> by running set command with no arguments from the
	>> command prompt. If the
	>> CLASSPATH variable is not displaying properly there
	>> then it is not
	>> properly set (possibly incorrect syntax).
	>>
	>> If you are running BioJava 1.3 or less you will also
	>> need the
	>> Jakarta-Regexp jar on your path.
	>>
	>> - Mark
	>>
	>>
	>> -----Original Message-----
	>> From: David Millis [mailto:dmillis at mindspring.com]
	>> Sent: Friday, 8 August 2003 6:04 a.m.
	>> To: biojava-l at biojava.org
	>> Subject: [Biojava-l] problems installing biojava on
	>> Windows 2000
	>>
	>>
	>>
	>> Hello,
	>>
	>> I am new to using biojava. I am trying to install
	>> biojava on a PC
	>> running Windows 2000 Professional. I am using Java 2
	>> SDK version 1.4.2.
	>> I have downloaded the files in the "binaries"
	>> directory in the download
	>> area of the biojava server to the directory
	>> "C:\biojava" on my computer.
	>> I have added the
	>> string
	>>
	>>
	>>
	>"C:\biojava;C:\biojava\biojava.jar;C:\biojava\xerces.jar;C:\biojava\byte
	>> code.jar;"
	>>
	>> to my PATH variable. When I try to compile one of
	>> the simple demo files,
	>> like AlphabetExample.java, I get error messages
	>> saying that the packages
	>> "org.biojava.bio.symbol.*" and
	>> "org.biojava.bio.seq.*" can't be found.
	>> Is there something else I have to do to get the
	>> biojava files installed
	>> correctly?
	>>
	>> Thanks -
	>> David Millis.
	>>
	>> _______________________________________________
	>> Biojava-l mailing list  -  Biojava-l at biojava.org
	>> http://biojava.org/mailman/listinfo/biojava-l
	>
	>________________________________________________________________________
	>Want to chat instantly with your online friends?  Get the FREE Yahoo!
	>Messenger http://uk.messenger.yahoo.com/
	>
	>------------------------------
	>
	>Message: 2
	>Date: Sun, 10 Aug 2003 15:13:19 -0700 (PDT)
	>From: Suman Kanuganti <bioinformatics4suman at yahoo.com>
	>Subject: [Biojava-l] biojava-acedb
	>To: biojava-l at biojava.org
	>Message-ID: <20030810221320.8535.qmail at web20702.mail.yahoo.com>
	>Content-Type: text/plain; charset=us-ascii
	>
	>Is there any jar for acedb-biojava for running its
	>programs. I downloaded biojava-acedb.tar but couldnt
	>figure how to build corresponding .jar to add it in my
	>path.
	>
	>Could any one tell me about this?
	>
	>Suman K
	>
	>__________________________________
	>Do you Yahoo!?
	>Yahoo! SiteBuilder - Free, easy-to-use web site design software
	>http://sitebuilder.yahoo.com
	>
	>------------------------------
	>
	>Message: 3
	>Date: Sun, 10 Aug 2003 15:40:06 -0700 (PDT)
	>From: Suman Kanuganti <bioinformatics4suman at yahoo.com>
	>Subject: [Biojava-l] Re: biojava-acedb
	>To: biojava-l at biojava.org
	>Message-ID: <20030810224006.59350.qmail at web20713.mail.yahoo.com>
	>Content-Type: text/plain; charset=us-ascii
	>
	>I figured out something that I need to use ant to
	>build the acedb-biojava, with the build.xml provided
	>by the package. Now the problem:
	>
	>[newton at newtondell bin]$ ant -buildfile
	>~/biojava-acedb/build.xml
	>Buildfile: /home/newton/biojava-acedb/build.xml
	>
	>init:
	>
	>prepare:
	>
	>BUILD FAILED
	>file:/home/newton/biojava-acedb/build.xml:61:
	>Directory /home/newton/biojava-acedb/ant-build
	>creation was not successful for an unknown reason
	>
	>Total time: 1 second
	>
	>Any suggestions,
	>Suman K
	>
	>
	>--- Suman Kanuganti <bioinformatics4suman at yahoo.com>
	>wrote:
	>> Is there any jar for acedb-biojava for running its
	>> programs. I downloaded biojava-acedb.tar but couldnt
	>> figure how to build corresponding .jar to add it in
	>> my
	>> path.
	>>
	>> Could any one tell me about this?
	>>
	>> Suman K
	>>
	>> __________________________________
	>> Do you Yahoo!?
	>> Yahoo! SiteBuilder - Free, easy-to-use web site
	>> design software
	>> http://sitebuilder.yahoo.com
	>>
	>
	>
	>=====
	>Suman K
	>BioInformatics Associate,
	>Genomics Research,
	>University of Missouri - Columbia.
	>
	>__________________________________
	>Do you Yahoo!?
	>Yahoo! SiteBuilder - Free, easy-to-use web site design software
	>http://sitebuilder.yahoo.com
	>
	>------------------------------
	>
	>Message: 4
	>Date: Mon, 11 Aug 2003 11:30:34 +1200
	>From: "Schreiber, Mark" <mark.schreiber at agresearch.co.nz>
	>Subject: [Biojava-l] Announcing: BJIA in Japanese
	>To: <biojava-l at biojava.org>, <biojava-dev at biojava.org>
	>Message-ID:
	>       <AF026AF0FF4B054590228FD1F1DE5165011BA5F4 at inbox.agresearch.co.nz>
	>Content-Type: text/plain;      charset="us-ascii"
	>
	>Hello all,
	>
	>The unexpectidly popular biojava in anger site has now been translated
	>into Japanese. A big thanks to the Translators Takeshi Sasayama and
	>Kentaro Sugino and possibly others, let me know if I haven't credited
	>every one.
	>
	>Just follow the link off the main page:
	>http://www.biojava.org/docs/bj_in_anger/index.htm.  This site requires
	>you to have the font MS Michu to display Kanji but you can easily get it
	>off the web. There is also a link to a French version (by Sylvain
	>Foisey)  on the main page. Anyone want to do a Chinese or Spanish
	>version so we can cover 90 of the world?
	>
	>I have also recently added a tutorial on the use of Edit objects in the
	>Basic Sequence Manipulaton section
	>(http://www.biojava.org/docs/bj_in_anger/edit.htm)
	>
	>I'm always open to suggestions for or donations of new tutorials,
	>comments and bugfixes.
	>
	>Enjoy
	>
	>- Mark
	>
	>Mark Schreiber PhD
	>AgResearch Joint Bioinformatics Institute
	>School of Biological Sciences
	>Universtity of Auckland
	>3a Symonds St
	>Private Bag 92-019 Auckland New Zealand
	>
	>PH:   +64 9 3737599 ext 84290
	>FAX:  +64 9 3737414
	>
	>
	>=======================================================================
	>Attention: The information contained in this message and/or attachments
	>from AgResearch Limited is intended only for the persons or entities
	>to which it is addressed and may contain confidential and/or privileged
	>material. Any review, retransmission, dissemination or other use of, or
	>taking of any action in reliance upon, this information by persons or
	>entities other than the intended recipients is prohibited by AgResearch
	>Limited. If you have received this message in error, please notify the
	>sender immediately.
	>=======================================================================
	>
	>
	>------------------------------
	>
	>Message: 5
	>Date: Sun, 10 Aug 2003 19:53:43 -0400
	>From: "Francois Pepin" <fpepin at cs.mcgill.ca>
	>Subject: RE: [Biojava-l] Re: biojava-acedb
	>To: "'Suman Kanuganti'" <bioinformatics4suman at yahoo.com>,
	>       <biojava-l at biojava.org>
	>Message-ID: <006101c35f9a$a5262a50$e0abfea9 at hermes>
	>Content-Type: text/plain;      charset="us-ascii"
	>
	>Hi Suman,
	>
	>My guess is that you have a permission problem somewhere, or that your
	>disk is full or something similar.
	>
	>Try to see if you can create that directory by yourself.
	>
	>The error seems to be about being able to create the directory itself.
	>It happened before any of the code was touched for compilation, so the
	>problem would not be with the code, but with the machine that you're
	>building on.
	>
	>Francois
	>
	>-----Original Message-----
	>From: biojava-l-bounces at biojava.org
	>[mailto:biojava-l-bounces at biojava.org] On Behalf Of Suman Kanuganti
	>Sent: 10 aout, 2003 18:40
	>To: biojava-l at biojava.org
	>Subject: [Biojava-l] Re: biojava-acedb
	>
	>
	>I figured out something that I need to use ant to
	>build the acedb-biojava, with the build.xml provided
	>by the package. Now the problem:
	>
	>[newton at newtondell bin]$ ant -buildfile ~/biojava-acedb/build.xml
	>Buildfile: /home/newton/biojava-acedb/build.xml
	>
	>init:
	>
	>prepare:
	>
	>BUILD FAILED
	>file:/home/newton/biojava-acedb/build.xml:61:
	>Directory /home/newton/biojava-acedb/ant-build
	>creation was not successful for an unknown reason
	>
	>Total time: 1 second
	>
	>Any suggestions,
	>Suman K
	>
	>
	>--- Suman Kanuganti <bioinformatics4suman at yahoo.com>
	>wrote:
	>> Is there any jar for acedb-biojava for running its
	>> programs. I downloaded biojava-acedb.tar but couldnt
	>> figure how to build corresponding .jar to add it in
	>> my
	>> path.
	>>
	>> Could any one tell me about this?
	>>
	>> Suman K
	>>
	>> __________________________________
	>> Do you Yahoo!?
	>> Yahoo! SiteBuilder - Free, easy-to-use web site
	>> design software
	>> http://sitebuilder.yahoo.com
	>>
	>
	>
	>=====
	>Suman K
	>BioInformatics Associate,
	>Genomics Research,
	>University of Missouri - Columbia.
	>
	>__________________________________
	>Do you Yahoo!?
	>Yahoo! SiteBuilder - Free, easy-to-use web site design software
	>http://sitebuilder.yahoo.com
	>_______________________________________________
	>Biojava-l mailing list  -  Biojava-l at biojava.org
	>http://biojava.org/mailman/listinfo/biojava-l
	>
	>
	>------------------------------
	>
	>Message: 6
	>Date: Mon, 11 Aug 2003 11:59:46 +1200
	>From: "Schreiber, Mark" <mark.schreiber at agresearch.co.nz>
	>Subject: [Biojava-l] Running apps with Java
	>To: <biojava-l at biojava.org>
	>Message-ID:
	>       <AF026AF0FF4B054590228FD1F1DE5165011BA5F6 at inbox.agresearch.co.nz>
	>Content-Type: text/plain;      charset="us-ascii"
	>
	>Hi -
	>
	>I know this has come up a few times on the list but I'm not sure we have
	>ever come to any agreement on it so I'm going to raise it again as I
	>think it is important.
	>
	>What is the best way to invoke a native bioinformatics program in Java.
	>People have reported that controlling processes directly has been patchy
	>in Java, is this still the case or have JVMs evolved? If not then what
	>is the alternative? Wrapping the program in a perl or python webservice?
	>If this was the prefered method then we could borrow quite a bit from
	>the Bio::Pipeline::Runnable package.
	>
	>Ultimately the reason for asking is that J2EE (particularly the message
	>driven beans) would make for a pretty good pipelining system (drawing on
	>all its inherent transaction control, roll back etc). My expectation
	>would be that biojava could exist server side to provide parsing support
	>and possibly connection to BioSQL although J2EE could also do that
	>without biojava. It would also be useful in local EJBs (no serialization
	>slowdown) to do some manipulation of sequence data. The only missing
	>component is some kind of BioRunnable that could reliably kick off the
	>jobs and capture the output for parsing with the biojava parsers.
	>
	>Any thoughts?
	>
	>- Mark
	>
	>
	>Mark Schreiber PhD
	>AgResearch Joint Bioinformatics Institute
	>School of Biological Sciences
	>Universtity of Auckland
	>3a Symonds St
	>Private Bag 92-019 Auckland New Zealand
	>
	>PH:   +64 9 3737599 ext 84290
	>FAX:  +64 9 3737414
	>
	>
	>=======================================================================
	>Attention: The information contained in this message and/or attachments
	>from AgResearch Limited is intended only for the persons or entities
	>to which it is addressed and may contain confidential and/or privileged
	>material. Any review, retransmission, dissemination or other use of, or
	>taking of any action in reliance upon, this information by persons or
	>entities other than the intended recipients is prohibited by AgResearch
	>Limited. If you have received this message in error, please notify the
	>sender immediately.
	>=======================================================================
	>
	>
	>------------------------------
	>
	>Message: 7
	>Date: Mon, 11 Aug 2003 09:11:08 +0100
	>From: Thomas Down <td2 at sanger.ac.uk>
	>Subject: Re: [Biojava-l] Running apps with Java
	>To: "Schreiber, Mark" <mark.schreiber at agresearch.co.nz>
	>Cc: biojava-l at biojava.org
	>Message-ID: <20030811081108.GA78872 at jabba.sanger.ac.uk>
	>Content-Type: text/plain; charset=us-ascii
	>
	>On Mon, Aug 11, 2003 at 11:59:46AM +1200, Schreiber, Mark wrote:
	>>
	>> What is the best way to invoke a native bioinformatics program in Java.
	>> People have reported that controlling processes directly has been patchy
	>> in Java, is this still the case or have JVMs evolved? If not then what
	>> is the alternative? Wrapping the program in a perl or python webservice?
	>> If this was the prefered method then we could borrow quite a bit from
	>> the Bio::Pipeline::Runnable package.
	>
	>I think it *is* possible to write good-quality wrappers to
	>external tools in Java: it's just that the Runtime.exec
	>APIs are substantially more complicated than the equivalents
	>in $PREFERRED_SCRIPTING_LANGUAGE.  If you're using stdin/stdout/stderr
	>on the external program, you need to make heavy use of Threads
	>in Java.  I think that's the main barrier to entry.
	>
	>A lot of these issues could probably be addressed by something
	>like:
	>
	>public class ExecTools {
	>    /**
	>     * Execute an external program and wait for it to complete.
	>     *
	>     * @param args the command line to run.
	>     * @param input some data to feed to the program's standard input,
	>     *              or null if no data.
	>     * @param stdout a StringBuffer to receive the program's output,
	>     *               or null to ignore them.
	>     * @param stderr a StringBuffer to receive the program's error
	>     *               stream, or null to ignore this.
	>     * @returns the program's return code.
	>     */
	>
	>    public static int exec(
	>        String[] args,
	>        String input,
	>        StringBuffer stdout,
	>        StringBuffer stderr
	>    );
	>}
	>
	>All the necessary thread code for most practical uses of exec could
	>be hidden in there.  I might code this up this afternoon if nobody
	>objects -- it's code I write reasonably regularly, and the API above
	>would certainly save me time.  Anyone else?
	>
	>
	>As for the web service approach, AppLap might be relevant:
	>
	>     http://industry.ebi.ac.uk/applab/
	>
	>Thomas.
	>
	>------------------------------
	>
	>Message: 8
	>Date: Mon, 11 Aug 2003 10:03:55 -0400 (EDT)
	>From: Francois Pepin <fpepin at cs.mcgill.ca>
	>Subject: Re: [Biojava-l] Running apps with Java
	>To: biojava-l at biojava.org
	>Message-ID: <Pine.GSO.4.44.0308111003050.6867-100000 at mimi>
	>Content-Type: TEXT/PLAIN; charset=US-ASCII
	>
	>I have code that did that, but it wasn't reliable enough to use like
	>that. For unknown reasons, there are programs that I couldn't call at
	>all.
	>
	>The only reliable method that I found was to write a one-liner shell
	>script to be executed by sh, but this is an ugly, ugly hack.
	>
	>The grabbing of stdin and stdout wasn't working as advertised either.
	>
	>This is with Linux. I don't know about Windows, but I'm sure I'm not the
	>only one who needs to call Linux apps.
	>
	>Maybe like Mark said it got more reliable with 1.4.
	>
	>Personally I'd much rather use a system like that than to have to depend
	>on Perl or Python to do it.
	>
	>Francois
	>
	>On Mon, 2003-08-11 at 04:11, Thomas Down wrote:
	>> On Mon, Aug 11, 2003 at 11:59:46AM +1200, Schreiber, Mark wrote:
	>> >
	>> > What is the best way to invoke a native bioinformatics program in
	>Java.
	>> > People have reported that controlling processes directly has been
	>patchy
	>> > in Java, is this still the case or have JVMs evolved? If not then what
	>> > is the alternative? Wrapping the program in a perl or python
	>webservice?
	>> > If this was the prefered method then we could borrow quite a bit from
	>> > the Bio::Pipeline::Runnable package.
	>>
	>> I think it *is* possible to write good-quality wrappers to
	>> external tools in Java: it's just that the Runtime.exec
	>> APIs are substantially more complicated than the equivalents
	>> in $PREFERRED_SCRIPTING_LANGUAGE. If you're using stdin/stdout/stderr
	>> on the external program, you need to make heavy use of Threads
	>> in Java. I think that's the main barrier to entry.
	>>
	>> A lot of these issues could probably be addressed by something
	>> like:
	>>
	>> public class ExecTools {
	>> /**
	>> * Execute an external program and wait for it to complete.
	>> *
	>> * @param args the command line to run.
	>> * @param input some data to feed to the program's standard input,
	>> * or null if no data.
	>> * @param stdout a StringBuffer to receive the program's output,
	>> * or null to ignore them.
	>> * @param stderr a StringBuffer to receive the program's error
	>> * stream, or null to ignore this.
	>> * @returns the program's return code.
	>> */
	>>
	>> public static int exec(
	>> String[] args,
	>> String input,
	>> StringBuffer stdout,
	>> StringBuffer stderr
	>> );
	>> }
	>>
	>> All the necessary thread code for most practical uses of exec could
	>> be hidden in there. I might code this up this afternoon if nobody
	>> objects -- it's code I write reasonably regularly, and the API above
	>> would certainly save me time. Anyone else?
	>>
	>>
	>> As for the web service approach, AppLap might be relevant:
	>>
	>> http://industry.ebi.ac.uk/applab/
	>>
	>> Thomas.
	>> _______________________________________________
	>> Biojava-l mailing list - Biojava-l at biojava.org
	>> http://biojava.org/mailman/listinfo/biojava-l
	>
	>
	>------------------------------
	>
	>Message: 9
	>Date: Mon, 11 Aug 2003 10:28:14 -0400
	>From: "Patrick McConnell" <MCCon012 at mc.duke.edu>
	>Subject: Re: [Biojava-l] Running apps with Java
	>To: biojava-l at biojava.org
	>Message-ID:
	>       <OF0C5E9D1F.6A76EA34-ON85256D7F.004ED3D3-85256D7F.004F7D5B at notes.duke.edu>
	>      
	>Content-Type: text/plain; charset=us-ascii
	>
	>
	>
	>
	>
	>
	>We do something similar, and I have not ran into any problems.  The biggest
	>problem is when stdout and stderr are not handled in separate threads.
	>
	>Personally, I would like to see API's developed for specific applications.
	>Something ilke:
	>
	>    public static int execNCBIBlast(
	>        String executable,
	>        String inputFile,
	>        String outputFile
	>        String program,
	>        String database,
	>        String input,
	>        StringBuffer stdout,
	>        StringBuffer stderr
	>    );
	>
	>Or, even better would be some sort of Parameters class to encapsulate all
	>those parameters, providing optional parameters.  Then, you could do
	>something like this:
	>
	>   NCBIBlastParameters params = new NCBIBlastParameters();
	>   params.addParameter("p", "blastn");
	>   params.addParameter("d", "nt");
	>   params.addParameter("m", "7");
	>   StringBuffer outputXML = new StringBuffer();
	>   int success = NCBIBlast.exec(
	>     "c:\\blast\\blastall",
	>     params,
	>     inputFasta,
	>     outputXML,
	>     null
	>   );
	>   System.out.println(outputXML);
	>
	>I think this would be more convenient to people for developing
	>applications.  If you wanted to get fancy, you could have the exec method
	>throw an exception for missing or invalid parameters.  Perhaps a method to
	>turn off this parameter checking would also be necessary.
	>
	>-Patrick
	>
	>
	>
	>
	>
	>Thomas Down <td2 at sanger.ac.uk>@biojava.org on 08/11/2003 04:11:08 AM
	>
	>Sent by:    biojava-l-bounces at biojava.org
	>
	>
	>To:    "Schreiber, Mark" <mark.schreiber at agresearch.co.nz>
	>cc:    biojava-l at biojava.org
	>
	>Subject:    Re: [Biojava-l] Running apps with Java
	>
	>On Mon, Aug 11, 2003 at 11:59:46AM +1200, Schreiber, Mark wrote:
	>>
	>> What is the best way to invoke a native bioinformatics program in Java.
	>> People have reported that controlling processes directly has been patchy
	>> in Java, is this still the case or have JVMs evolved? If not then what
	>> is the alternative? Wrapping the program in a perl or python webservice?
	>> If this was the prefered method then we could borrow quite a bit from
	>> the Bio::Pipeline::Runnable package.
	>
	>I think it *is* possible to write good-quality wrappers to
	>external tools in Java: it's just that the Runtime.exec
	>APIs are substantially more complicated than the equivalents
	>in $PREFERRED_SCRIPTING_LANGUAGE.  If you're using stdin/stdout/stderr
	>on the external program, you need to make heavy use of Threads
	>in Java.  I think that's the main barrier to entry.
	>
	>A lot of these issues could probably be addressed by something
	>like:
	>
	>public class ExecTools {
	>    /**
	>     * Execute an external program and wait for it to complete.
	>     *
	>     * @param args the command line to run.
	>     * @param input some data to feed to the program's standard input,
	>     *              or null if no data.
	>     * @param stdout a StringBuffer to receive the program's output,
	>     *               or null to ignore them.
	>     * @param stderr a StringBuffer to receive the program's error
	>     *               stream, or null to ignore this.
	>     * @returns the program's return code.
	>     */
	>
	>    public static int exec(
	>        String[] args,
	>        String input,
	>        StringBuffer stdout,
	>        StringBuffer stderr
	>    );
	>}
	>
	>All the necessary thread code for most practical uses of exec could
	>be hidden in there.  I might code this up this afternoon if nobody
	>objects -- it's code I write reasonably regularly, and the API above
	>would certainly save me time.  Anyone else?
	>
	>
	>As for the web service approach, AppLap might be relevant:
	>
	>     http://industry.ebi.ac.uk/applab/
	>
	>Thomas.
	>_______________________________________________
	>Biojava-l mailing list  -  Biojava-l at biojava.org
	>http://biojava.org/mailman/listinfo/biojava-l
	>
	>
	>
	>
	>
	>------------------------------
	>
	>_______________________________________________
	>Biojava-l mailing list  -  Biojava-l at biojava.org
	>http://biojava.org/mailman/listinfo/biojava-l
	>
	>
	>End of Biojava-l Digest, Vol 8, Issue 6
	>***************************************
	>.
	
	= = = = = = = = = = = = = = = = = = = =
	                      
	                        
	              Best wishes for you!
	                   
	                                          Yours faithfully,
	                   wux
	                   wux at mail.cbi.pku.edu.cn
	                   2003-08-12
	*****************************************************
	WuXin  Ph.D student of CBI (Center of Bioinformatics)
	Peking University  100871 P.R.China
	Email: wux at mail.cbi.pku.edu.cn
	Tel: 010-62762409 (dorm)
	     010-62755206 (office)
	Address: Building 47#2026 Peking University
	*****************************************************
	
	_______________________________________________
	Biojava-l mailing list  -  Biojava-l at biojava.org
	http://biojava.org/mailman/listinfo/biojava-l
	


=======================================================================
Attention: The information contained in this message and/or attachments
from AgResearch Limited is intended only for the persons or entities
to which it is addressed and may contain confidential and/or privileged
material. Any review, retransmission, dissemination or other use of, or
taking of any action in reliance upon, this information by persons or
entities other than the intended recipients is prohibited by AgResearch
Limited. If you have received this message in error, please notify the
sender immediately.
=======================================================================



More information about the Biojava-l mailing list