[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
[ptp-dev] About storing constants and default values
|
Hi,
I would like to share some experience for a requirement I describe:
I am wondering the best approach to store and read:
- Default values for preferences/launches/etc.
- Other configuration values/constants that that should no stay hard
coded in plugin.
One approach is leaving them in a property file inside the plugin,
together with the source code or in a directory dedicated for this purpose.
I would then get the inputstream for this file and create a Properties
object.
Another solution would be getBundle()/getString() or even extending NLS.
But I feel I should not use this approach because it is designed for UI
messages and allows overriding the files on different locals, what is
not my intention.
Another alternative would be saving the value inside the .options file.
Would this confuse the tracing launch tab when launching eclipse? And
will be options be easily readable? I have found only methods to get
debug options.
Best regards,
Daniel Felix Ferber