return keyPattern;
}
public void putKeyPattern(LabelPattern pattern){
keyPattern = pattern;
LabelPattern parent = pattern.getParent();
if (parent == null)
return;
// Store overridden definitions to Preferences.
Preferences pre = Preferences.userNodeForPackage
(net.sf.jabref.labelPattern.LabelPattern.class);
try {
pre.clear(); // We remove all old entries.
} catch (BackingStoreException ex) {
Globals.logger("BackingStoreException in JabRefPreferences.putKeyPattern");
}
for (String s: pattern.keySet()){
if (!(pattern.get(s)).equals(parent.get(s)))
pre.put(s, pattern.getValue(s).get(0).toString());
}
}