Skip to main content



      Home
Home » Eclipse Projects » Eclipse Platform » ResourceBundle, and need the file path as a String
ResourceBundle, and need the file path as a String [message #43954] Thu, 22 May 2003 12:09 Go to next message
Eclipse UserFriend
Originally posted by: mouse7m.hotmail.com

I have a ResourceBundle, and need it's file path as a String. how can i do
this in Eclipse plug-in entwicklung? am best is an example. thanks.

Filix
Re: ResourceBundle, and need the file path as a String [message #44231 is a reply to message #43954] Thu, 22 May 2003 13:08 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: olivier_thomann.nospam.oti.com

On Thu, 22 May 2003 16:09:30 +0000 (UTC), mouse7m@hotmail.com (Filix)
wrote:
>I have a ResourceBundle, and need it's file path as a String. how can i do
>this in Eclipse plug-in entwicklung? am best is an example. thanks.
It doesn't need its path, it simply needs its fully qualified name. As
long as you put the .properties file in the classpath, it should work.
For example:

ResourceBundle.getBundle("org.eclipse.jdt.internal.antadapter.messages ",
Locale.getDefault());

will try to load the file messages.properties located in the package
org.eclipse.jdt.internal.antadapter. If this package is on the
classpath and the messages.properties is inside this package, then it
should be found. You can have multiple messages_xx_xx.properties files
to handle different locales.
--
Olivier
Re: ResourceBundle, and need the file path as a String [message #44289 is a reply to message #44231] Thu, 22 May 2003 13:22 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: mouse7m.hotmail.com

> It doesn\'t need its path, it simply needs its fully qualified name. As
> long as you put the .properties file in the classpath, it should work.
> For example:

> ResourceBundle.getBundle(\"org.eclipse.jdt.internal.antadapter.messages\ ",
> Locale.getDefault());

> will try to load the file messages.properties located in the package
> org.eclipse.jdt.internal.antadapter. If this package is on the
> classpath and the messages.properties is inside this package, then it
> should be found. You can have multiple messages_xx_xx.properties files
> to handle different locales.
> --
> Olivier

thank you, but if I want to create another file in the same directory, i
still need to get out its path, or there is any other way to do this?

Felix
Re: ResourceBundle, and need the file path as a String [message #44319 is a reply to message #44289] Thu, 22 May 2003 13:38 Go to previous message
Eclipse UserFriend
Originally posted by: Olivier_Thomann.ca.ibm.comNOSPAM

On Thu, 22 May 2003 17:22:24 +0000 (UTC), mouse7m@hotmail.com (Felix)
wrote:
>thank you, but if I want to create another file in the same directory, i
>still need to get out its path, or there is any other way to do this?
Why do you need to create a file in the same directory and use it with
a resource bundle?
Please describe what you are trying to do.
--
Olivier
Previous Topic:Image display/information view available?
Next Topic:Umlauts in files get lost under linux
Goto Forum:
  


Current Time: Mon Jul 07 04:31:25 EDT 2025

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

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

Back to the top