|
Apache JMeter | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.awt.Component java.awt.Container javax.swing.JComponent javax.swing.JPanel org.apache.jorphan.gui.JLabeledChoice
public class JLabeledChoice
Nested Class Summary |
---|
Nested classes/interfaces inherited from class javax.swing.JPanel |
---|
JPanel.AccessibleJPanel |
Nested classes/interfaces inherited from class javax.swing.JComponent |
---|
JComponent.AccessibleJComponent |
Nested classes/interfaces inherited from class java.awt.Container |
---|
Container.AccessibleAWTContainer |
Nested classes/interfaces inherited from class java.awt.Component |
---|
Component.AccessibleAWTComponent, Component.BltBufferStrategy, Component.FlipBufferStrategy |
Field Summary |
---|
Fields inherited from class javax.swing.JComponent |
---|
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
Fields inherited from class java.awt.Component |
---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Fields inherited from interface java.awt.image.ImageObserver |
---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
---|---|
JLabeledChoice()
Default constructor, The label and the Text field are left empty. |
|
JLabeledChoice(String pLabel,
boolean editable)
|
|
JLabeledChoice(String pLabel,
String[] items)
Constructs a non-edittable combo-box with the label displaying the passed text. |
|
JLabeledChoice(String pLabel,
String[] items,
boolean editable)
Constructs a combo-box with the label displaying the passed text. |
Method Summary | |
---|---|
void |
addChangeListener(ChangeListener pChangeListener)
Adds a change listener, that will be notified when the text in the text field is changed. |
void |
addValue(String item)
|
List<JComponent> |
getComponentList()
Get the label JLabel followed by the combo-box @link JComboBox . |
String[] |
getItems()
|
String |
getLabel()
Returns the text of the label. |
int |
getSelectedIndex()
|
Object[] |
getSelectedItems()
|
String |
getText()
Returns the text in the Text Field. |
String |
getToolTipText()
Returns the tooltip string that has been set with setToolTipText |
void |
removeChangeListener(ChangeListener pChangeListener)
Removes a change listener. |
void |
setEditable(boolean editable)
|
void |
setLabel(String pLabel)
Set the text displayed in the label. |
void |
setSelectedIndex(int index)
|
void |
setText(String pText)
Set the text displayed in the Text Field. |
void |
setToolTipText(String text)
Registers the text to display in a tool tip. |
void |
setValues(String[] items)
|
Methods inherited from class javax.swing.JPanel |
---|
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public JLabeledChoice()
public JLabeledChoice(String pLabel, boolean editable)
public JLabeledChoice(String pLabel, String[] items)
pLabel
- - the text to display in the label.items
- - the items to display in the Combo boxpublic JLabeledChoice(String pLabel, String[] items, boolean editable)
pLabel
- - the text to display in the label.items
- - the items to display in the Combo boxeditable
- - if true, then Add and Delete buttons are created.Method Detail |
---|
public List<JComponent> getComponentList()
JLabel
followed by the combo-box @link JComboBox
.
getComponentList
in interface JLabeledField
public void setEditable(boolean editable)
public void addValue(String item)
public void setValues(String[] items)
public void setLabel(String pLabel)
setLabel
in interface JLabeledField
pLabel
- The new label text.public void setText(String pText)
setText
in interface JLabeledField
pText
- The new text to display in the text field.public void setSelectedIndex(int index)
public String getText()
getText
in interface JLabeledField
public int getSelectedIndex()
public Object[] getSelectedItems()
public String[] getItems()
public String getLabel()
public void setToolTipText(String text)
setToolTipText
in class JComponent
text
- the string to display; if the text is null,
the tool tip is turned off for this componentpublic String getToolTipText()
getToolTipText
in class JComponent
public void addChangeListener(ChangeListener pChangeListener)
getText
method.
addChangeListener
in interface JLabeledField
pChangeListener
- The listener to addpublic void removeChangeListener(ChangeListener pChangeListener)
pChangeListener
- The change listener to remove.
|
Apache JMeter | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |