Package com.sun.interview
Class PropertiesQuestion.BooleanConstraints
java.lang.Object
com.sun.interview.PropertiesQuestion.ValueConstraints
com.sun.interview.PropertiesQuestion.BooleanConstraints
- Enclosing class:
PropertiesQuestion
public static class PropertiesQuestion.BooleanConstraints
extends PropertiesQuestion.ValueConstraints
Constraints allowing a value to be either a boolean or Yes/No response.
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionBooleanConstraints
(boolean isYesNo) BooleanConstraints
(boolean isYesNo, boolean unsetAllowed) -
Method Summary
Modifier and TypeMethodDescriptionboolean
isYesNo()
Is this a yes/no field, instead of the default true/false?void
setUseYesNo
(boolean state) Indicate whether this should be a Yes/No question or True/False.Methods inherited from class com.sun.interview.PropertiesQuestion.ValueConstraints
isReadOnly, isUnsetAllowed, isValid, isVisible, setReadOnly, setUnsetAllowed, setVisible
-
Field Details
-
YES
- See Also:
-
NO
- See Also:
-
TRUE
- See Also:
-
FALSE
- See Also:
-
-
Constructor Details
-
BooleanConstraints
public BooleanConstraints() -
BooleanConstraints
public BooleanConstraints(boolean isYesNo) - Parameters:
isYesNo
- Should this question be presented as a Yes/No question rather than a True/False.- See Also:
-
BooleanConstraints
public BooleanConstraints(boolean isYesNo, boolean unsetAllowed) - Parameters:
isYesNo
- Should this question be presented as a Yes/No question rather than a True/False.unsetAllowed
- Can the question be set to have no value.- See Also:
-
-
Method Details
-
setUseYesNo
public void setUseYesNo(boolean state) Indicate whether this should be a Yes/No question or True/False.- Parameters:
state
- True if this should be rendered as a Yes/No question, false if it should be a boolean true/false.- See Also:
-
isYesNo
public boolean isYesNo()Is this a yes/no field, instead of the default true/false?- Returns:
- True if this is a Yes/No question, false if it is a True/False question.
- See Also:
-