com.mentata.sg8
Class SG8PasswordAttribute
java.lang.Object
com.mentata.l3d.L3DAttribute
com.mentata.sg8.SG8StringAttribute
com.mentata.sg8.SG8PasswordAttribute
- All Implemented Interfaces:
- Comparator, SG8Attribute
- public class SG8PasswordAttribute
- extends SG8StringAttribute
An attribute representing a password for use with SG8 objects.
This attribute type suppresses all displayable output of values. Instances return duplicate password text fields as update form elements, validating a new value by ensuring a match.
- Since:
- 0.7
- Author:
- Jon Roberts
| Methods inherited from class com.mentata.l3d.L3DAttribute |
addValue, compare, getAttribute, getBind, getContext, getLabel, getLengthThreshold, getName, getObject, getObject, getPrerequisites, getSize, getThreshold, getValues, initialize, isBound, isExceeded, isGenerated, isLengthExceeded, isMultivalue, isRequired, removeValue, same, setGenerated, setLabel, setLengthThreshold, setPrerequisites, setThreshold, setValues |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SG8PasswordAttribute
public SG8PasswordAttribute()
getShortValues
public String[] getShortValues()
- Returns an indication that the attribute values are not for display.
- Overrides:
getShortValues in class L3DAttribute
- Returns:
- a single value array indicating passwords can not be displayed
getHTMLValues
public String[] getHTMLValues()
- Returns an indication that the attribute values are not for display.
- Specified by:
getHTMLValues in interface SG8Attribute- Overrides:
getHTMLValues in class SG8StringAttribute
- Returns:
- a single value array indicating passwords can not be displayed
getUpdateHTML
public String getUpdateHTML()
throws SG8Exception
- Returns HTML form elements for modifying the attribute.
- Specified by:
getUpdateHTML in interface SG8Attribute- Overrides:
getUpdateHTML in class SG8StringAttribute
- Returns:
- the HTML modification form elements
- Throws:
SG8Exception - if the attribute is generated
processUpdateHTML
public boolean processUpdateHTML(HttpServletRequest req)
throws SG8Exception
- Reads and processes attribute changes from relevant HTML request form parameters.
- Specified by:
processUpdateHTML in interface SG8Attribute- Overrides:
processUpdateHTML in class SG8StringAttribute
- Parameters:
req - a servlet request
- Returns:
- whether the attribute values changed
- Throws:
SG8Exception - if form values are inappropriate or the attribute is generated