In some cases, it puzzled me, but I'm not sure I can give you the full answer.
Firstly, my org.eclipse.core.resources.prefs files never include a timestamp! I have other preference files, such as org.eclipse.jdt.ui.prefs , which always have a timestamp. In my current setup, they never look overly updated.
There are several generations of preference APIs
org.eclipse.core.runtime.Preferences - Access via Plugin.getPluginPreferences() - Deprecated in Eclipse 3.0; Now imitated - do not use it!org.eclipse.jface.preference.* - Access via AbstractUIPlugin.getPreferenceStore() - Replaced in Eclipse 3.1; now modeled - used for field editorsorg.eclipse.core.runtime.preferences.* - Access via Platform.getPreferencesService() - based on the OSGi preference service
Those preferences that use the third generation API, reading and writing preference files, as always, occur through EclipsePreferences . This class does the βrightβ thing and removes the timestamp.
In some cases, for example, when formatting is processed in JDT, a special org.eclipse.jface.preference.PreferenceStore . This class will not work, just write a timestamp.
Why this class is used and exactly when it is used is not very clear from the code ...
One thing is certain, but I cannot find a way to avoid this!
Tonny madsen
source share