Java Preference Remove removePref(String prefName, Object obj)

Here you can find the source of removePref(String prefName, Object obj)

Description

remove Pref

License

Open Source License

Declaration

public static void removePref(String prefName, Object obj) 

Method Source Code

//package com.java2s;
// under the terms of the GNU Lesser General Public License as published by

import java.util.prefs.Preferences;

public class Main {
    public static void removePref(String prefName, Object obj) {
        Preferences prefs = Preferences.userNodeForPackage(obj.getClass());
        prefs.remove(prefName);//  www  .  jav a  2s.c  om
    }
}

Related

  1. removeAll(Preferences prefs, boolean deep)
  2. removeCLOB(Preferences prefs, String key)
  3. removeKeys(Preferences prefs, String key, int from, int to)
  4. resetPreferences()