BooleanControl provides the ability to switch between two possible
settings that affect a line's audio. The settings are boolean values
(true and false). A graphical user interface might represent
the control by a two-state button, an on/off switch, two mutually exclusive
buttons, or a checkbox (among other possibilities). For example, depressing a
button might activate a MUTE control to
silence the line's audio.
As with other Control subclasses, a method is provided that returns
string labels for the values, suitable for display in the user interface.
| Modifier and Type | Class and Description |
|---|---|
| public static class | BooleanControl.
An instance of the |
| Modifier and Type | Field and Description |
|---|---|
| private final String | falseStateLabel
The |
| private final String | trueStateLabel
The |
| private boolean | value
The current value. |
| Access | Constructor and Description |
|---|---|
| protected | BooleanControl(BooleanControl.
the type of control represented this float control object type,the initial control value initialValue, String the label for the state represented by
trueStateLabel, String true, such as "true" or "on"the label for the state represented by
falseStateLabel)false, such as "false" or "off"Constructs a new boolean control object with the given parameters. |
| protected | BooleanControl(BooleanControl.
the type of control represented by this float control object type,the initial control value initialValue)Constructs a new boolean control object with the given parameters. |
| Modifier and Type | Method and Description |
|---|---|
| public String | Returns: the label for the specified state, such as "true" or "on" fortrue, or "false" or "off" for falsethe state whose label will be returned state)Obtains the label for the specified state. |
| public boolean | |
| public void | |
| public String | Returns: a string representation of the boolean controlOverrides javax. Returns a string representation of the boolean control. |
| falseStateLabel | back to summary |
|---|---|
| private final String falseStateLabel The | |
| trueStateLabel | back to summary |
|---|---|
| private final String trueStateLabel The | |
| value | back to summary |
|---|---|
| private boolean value The current value. | |
| BooleanControl | back to summary |
|---|---|
| protected BooleanControl(BooleanControl. Constructs a new boolean control object with the given parameters.
| |
| BooleanControl | back to summary |
|---|---|
| protected BooleanControl(BooleanControl. Constructs a new boolean control object with the given parameters. The
labels for the
| |
| getStateLabel | back to summary |
|---|---|
| public String getStateLabel(boolean state) Obtains the label for the specified state.
| |
| getValue | back to summary |
|---|---|
| public boolean getValue() Obtains this control's current value.
| |
| setValue | back to summary |
|---|---|
| public void setValue(boolean value) Sets the current value for the control. The default implementation simply sets the value as indicated. Some controls require that their line be open before they can be affected by setting a value.
| |
| toString | back to summary |
|---|---|
| public String toString() Overrides javax. Returns a string representation of the boolean control. | |
BooleanControl.Type class identifies one kind
of boolean control. Static instances are provided for the common types.
| Modifier and Type | Field and Description |
|---|---|
| public static final BooleanControl. | APPLY_REVERB
Represents a control for whether reverberation is applied to a line. |
| public static final BooleanControl. | MUTE
Represents a control for the mute status of a line. |
| Access | Constructor and Description |
|---|---|
| protected |
| APPLY_REVERB | back to summary |
|---|---|
| public static final BooleanControl. Represents a control for whether reverberation is applied to a line. Note that the status of this control not affect the reverberation settings for a line, but does affect whether these settings are used. | |
| MUTE | back to summary |
|---|---|
| public static final BooleanControl. Represents a control for the mute status of a line. Note that mute status does not affect gain. | |
| Type | back to summary |
|---|---|
| protected Type(final String name) Constructs a new boolean control type.
| |