Jonathan,
I have tried a number of different ways to build the string:
StringBuilder, StringBuffer, and just String = String + line;

The cleanest way I can think of would be to pass an array of strings to
loadinline and have Jmol empty the array as processed or have an overload of
loadFile that would read the array and also empty as read.  I am trying to
avoid having to use another chuck of memory when all the file contents are
already stored as an ArrayList.

If I write to a temp file on disk I can free the array prior to loading back
in the file but then I have the lag associated with file i/o.  I think I
will see if I can get Jmol to take a memory file.  I am an old C/C++ guy and
I will have to see what Java has for memory file options.

Thanks,
Joe


> -----Original Message-----
> From: Jonathan Gutow [mailto:[email protected]]
> Sent: Sunday, November 01, 2009 2:26 PM
> To: [email protected]
> Subject: Re: [Jmol-developers] inline clarification
> 
> Joe,
>       Got it!  Sorry, now that you say this I recall your original
> description of the problem.  Unfortunately, I don't think I'm familiar
> enough with the loadinline code to help you.  This actually sounds
> like a Java conversion error.  Are you concatenating all the strings
> first?  Other than that I'm out of ideas.
> 
> Sorry,
> Jonathan
> On Nov 1, 2009, at 2:30 PM, Joe Gatewood wrote:
> 
> > I have the pdb files stored in a relational DB.
> >
> > The DB returns the file as a JList<String> with the exact contents
> > of the
> > original pdb.
> >
> > I am trying to avoid writing to file and then having to do a file
> > read?
> > I am working with an embedded application not an applet.
> >
> > Joe
> >
> >
> >> -----Original Message-----
> >> From: Jonathan Gutow [mailto:[email protected]]
> >> Sent: Sunday, November 01, 2009 1:20 PM
> >> To: [email protected]
> >> Subject: Re: [Jmol-developers] inline clarification
> >>
> >> Is there a reason you are not just generating a multiframe file of
> >> one
> >> of the formats Jmol reads.  Then you can just use the standard Jmol
> >> load calls and not have to worry about inline strings.  Are you
> >> trying
> >> to do the generation in javascript on the user's machine?
> >
> >
> > ------------------------------------------------------------------------
> ------
> > Come build with us! The BlackBerry(R) Developer Conference in SF, CA
> > is the only developer event you need to attend this year. Jumpstart
> > your
> > developing skills, take BlackBerry mobile applications to market and
> > stay
> > ahead of the curve. Join us from November 9 - 12, 2009. Register now!
> > http://p.sf.net/sfu/devconference
> > _______________________________________________
> > Jmol-developers mailing list
> > [email protected]
> > https://lists.sourceforge.net/lists/listinfo/jmol-developers
> 
>                           Dr. Jonathan H. Gutow
> Chemistry Department                                 [email protected]
> UW-Oshkosh                                           Office:920-424-1326
> 800 Algoma Boulevard                                 FAX:920-424-2042
> Oshkosh, WI 54901
>                   http://www.uwosh.edu/facstaff/gutow
> 
> 
> 
> 
> 
> 
> --------------------------------------------------------------------------
> ----
> Come build with us! The BlackBerry(R) Developer Conference in SF, CA
> is the only developer event you need to attend this year. Jumpstart your
> developing skills, take BlackBerry mobile applications to market and stay
> ahead of the curve. Join us from November 9 - 12, 2009. Register now!
> http://p.sf.net/sfu/devconference
> _______________________________________________
> Jmol-developers mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/jmol-developers


------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay 
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
Jmol-developers mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jmol-developers

Reply via email to