In this section: |
The Telnet Designer in web deployment mode creates an XML rules file that controls your online session with appropriate JavaServer Pages (JSP) for each screen you want to run with a template. These templates change the look and feel of the screen or add functionality to the screen.
It is important to understand the effects of running a mainframe online application over the web. These effects can occur when using default translation with or without a generic template or when using the Telnet Designer template facility.
HTTP communication occurs in half-duplex mode, which means the communication occurs in both directions, but with only one entity communicating at a time. To bring Terminal Emulator capabilities to the web, the HTML translation services determine when the communication from the back end completes.
The following image illustrates the process of running a mainframe online application over the web.
The following commands are available:
It is recommended that you resynchronize each screen for either deployment method, default translation, or template modes.
The Telnet Designer enables you to control parameters that affect the Emulator console, screen navigation, and the web session. The parameters have an effect on default translation and the template facility. In a web application, the web.xml file contains these parameters.
The following table lists and describes the parameters that affect the Terminal Emulator console facility, screen navigation, the HTML web session, and the Telnet Designer.
Parameter |
Description |
---|---|
Terminal Emulator Console Facility | |
accessLog |
Logs an entry for each established session (access.log). |
user |
Authenticates the management commands for HTTP. |
password |
Is the password associated with the user. |
Screen Navigation | |
telnetTimeout |
Amount of time, in seconds, to continue to receive a response from the mainframe application. This time-out is determined by the maxTimeoutLimit and MinBufferSize parameters. A time-out is recommended when there is a possibility that partial screens will be delivered. The socket connection to the back-end application remains active across this time-out. |
maxTimeoutLimit |
Number of reads that the emulator attempts when it determines that the data received from the application might be incomplete. |
minBufferSize |
Minimum size acceptable for a Telnet screen. When the received buffer is smaller than the defined size, the adapter continues to attempt to read until the specified size is reached. |
HTML web session | |
httpTimeout |
The time, in hours, that an idle session must remain active. The time is calculated roughly between keystrokes. When an expired session is detected, the Telnet connection to the mainframe application is disconnected. |
httpTimeoutUnts |
The units, in hours or minutes, that httpTimeout indicates. The default value is hours. |
logLevel |
Used for generating logs. The log file is written to the logs subdirectory of the deployed ibitelnet webapps directory. For example: C:\Program Files\Apache Group\Tomcat 4.1\webapps \ibitelnet.war\logs Valid log levels are DEBUG, INFO, WARN, ERROR, and FATAL. The default log level is DEBUG. |
Template Mode | |
repository |
Location of the created XML rules files that contain the template rules when using the Telnet Designer in web mode. Used only in web mode when using Telnet Designer. |
Understanding the HTML service request helps you to create screen templates. The TelnetHtmlServlet controls Telnet sessions. Each HTML screen sends parameters for the TelnetHtmlServlet to handle the Telnet screen. The types of parameters are:
<input onFocus='setCursor(this.name)' type='text' value='' size='8' maxlength='8' name='12'>
Note: The names of the field must match the numbers represented in the Telnet screen.
<input type='button' value='PA1' style='font-size: 8pt' onclick='setAttention("PA1")'>
The onClick event uses a JavaScript function to set the current keyboard value in the keyboard hidden field. The Shift key is used to switch from PF1-PF12 to PF13-PF24.
These two fields track which attention key is pressed:
<input type='hidden' name='shift' value='0' size='2'> <input type='hidden' name='keyboard' value='ENTER' size='15'>
<input type='hidden' name='cursor' size='3'>
Screen templates enable you to redesign Telnet screens. The template screen is a JavaServer Page (JSP) on which Telnet HTML Services expose a screen object. The screen object obtains the dynamic value of the Telnet Session.
You can use a hyperlink equivalent to a keystroke as follows:
<!-- Issuing the attention key "CLEAR" --> <a href='TelnetHtmlServlet?keyboard=CLEAR&10=brws'>Click here to browse records</a>
You can use a hyperlink equivalent to a field and a keystroke as follows:
<!-- Entering "brws" in the field 10 and Issuing the attention key "ENTER" --> <br><a href='TelnetHtmlServlet?keyboard=ENTER&10=brws'>Click here to broBSE records</a>
You can use a hyperlink equivalent to a cursor and a keystroke as follows:
<!-- Positioning the cursor at field 16 and Issuing the attention key "F4" --> <a href='TelnetHtmlServlet?keyboard=F4&cursor=16'>Names </a>
Form fields include combo boxes for specific fields and protected and unprotected screen fields. You can use the combo box for a specific field as follows:
<!-- Using the combo box to enter the transaction name to field 10 --> <b>Transaction:</b><select name="10"> <option value="inqy">Inquiry <option value="adds">Add <option value="updt">Update </select>
You can use an unprotected screen field as follows:
<!-- Painting field 12, which is an unprotected field for entering number --> <b>Number:</b><input type='text' value='' size='6' maxlength='6' name='12'>
You can use a protected screen field as follows:
<!-- Painting field 3, which is protected field --> <b>Number..:</b><%= screen.paintField(3) %>
Form buttons are used to create keyboard strokes. You can use a form button as follows:
<!-- CREATING BUTTONS FOR KEYBOARD STROKES --> <input type='button' value='Process' onclick='setAttention("ENTER")'> <input type='button' value='Leave' onclick='setAttention("CLEAR")'>
iWay Software |