Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Web Tools Project (WTP) » Update Project Explorer with new contents of war file
Update Project Explorer with new contents of war file [message #669293] Mon, 09 May 2011 15:09
Adam Steiner is currently offline Adam Steiner
Messages: 4
Registered: July 2009
Junior Member
I wrote a plugin to extract the contents of a war file and repackage the war file with changes my plugin made to the web.xml file.

I have an enterprise application project, this project has a war file as a reference. The war file is located at the root level of the enterprise application project.

When the war file is repackaged, the deployment descriptor node under the binary module folder of the enterprise application project does not pickup my changes made to the web.xml file in the project explorer. The war file in the workspace however does contain the changes I made to the web.xml file.

Any suggestions as to what I'm doing wrong?

The Process:
The unpacking of the war file is done to a temp directory and the web.xml changes are made in the temp directory. The contents of the temp directory are then written out to a temporary zip file. An InputStream is gotten from the temporary zip file and is used to write back to the original war file using ((IFile)warResource).setContents() method which I pass FileInputStream, true, true, (instance of IProgressMonitor).
The use of the setContents method makes it a workspace aware operation, right?
This whole process is done inside of a WorkspaceJob.
Previous Topic:Install from repositories fails
Next Topic:File paths in static web project
Goto Forum:
  


Current Time: Sat Aug 23 07:39:40 EDT 2014

Powered by FUDForum. Page generated in 0.01652 seconds