|
||||||||||
| PREV PACKAGE NEXT PACKAGE | FRAMES NO FRAMES | |||||||||
See:
Description
| Class Summary | |
|---|---|
| ClassDefTagHandler | Genrates all Slug related JavaScript Classes. |
| SlugMgrTagHandler | Generates SlugMgr JavaScript instance. |
Slug's JSP Tag Library.

SimpleTag, which is available in JSP 2.0 API.
SluggishProcess live time.
As a result application session will be kept “alive” until monitored process is not completed.

internal and external.
When used in its internal form the tag generates all JavaScript Objects localy in current page.
When used in its external form the tag generates only a script link to an external JavaScript
file provided by the src patameter.
| Parameter | Type | Default | Description | Mode | Is required |
|---|---|---|---|---|---|
| src | String | URL to a JavaScript file providing all Slug JavaScript Objects. If present script tag is swithced to external mode. | external | No | |
| xmlFormat | boolean | false | Specify where produced script tag will be in HTML 4.1 (false) or XHTML (true) compatible. | internal | No |
| rawScript | boolean | false | Specify where script tag should be omited in during script's generation. If set to true it would ommit the enclosing scritp tag. | internal | No |
Examples:
Internal declaration:
<slug:script />
External declaration:
<slug:script src="scripts.jsp" />
SlugMgr Object and puts its instance in to service.inline or function call.
In the inline mode user's event processing code is entered directly in the tag's body while in the function call
more of operation only a reference to external, already defined, JavaScript function is provided.
| Parameter | Type | Default | Description | Mode | Is required |
|---|---|---|---|---|---|
| name | String | Name of the SlugMgr instance. | both | Yes | |
| pid | String | SlugProcess PID. | both | Yes | |
| updateFunction | String | User defined ervent handler. Required functions signature is updateHndlr(SlugMgr, ProcessStaus). | function call | Yes, if no body is provided. | |
| url | String | URL to the Slut Servlet. | both | Yes | |
| translator | String | Default translator in the config file | Transaltor's name as defined in Slug's config. | both | No |
| runner | String | Default runner in the config file | Runner's name as defined in Slug's config. | both | No |
| refresh | int | 500 (1/2 second) | Specify where script tag should be omited in during script's generation. If set to true it would ommit the enclosing scritp tag. | both | No |
| errorFunction | String | alert ('Error server status: ' + status); | Error processing hanler. Required function signature is errorHndlr(respStatus), where respStatus is HTTP response status code. | both | No |
Examples:
Inline declaration:
<slug:script />
<slug:manage name="mySlug" pid="<%= pid %>" url="../slug" refresh="1000">
document.getElementById("prStatus").innerHTML = ps.toString();
</slug:manage>
Function call declaration:
<slug:script />
<SCRIPT TYPE="text/javascript">
<!--
/**
* Updates html body with process status.
* @param smgr calling SlugMgr instance.
* @param ps current ProcessStaus instance.
*/
function updateHndlr(smgr, ps) {
...
}
/**
* Error processing functoin.
* @param respStatus server response status code.
*/
function errorHndlr(respStatus) {
...
}
// -->
</SCRIPT>
<slug:manage name="mySlug" pid="<%= pid %>" updateFunction="updateHndlr" errorFunction="errorHndlr" url="../slug" translator="js" />
|
||||||||||
| PREV PACKAGE NEXT PACKAGE | FRAMES NO FRAMES | |||||||||