org.apache.tapestry.form
Class AbstractFormComponentContributor
java.lang.Object
org.apache.tapestry.form.AbstractFormComponentContributor
- All Implemented Interfaces:
- FormComponentContributor
- Direct Known Subclasses:
- AbstractTranslator
public abstract class AbstractFormComponentContributor
- extends java.lang.Object
- implements FormComponentContributor
Abstract FormComponentContributor
implementation that adds an optional static javscript
method reference to the page.
- Since:
- 4.0
- Author:
- Paul Ferraro
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AbstractFormComponentContributor
public AbstractFormComponentContributor()
AbstractFormComponentContributor
public AbstractFormComponentContributor(java.lang.String initializer)
defaultScript
protected java.lang.String defaultScript()
- Defines the default JavaScript file used by this contributor. Overriden by most subclasses
that use JavaScript.
getScript
public java.lang.String getScript()
setScript
public void setScript(java.lang.String script)
renderContribution
public void renderContribution(IMarkupWriter writer,
IRequestCycle cycle,
FormComponentContributorContext context,
IFormComponent field)
- Description copied from interface:
FormComponentContributor
- Invoked by a form component after it finishes rendering its tag (but before the tag is
closed) to allow this object to contribute to the component's rendering process. Typically
used by Validators and Translators to add javascript methods to the form's submit event
handler.
- Specified by:
renderContribution
in interface FormComponentContributor
- Parameters:
writer
- allows contributor to write additional attributes into the component's tagcycle
- for accessing request informationcontext
- utilities for genering messages and client-side validationfield
- the field for which contributions are being rendered- See Also:
FormComponentContributor.renderContribution(org.apache.tapestry.IMarkupWriter,
org.apache.tapestry.IRequestCycle, FormComponentContributorContext,
org.apache.tapestry.form.IFormComponent)