|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface FormComponentContributorContext
Object that provides support to objects that implement
FormComponentContributor. For the moment, at least, this is all
about client-side JavaScript generation.
TODO: Having support for regular expressions might be useful (and would allow a single
to be shared).
| Method Summary | |
|---|---|
void |
addInitializationScript(IComponent target,
String script)
Adds initialization javascript code that will be executed on page/content/etc load. |
void |
addSubmitHandler(String handler)
Deprecated. To be removed in 4.2 with no replacement. The new preferred way to do this is by using simple dojo.event.connect("formName", "event", object, "functionName) style connections. |
JSONObject |
getProfile()
The javascript object profile being built by this context to validate/translate form values. |
void |
includeClasspathScript(String path)
Includes the indicated script; the path is a path on the classpath. |
void |
registerForFocus(int priority)
Registers a field for automatic focus. |
| Methods inherited from interface org.apache.tapestry.form.ValidationMessages |
|---|
formatValidationMessage, getLocale |
| Method Detail |
|---|
void includeClasspathScript(String path)
void addSubmitHandler(String handler)
dojo.event.connect("formName", "event", object, "functionName) style connections.
handler - either the name of a submit listener ("myListener"), or an inline implementation
of a listener function ("function(event) { ... } ").
void addInitializationScript(IComponent target,
String script)
target - The component the script is being added for.script - The javascript code to execute.void registerForFocus(int priority)
priority - a priority level used to determine whether the registered field becomes the focus
field. Constants for this purpose are defined in ValidationConstants.FormBehavior.registerForFocus(IFormComponent, int)JSONObject getProfile()
FormBehavior.
JSONObject profile.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||