Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Rich Client Platform (RCP) » properties file after export
properties file after export [message #466479] Fri, 20 April 2007 01:29 Go to next message
Eclipse UserFriend
Originally posted by: jelgolfnut.gmail.com

I have an RCP application that uses Spring JDBC. I have a properties file
that gets loading into the applicationContext.xml. I'm able to export the
app and everything works fine. The properties file is bundled in a jar
file in the exported app. Want I want to do is to be able to create this
file on the fly, but I'm not sure how to locate it or how to create it
inside the jar file since it has to be accesible to the context.xml file.
If there is a way to keep the property file out of the jar file, that
might work too. I'm open to all suggestions.
Thanks
Re: properties file after export [message #466513 is a reply to message #466479] Fri, 20 April 2007 09:43 Go to previous messageGo to next message
Alex Blewitt is currently offline Alex BlewittFriend
Messages: 946
Registered: July 2009
Senior Member
You can attach it as a fragment, which means the .properties file will be available to the bundle. If you're really cool, you can generate this fragment on the fly :-)

Alex.
Re: properties file after export [message #466562 is a reply to message #466479] Fri, 20 April 2007 21:03 Go to previous message
Patrick Paulin is currently offline Patrick PaulinFriend
Messages: 44
Registered: July 2009
Location: Madison, Wisconsin
Member
Hi Jim,

It's common for plug-ins that generate metadata on the fly to store those
files in the "state location" for the plug-in. You can access the path for
a given bundle/plug-in by calling Platform.getStateLocation(Bundle).

Physically, these locations are beneath the .metadata folder in the OSGi
instance area (workspace).

Hope this helps,

--- Patrick
patrick@rcpquickstart.com


JimL wrote:

> I have an RCP application that uses Spring JDBC. I have a properties file
> that gets loading into the applicationContext.xml. I'm able to export the
> app and everything works fine. The properties file is bundled in a jar
> file in the exported app. Want I want to do is to be able to create this
> file on the fly, but I'm not sure how to locate it or how to create it
> inside the jar file since it has to be accesible to the context.xml file.
> If there is a way to keep the property file out of the jar file, that
> might work too. I'm open to all suggestions.
> Thanks


Patrick Paulin
Eclipse RCP/OSGi Trainer and Consultant
Modular Mind, Ltd.

patrick@modumind.com
www.modumind.com
twitter.com/pjpaulin
linkedin.com/in/pjpaulin
Previous Topic:specifying exported packages
Next Topic:Help no longer works after upgrade to 3.3M6 - index.jsp 404
Goto Forum:
  


Current Time: Sat Apr 27 04:41:44 GMT 2024

Powered by FUDForum. Page generated in 0.02827 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top