|
Decision Center API | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object ilog.webui.dhtml.IlxWContainer ilog.webui.dhtml.IlxWComponent ilog.webui.dhtml.components.IlxWButton
public class IlxWButton
This class implements a simple button component.
A button component is rendered on the web browser as an
<input type="submit">
element.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class ilog.webui.dhtml.IlxWComponent |
---|
IlxWComponent.DynamicStyleMap |
Field Summary |
---|
Fields inherited from class ilog.webui.dhtml.IlxWContainer |
---|
listenerList |
Constructor Summary | |
---|---|
IlxWButton()
Constructs an empty button, with no text. |
|
IlxWButton(String text)
Constructs a button with the given caption. |
Method Summary | |
---|---|
void |
addActionListener(ActionListener listener)
Adds the specified action listener. |
protected IlxWAction |
createDefaultAction()
Create the default action. |
protected void |
doPrint(IlxWPort port)
|
protected void |
fireActionPerformed()
Notifies all action listeners than an action has been triggered, using the text of the button as the name of the event command. |
IlxWAction |
getAction()
Gets the action which will be called when the user clicks on the button. |
String |
getText()
Gets the text displayed in the button |
boolean |
isEnabled()
Specifies whether the component is enabled or not. |
protected void |
printComponent(IlxWPort port)
Prints the HTML code that will display the graphical representation of this component. |
void |
removeActionListener(ActionListener listener)
Removes the specified action listener. |
void |
setAction(IlxWAction action)
Sets the action which will be called when the user clicks on this button. |
void |
setEnabled(boolean enabled)
Sets the component as enabled or disabled. |
void |
setText(String text)
Sets the text to display in the button. |
Methods inherited from class ilog.webui.dhtml.IlxWComponent |
---|
addPropertyChangeListener, addPropertyChangeListener, detach, firePropertyChange, firePropertyChange, getName, getRealHtmlTagName, getStyle, invalidate, isInvalidated, notifyDependencies, print, removePropertyChangeListener, removePropertyChangeListener, setName, validate |
Methods inherited from class ilog.webui.dhtml.IlxWContainer |
---|
add, add, getAttribute, getAttributeNames, getComponent, getComponentCount, getComponentNamed, getComponents, getManager, getParent, getUserAgentRules, indexOf, isAncestorOf, remove, remove, removeAll, removeAttribute, setAttribute, setAuthorRules, setFinalizer |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public IlxWButton()
public IlxWButton(String text)
text
- The text to display in the button.Method Detail |
---|
public void setText(String text)
text
- any stringpublic String getText()
public void setEnabled(boolean enabled)
enabled
- enabled flag valuepublic boolean isEnabled()
true
if the button is enabled.public void setAction(IlxWAction action)
action
- The action to perform when the user clicks on the button.getAction()
public IlxWAction getAction()
By default, this action is a Java action (IlxWJavaAction
)
of which the perform
method calls
fireActionPerformed
on the button.
setAction(ilog.webui.dhtml.components.IlxWAction)
protected IlxWAction createDefaultAction()
perform
method simply calls fireActionPerformed
.
setAction(ilog.webui.dhtml.components.IlxWAction)
protected void doPrint(IlxWPort port) throws IOException
doPrint
in class IlxWComponent
IOException
protected void printComponent(IlxWPort port) throws IOException
IlxWComponent
IlxWComponent.print(ilog.webui.dhtml.IlxWPort)
method.
printComponent
in class IlxWComponent
IOException
port
- The port on which the component will be printed.IlxWComponent.print(ilog.webui.dhtml.IlxWPort)
public void addActionListener(ActionListener listener)
listener
- the action listenerpublic void removeActionListener(ActionListener listener)
listener
- the action listenerprotected void fireActionPerformed()
|
Decision Center API | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |