Code example for Preferences

Methods: getBoolean

0
    public void setLandscape(boolean value) {
        set("landscape", value);
    } 
 
    public boolean isAutoShow() { 
        return applicationPreferences.getBoolean("autoShow", false);
    } 
 
    public void setAutoShow(boolean value) {
        set("autoShow", value);
    } 
 
 
    private void set(String name, String value) {
        String old = applicationPreferences.get(name, "");
        applicationPreferences.put(name, value);
        savePreferences(); 
        propSupport.firePropertyChange(name, old, value);
    } 
 
Contextual code suggestions in your IDE  Get Codota for Java