|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.zkoss.zk.ui.metainfo.WidgetListener
public class WidgetListener
Represents a client-side event listener for the peer widget.
Notice that, unlike WidgetOverride
, getScript()
has only
the function's body (without function (event)
).
EventHandler
,
WidgetOverride
,
Serialized FormField Summary | |
---|---|
protected ConditionImpl |
_cond
|
protected java.lang.String |
_name
|
protected java.lang.String |
_script
|
Constructor Summary | |
---|---|
WidgetListener(EvaluatorRef evalr,
java.lang.String name,
java.lang.String script,
ConditionImpl cond)
|
Method Summary | |
---|---|
void |
assign(Component comp)
|
java.lang.String |
getName()
Returns the event name, such as, onClick. |
java.lang.String |
getScript()
Returns the script associated with this event handler. |
boolean |
isEffective(Component comp)
Used to evaluate whether it is effective. |
boolean |
isEffective(Page page)
Used to evaluate whether it is effective. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected final java.lang.String _name
protected final java.lang.String _script
protected final ConditionImpl _cond
Constructor Detail |
---|
public WidgetListener(EvaluatorRef evalr, java.lang.String name, java.lang.String script, ConditionImpl cond)
name
- the event name, such as onClickevalr
- the evaluator reference. It is required if cond is not null.
java.lang.IllegalArgumentException
- if script is null
or (cond is not null but evalr is null)Method Detail |
---|
public java.lang.String getName()
public java.lang.String getScript()
public void assign(Component comp)
public boolean isEffective(Component comp)
Condition
isEffective
in interface Condition
comp
- used as the self variable. Ignored if null.public boolean isEffective(Page page)
Condition
isEffective
in interface Condition
page
- used as the self variable. Ignored if null.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |