Re: Does anyone know if I can automate the Firefox Opening and Cache Clearing with Java or Javascript?

JanakiRam <[email protected]>
Newsgroups gmane.comp.mozilla.devel.oji
Organization http://groups.google.com
Message-ID <[email protected]>
Hi Rafael,

          We can clear the cache using XPCOM Component method. The
following javascript code will clear the cache of the browser.

	const cc = Components.classes;
	const ci = Components.interfaces;
	var cacheService =         cc["@mozilla.org/network/cache-service;
1"].getService(ci.nsICacheService);

		cacheService.evictEntries(ci.nsICache.STORE_ANYWHERE);

     How do you want to automate the cache clearing process.Are you
starting the XUL Application from Java using JavaXPCOM. If this is so
-- place the following code in the XULApplication initialization.



-JanakiRam.


On May 31, 10:45 pm, Rafael <[email protected]> wrote:
> Does anyone know if I can automate the Firefox Opening and Cache
> Clearing with Java or Javascript?
>
> PS.: I don't want to clear the cache providing the application the
> cache files directory, I want to clean accessing the Menu Tools.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.