Dear OOo Dev folk -

I've been poking around in the DEV300_m48 world for a bit. I am exploring ways to use OpenOffice.org from the command line, in what is basically the "-headless -invisible" mode.

As part of this process, I took a sample BASIC macro that "prints" a Writer document to a PostScript file - similar to this:

   http://www.oooforum.org/forum/viewtopic.phtml?t=3388&highlight=printer

I can invoke the macro with "-hidden -invisible "macro:///mymacroname(someargs)" and indeed I get my PostScript output; my version of the macro adds the Wait and FileName properties to the com.sun.star.view.XPrintable object and passes the source document, destination PostScript filename, and target printer as arguments. I then transliterated the macro into a stand-alone bit of Java that I can also invoke from the command line.

At the moment, my Java makes use of com.sun.star.uno.XComponentContext.Bootstrap, and so it fires up a full version of OOo in the background. The good news is that as a "daemon" it is much faster - after the first document has been processed - but the footprint remains the same for memory use. As a next step, I would like to further trim the daemon OOo process's footprint. E.g., since it is running "-headless -invisible" (I pass in the "Hidden" property to com.sun.star.frame.XComponentLoader's loadComponentFromURL()) I would like to make sure that little or no GUI-related code gets loaded.

In cppuhelper/source/shlib.cxx and sal/osl/unx/module.c I see hooks for loading shared libraries. I see references to osl_loadModule() in literally scores of files. Is there a roadmap or project that would help me identify which additional shared-object libraries that are currently resolved at soffice.bin runtime could instead be dynamically loaded/resolved on demand?

My hope is to move from monolithic UNO/soffice.bin daemon to a lighter weight, load-on-demand daemon. I appreciate that in some cases this could mean that the first time a function/component/UNO-object is used it might incur overhead at the time, but this would be balanced by reduced resource use and faster initial load time.

Thanks for any thoughts or pointers.

-Del

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to