alvinalexander.com | career | drupal | java | mac | mysql | perl | scala | uml | unix  

What this is

This file is included in the DevDaily.com "Java Source Code Warehouse" project. The intent of this project is to help you "Learn Java by Example" TM.

Other links

The source code

/*
 *                 Sun Public License Notice
 *
 * The contents of this file are subject to the Sun Public License
 * Version 1.0 (the "License"). You may not use this file except in
 * compliance with the License. A copy of the License is available at
 * http://www.sun.com/
 *
 * The Original Code is NetBeans. The Initial Developer of the Original
 * Code is Ralph Krueger. 
 */

package org.netbeans.modules.changelog.settings;

import org.openide.options.*;
import org.openide.util.*;

/** Options for changelog module
*
* @author Ralph krueger
*/
public class ChangeLogSettings extends SystemOption {

    public static final String PROP_DEFAULT_SERVER = "defaultServerInfo"; // NOI18N

    public static final String PROP_SHOW_BRANCHES = "showBranchesByDefault"; //NOI18N
    
    static final long serialVersionUID = -1563396366224442828L;

    public ChangeLogSettings() {
        setDefaultServerInfo("");
        setShowBranchesByDefault(false);
    }
    

    /** human presentable name */
    public String displayName() {
        return NbBundle.getBundle(ChangeLogSettings.class).getString("CTL_ChangeLog_settings"); // NOI18N
    }


    public HelpCtx getHelpCtx () {
        return new HelpCtx (ChangeLogSettings.class);
    }
    
    /** Getter for property defaultServerInfo.
     * @return Value of property defaultServerInfo.
     */
    public String getDefaultServerInfo() {
        return (String)getProperty(PROP_DEFAULT_SERVER);
    }
    
    /** Setter for property defaultServerInfo.
     * @param defaultServerInfo New value of property defaultServerInfo.
     */
    public void setDefaultServerInfo(String defaultServerInfo) {
        putProperty(PROP_DEFAULT_SERVER, defaultServerInfo, true);
    }
    
    /** Getter for property showBranchesByDefault.
     * @return Value of property showBranchesByDefault.
     */
    public boolean isShowBranchesByDefault() {
        return ((Boolean)getProperty(PROP_SHOW_BRANCHES)).booleanValue();
    }
    
    /** Setter for property showBranchesByDefault.
     * @param showBranchesByDefault New value of property showBranchesByDefault.
     */
    public void setShowBranchesByDefault(boolean showBranchesByDefault) {
        putProperty(PROP_SHOW_BRANCHES, showBranchesByDefault ? Boolean.TRUE : Boolean.FALSE);
    }
    
}
... this post is sponsored by my books ...

#1 New Release!

FP Best Seller

 

new blog posts

 

Copyright 1998-2021 Alvin Alexander, alvinalexander.com
All Rights Reserved.

A percentage of advertising revenue from
pages under the /java/jwarehouse URI on this website is
paid back to open source projects.