org.rhq.enterprise.installer
Class PropertyItem

java.lang.Object
  extended by org.rhq.enterprise.installer.PropertyItem

public class PropertyItem
extends Object

Defines generic information about one particular server property setting (all except its value - see PropertyItemWithValue for that).

If a property change requires the application server to restart in order for the change to take effect, isRequiresRestart() will be true.

If a property's value is to be considered a secret (like a password), then isSecret() will be true.

If a property is considered an advanced setting, one that many users, especially beginners, should not be concerned about most times, then isAdvanced() will be true.

Each property has a name that corresponds to the actual property name as found in the properties file. There is a resource bundle key associated with each property that corresponds to the property's human readable label. The localized label is usually what you want to display to the user, since the property names themselves may be cryptic to most users.

Author:
John Mazzitelli

Constructor Summary
PropertyItem(String name, Class<?> type, String labelBundleKey, String helpBundleKey, boolean requiresRestart, boolean secret, boolean advanced)
           
PropertyItem(String name, Class<?> type, String labelBundleKey, String helpBundleKey, boolean requiresRestart, boolean secret, boolean advanced, boolean hidden)
           
PropertyItem(String name, Class<?> type, String labelBundleKey, String helpBundleKey, boolean requiresRestart, boolean secret, boolean advanced, List<javax.faces.model.SelectItem> options)
          Use this constructor to define a property that is rendered with a drop down box of options to choose from.
 
Method Summary
 boolean equals(Object o)
           
 int getFieldSize()
           
 String getHelp()
           
 String getHelpResourceBundleKey()
           
 List<javax.faces.model.SelectItem> getOptions()
           
 String getPropertyLabel()
           
 String getPropertyLabelResourceBundleKey()
           
 String getPropertyName()
           
 Class<?> getPropertyType()
           
 int hashCode()
           
 boolean isAdvanced()
           
 boolean isHidden()
           
 boolean isRequiresRestart()
           
 boolean isSecret()
           
 void setAdvanced(boolean hidden)
           
 void setFieldSize(int fieldSize)
           
 void setHelpResourceBundleKey(String helpResourceBundleKey)
           
 void setHidden(boolean hidden)
           
 void setOptions(List<javax.faces.model.SelectItem> options)
           
 void setPropertyLabelResourceBundleKey(String propertyLabelResourceBundleKey)
           
 void setPropertyName(String propertyName)
           
 void setPropertyType(Class<?> propertyType)
           
 void setRequiresRestart(boolean requiresRestart)
           
 void setSecret(boolean secret)
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PropertyItem

public PropertyItem(String name,
                    Class<?> type,
                    String labelBundleKey,
                    String helpBundleKey,
                    boolean requiresRestart,
                    boolean secret,
                    boolean advanced,
                    boolean hidden)

PropertyItem

public PropertyItem(String name,
                    Class<?> type,
                    String labelBundleKey,
                    String helpBundleKey,
                    boolean requiresRestart,
                    boolean secret,
                    boolean advanced)

PropertyItem

public PropertyItem(String name,
                    Class<?> type,
                    String labelBundleKey,
                    String helpBundleKey,
                    boolean requiresRestart,
                    boolean secret,
                    boolean advanced,
                    List<javax.faces.model.SelectItem> options)
Use this constructor to define a property that is rendered with a drop down box of options to choose from.

Method Detail

getPropertyName

public String getPropertyName()

setPropertyName

public void setPropertyName(String propertyName)

getPropertyType

public Class<?> getPropertyType()

setPropertyType

public void setPropertyType(Class<?> propertyType)

getFieldSize

public int getFieldSize()

setFieldSize

public void setFieldSize(int fieldSize)

isRequiresRestart

public boolean isRequiresRestart()

setRequiresRestart

public void setRequiresRestart(boolean requiresRestart)

isSecret

public boolean isSecret()

setSecret

public void setSecret(boolean secret)

isAdvanced

public boolean isAdvanced()

getOptions

public List<javax.faces.model.SelectItem> getOptions()

setOptions

public void setOptions(List<javax.faces.model.SelectItem> options)

setAdvanced

public void setAdvanced(boolean hidden)

isHidden

public boolean isHidden()

setHidden

public void setHidden(boolean hidden)

getPropertyLabelResourceBundleKey

public String getPropertyLabelResourceBundleKey()

setPropertyLabelResourceBundleKey

public void setPropertyLabelResourceBundleKey(String propertyLabelResourceBundleKey)

getHelpResourceBundleKey

public String getHelpResourceBundleKey()

setHelpResourceBundleKey

public void setHelpResourceBundleKey(String helpResourceBundleKey)

getPropertyLabel

public String getPropertyLabel()

getHelp

public String getHelp()

equals

public boolean equals(Object o)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object


Copyright © 2008-2012 Red Hat, Inc.. All Rights Reserved.