Development Tools For As400
Development Tools For As400
com
Redpaper
Masahiko Hamada
Drew Glasgow
Garry Kipfer
ibm.com/redbooks
International Technical Support Organization
March 2001
Take Note!
Before using this information and the product it supports, be sure to read the general information in Appendix C,
“Special notices” on page 97.
When you send information to IBM, you grant IBM a non-exclusive right to use or distribute the information in any
way it believes appropriate without incurring any obligation to you.
This IBM Redpaper targets IBM marketing personnel, Business Partners, and
AS/400e and iSeries customers who are looking to extend and expand their
information server into e-business. It shows you how to install, tailor, and
configure WebSphere Development Tools for AS/400.
Thanks to the following people for their invaluable contributions to this project:
Alan Chao
Ho-Kee Chiu
George Farr
Willson Hui
Comments welcome
Your comments are important to us!
WebSphere Development
Tools for AS/400 (WDT/400) Enterprise Edition
Composed Business
Components
Transaction application
Websphere Studio environment
Workbench Clustering and scaling
Wizard Advanced Edition EJS/EJB
Content Authoring Clustering and Scaling Database Connection
Site Development Enterprise Java Server Manager
Content (EJS) Java Servlet Runtime
Management Database Connection and Services T
Standard Edition Manager
Database Java Servlet Runtime I
Connection and Services
Manager V
Java Servlet
VisualAge
Application
Runtime and
Services
O
Programming
Component
L
Development
Team Development
I
For the iSeries server, WebSphere Development Tools for AS/400 (5769-CL3) is
a complete package of premium OS/400 program development tools. These tools
help you quickly develop OS/400-based applications for e-business using your
choice of traditional 5250 green-screen interfaces, HTML browser interfaces, or
GUI-based interfaces on workstations running the Windows operating system.
You can use these tools to:
• Generate Java to Web-enable your RPG applications
• Write host or server code with the CODE/400 workstation-based client/server
development environment
• Develop and maintain applications in many OS/400 languages, including RPG
and Java
Windows PC iSeries
W orkbench
W izards
Page designers WebSphere
Remote Debug HTTP Application
Server Server
Web Site
Client
W eb Site Files
(HTML,
Project scripts,
Files Import/Publish (Publishing Setup W izard) program s)
WebSphere Studio for AS/400 provides tools that you can use to manage your
Web application project and for creating HTML, Java, and JSPs, including
graphics and database access. WebSphere Studio for AS/400 maintains project
files in the file system and provides support for team development and version
control tools. WebSphere Studio for AS/400 deployment features enable you to
configure the projects to deploy to a number of locations, such as the WebSphere
Application Server or the WebSphere Test Environment of VisualAge for Java.
WebSphere Studio for AS/400 now incorporates AS/400 Affinity. AS/400 Affinity
is designed for OS/400 application developers who want to develop e-business
applications but do not have time to acquire the additional skills required to
develop Web-enabled applications. WebSphere Studio for AS/400 now gives
application developers, with traditional iSeries programming skills, the ability to
quickly develop e-business applications without having to learn Java and other
Web application skills. As a developer, you can concentrate on the underlying
business application logic residing on the OS/400 host, using current ILE RPG (or
any other high-level language) skills. You can use the intuitive aspects of
WebSphere Studio for AS/400 to design the Web-based front end. And, you can
generate the JavaServer Pages (JSP) and Java servlets required to enable the
new e-business application.
WebSphere Studio for AS/400 wizards take you through the steps required for
creating Web input and output pages. They allow you to define the parameters
associated with the design-time controls on the Web pages, and link the fields on
the Web pages to the parameters in the business logic. You can do all these
tasks without having to deal with JavaServer Pages, JavaScript code, and servlet
code.
The AS/400 Web interaction wizard also helps you perform these tasks:
• Define the parameters associated with the design-time controls on your Web
pages, without dealing directly with JavaServer Pages (JSP), JavaScript code,
and servlet code.
• Link the fields on your Web pages to the parameters in the ILE business logic.
Use the Publishing Setup wizard to identify your iSeries servers and to define the
publishing information used by the WebSphere Studio for AS/400 publishing
function. Once this is done, you can deploy an iteration of your application for
testing, or you can deploy the final version for production purposes.
WebSphere Studio for AS/400 contains several wizards that guide you through
such tasks as SQL statement generation and creating Web pages to interact with
databases and JavaBeans. You can also use the WebSphere Studio for AS/400
Page Designer to edit these generated pages. The following tools are included in
WebSphere Studio for AS/400 Version 3.5:
• Studio Workbench
• Studio Wizards
• Page Designer
Java export/import
Sources
Classes
One of the most important features of VisualAge for Java is the WebSphere Test
Environment. This feature provides application and Web server environments on
a development machine. This enables you to test and debug the resources of a
Web site locally.
You can use VisualAge for Java's visual programming features to quickly develop
Java applets and applications. In the Visual Composition Editor, you can simply
point and click to:
• Design the user interface for your program.
• Specify the behavior of the user interface elements.
• Define the relationship between the user interface and the rest of your
program.
• Generate the Java code to implement what you design in the Visual
Composition Editor. In many cases, you can design and run complete
programs without writing any Java code.
• SmartGuides (wizards) to lead you quickly through many tasks, including
creating new applets, packages, or classes.
With VisualAge for Java, you can develop very robust code. Specifically, you can:
• Build, modify, and use JavaBeans.
• Browse your code at different levels, such as project, package, class, or
method.
• Use the integrated visual debugger to examine and update code while it is
running.
• Use the distributed debugger to debug Java applications that are developed
outside the IDE.
After building your applications, they run on a workstation and can access
OS/400 host data and other OS/400 objects. VisualAge RPG integrated
components allow application developers to preserve their current skills and to
easily develop OS/400 applications with graphical user interfaces.
With VisualAge RPG, you can build an application from the top down. You start by
focusing on the look and feel of the interface. Then, you tie all the parts together
with workstation RPG logic that you write in the VisualAge RPG language. You
can reuse RPG logic and Display Files (DSPF) from an existing application.
1.4 CODE/400
CODE/400 features workstation-based editing, compiling, and debugging of your
OS/400 applications. CODE/400 is the preferred development environment for
writing host applications for the iSeries server. It is significantly more productive
than IBM Application Development Toolset (ADTS). CODE/400 capabilities
support RPG, COBOL, C, C++, CL, DDS, and Java.
Simplify your work by setting up the CODE Project Organizer to access and
manage your OS/400 files, members, objects and Application Development
Management (ADM) parts. Create a CODE Project Organizer project and set up
filters to gain quick GUI access to frequently used OS/400 objects, members,
ADM projects, groups, and parts. Use the pop-up menus on these items to
perform actions, such as edit, compile, and debug. Use the CODE Actions
notebook to create and manage user-defined actions.
Share your projects and actions with other team members to decrease set-up
time by importing and exporting projects and importing and exporting actions.
Use CODE Designer to create, design, and update your display and printer files.
CODE Designer allows you to graphically navigate through records, keywords,
and fields. This allows you to see the DDS source for individual records, fields,
and so on, as well as the entire source file.
You can group records together to design screens and reports. CODE Designer
drag-and-drop capabilities simplify screen and report design, and provide you
with built-in DDS verification and compile features. You can also browse the
source listing for your display or printer file.
When your program is finished, and there are no syntax errors, you can save time
by using the Program Verifier before you compile your program on the iSeries
server. Program Verifier checks for compile errors on your PC before you even
send your compile request to the iSeries server. Program Verifier is a handy tool
when you are writing code but are not connected to an iSeries server. Program
Verifier brings up the Error List, which helps you view and manage any errors
found.
Once you are satisfied with the state of your code, invoke the Program Generator
to select the redesigned and user-friendly compile options you desire for your
program. The Program Generator provides the ability to update and create
programs if you are using ILE modules. Program Generator notifies you when
your compile is complete and, if there were any errors, the Error List appears.
The Program Generator also supports Java and gives you the ability to compile
on the OS/400 host and run Java programs remotely on the iSeries server.
The CODE Debugger allows you to browse source, set, delete, enable, and
disable watch and line breakpoints as well as step through your code. The
Debugger is a powerful tool that enables you to get your applications up and
running quickly.
WebSphere Windows 95, 98, NT, or 2000; OS/400 V4R4 or later; Netscape
Studio for AS/400 Microsoft Internet Explorer 4.0 or 4.7 (provided) or later or Internet
later; IBM OS/400 V4R4 or later; Explorer 4.0 or later; IE5.0 for
WebSphere Application Server Page Detailer; WebSphere
V3.02 or later Application Server V3.5 or later
VisualAge RPG Windows 95, 98, NT, or 2000; Windows 95, 98, NT, or 2000 or
ADTS (5769-PW1); OS/400 any JRE V1.2 or later (including a
V4R3 or later browser); OS/400 V4R3 or later
VisualAge for Windows 95, 98, NT, or 2000; OS/400 V4R4 or later; JRE
Java for AS/400 OS/400 V4R4 or later V1.2.2 or later; Netscape 4.7
(provided) or later or Internet
Explorer 5.0 or later to access
HTML-based help and Web
documentation; TCP/IP
communication protocol
configured and running
Before you proceed further, you should load the latest version of the WebSphere
Development Tools for AS/400 PTF service pack. For the latest PTF service pack
information, visit the Web site at: http://www.ibm.com/software/ad/wdt400/
The following sections specifically deal with installing and configuring the default
instance of the WebSphere Application Server, HTTP server, and the
Administrative Console. Users who are experienced in these areas may want to
skip this section and continue with 2.3, “Setting up your instance of the
WebSphere administrative server” on page 28.
Installing and configuring the WebSphere Application Server on the iSeries server
should take a minimal amount of time and effort. Before you begin, make sure your
system meets the iSeries software prerequisites. For more information about
minimum software requirements, refer to WebSphere for AS/400 Documentation
Center. The online version can be accessed at the AS/400 WebSphere Web site:
http://www.iseries.ibm.com/products/websphere/index.htm
Note
To run either of these commands, you need a user profile with *ALLOBJ authority.
To install WebSphere Application Server from the CD-ROM drive of your iSeries
server, follow these steps:
1. Make sure that WebSphere Application Server 3.5 Standard Edition for
AS/400 CD-ROM is in the CD-ROM drive of your iSeries server.
2. We used all of the default settings for WebSphere Application Server. If you
want to use different settings, refer to the WebSphere for AS/400
Documentation Center. The online version can be accessed at the AS/400
WebSphere Web site:
http://www.iseries.ibm.com/products/websphere/index.htm
Follow either the Qshell Interpreter steps or the OS/400 command line steps if
you want to use all of the default settings:
• Using the Qshell Interpreter:
1. To start the Qshell Interpreter, on the OS/400 command line type:
STRQSH
2. Change directories to the root directory on the CD-ROM drive, and type:
cd /QOPT/WebSphere
3. Type SETUP
Note
Although this command is displayed on more than one line, you must enter
it as one continuous line on the OS/400 command line. Be sure to use the
same capitalization as shown.
After you complete this step, messages appear that indicate what the
installation process is currently doing. Installing WebSphere Application
Server may take between thirty minutes and one hour.
Before you continue with the configuration of the WebSphere Application Server,
you must install the latest PTFs for WebSphere Application Server Standard
Edition for AS/400.
For the latest WebSphere PTF information, go to the Web site at:
http://www.iseries.ibm.com/products/websphere/index.htm
Two jobs constitute the administrative server environment. The monitor job has
the default name QEJBMNTR. An administrative server job has the default name
QEJBADMIN.
Before you start your administrative console, you should ensure that the
environment has started successfully.
Bottom
Press Enter to continue.
Bottom
Press Enter to continue.
Before you proceed further, load the latest version of the WebSphere Application
Server Standard Edition for AS/400 Group PTF on the administration console.
For the latest WebSphere PTF information, go to the Web site at:
http://www.as400.ibm.com/websphere
Note
It is required that you have a host name entered on OS/400. The
WebSphere Administrative Console will not connect if the entry is not
present. If you do not have a host name entry, add it. Additionally, if the
OS/400 host name is in lowercase, you must also enter the name in
lowercase when connecting to the WebSphere Administrative Console.
Bottom
F3=Exit F4=Prompt F5=Refresh F10=Additional parameters F12=Cancel
F13=How to use this display F24=More keys
The WebSphere Administrative Console uses port 900 by default. If you changed the
default port with the admin.bootstrapPort parameter when you started the
administrative server, you need to specify that port for the WebSphere Administrative
Console. The admin.bootstrapPort parameter is specified in the admin.properties file.
Press Enter.
3. You are prompted for an OS/400 user ID and password. Your OS/400 user ID
must have *ALLOBJ authority.
The IBM HTTP Server for AS/400 page appears. See Figure 9.
2.2.2.4 Editing the IBM HTTP Server for AS/400 configuration file
You need to edit the configuration file to add the directives NameTrans,
Authorization, Service, ServerInit, ServerTerm, and Pass. These directives allow
a Web browser to access the Servlet Engine and the Web applications that come
with WebSphere Application Server.
Note
If you specify a port other than the default port, you must configure your
virtual host DNS (Domain Name System) aliases in the WebSphere
Administrative Console to reflect your port number.
Note
The directives are added as the first entries in the HTTP configuration file. If
you have existing directives you want processed before the WebSphere
directives, you must manually rearrange or add them.
2.2.2.5 Starting the IBM HTTP Server for AS/400 instance you created
IBM HTTP Server for AS/400 runs in the QHTTPSVR subsystem, and each HTTP
server instance starts multiple jobs. The WebSphere Application Server code
plugs into IBM HTTP Server for AS/400 and runs in the HTTP server job that
communicates with the administrative server and one or more application
servers.
Start the HTTP server instance that you created by typing the following command
on the OS/400 command line:
STRTCPSVR SERVER(*HTTP) HTTPSVR(my_instance)
If you change your HTTP server instance configuration, stop and then start your
HTTP server instance. To stop your HTTP server instance, enter the following
command from the OS/400 command line:
ENDTCPSVR SERVER(*HTTP) HTTPSVR(my_instance)
Note: You can also start and stop your HTTP server instance from the IBM HTTP
Server Configuration and Administration forms. See Figure 14.
The Configuration and Administration forms also provide the option to restart your
HTTP server instance. When you restart the server instance, the HTTP server
recognizes all configuration changes except for the changes to the Basic and
Security configuration forms.
If your HTTP server configuration uses a port other than the default (port 80), you
must update the Host Aliases table under the virtual host, which is default_host,
to reflect the correct HTTP port number. This is achieved by following these
steps:
1. From the WebSphere Administrative Console topology view, locate the virtual
host, which is named default_host.
2. Click default_host. The settings for default_host appear in the right side of
the console.
3. Go to the Advanced settings by clicking the Advanced tab.
4. In the Host Aliases menu, update the specified host aliases with the correct
port number. For example, the host name TORAS48F would become
TORAS48F:12345. Here, 12345 is the port number you used for your HTTP
server instance.
5. Click Apply. See Figure 15 on page 26.
6. In the Topology view of the WebSphere Administrative Console, find the node
that has the same name as the host name of the iSeries server, for example
TORAS48F. Expand that node and right-click the Default Server application
server instance.
7. Start the application server.
You can use the Administrative Console to start and stop application servers. If
you attempt to stop an application server and it does not stop, you can stop it by
using OS/400 commands. When you start or stop an application server, you also
start or stop everything that runs within the application server, such as servlet
engines.
Note
The first time you start WebSphere Application Server, you must start the
application server before you start your HTTP server instance. The first time
the application server starts a initialization is performed that affects your HTTP
server instance. If the instance is already running, restart it after you start the
application server to refresh the configuration.
Note: The URL is case sensitive. Therefore, the capitalization must be consistent
with the above example.
In the URL, your.server.name is the name of your iSeries server, and port is the
port number of your HTTP server instance.
If you see “Hello World” as the result, your WebSphere Application Server has
been set up successfully. See Figure 16 on page 28.
A single administrative server allows you to run many application servers. Each
application server runs in its own process. In most cases, a single administrative
server handles your scalability and isolation needs. Additionally, a single
administrative server allows you to use a single Administrative Console to
manage all the server resources.
To create a new administrative server, run the script that creates all new server
directories and sets up the correct authorities. Your OS/400 user profile must
have *ALLOBJ authority to run the script. Follow these steps:
1. On an OS/400 command line, run the STRQSH (Start Qshell Interpreter)
command.
2. Set up Qshell Interpreter to run the WebSphere Application Server scripts.
All WebSphere Application Server scripts are located in the
/QIBM/ProdData/WebASAdv/bin directory and must be run from Qshell
Interpreter.
Use one of the following methods to run the scripts in Qshell Interpreter. Use
the cd command to change to the /QIBM/ProdData/WebASAdv/bin directory,
and then run the script. In our case, we typed the following option on the
command line:
cd /QIBM/ProdData/WebASAdv/bin
crtnewinst -instance itso2 -bootstrap 790 -lsd 791
Here, crtnewinst is the name of the script, and -instance, -bootstrap, and -lsd
are the parameters that are passed to the script.
The other methods are included here for completeness:
• Invoke the fully qualified path name of the script.
An example is: /QIBM/ProdData/WebASAdv/bin/script_name parameters
Here, script_name is the name of the script, and parameters indicate the
parameters that are passed to the script.
• Update your PATH environment variable to automatically locate the script
when you run it. Follow these steps:
i. Edit the .profile file in the /home/user_profile_name directory. Here,
user_profile_name is the name of your iSeries user profile.
Note
If this file does not exist, create it in this directory. Save the file in an
ASCII code page format. Also note that .profile is the full name of the
file. When Qshell Interpreter is started, it searches for the .profile file,
and executes the commands listed in it. You can use the .profile file to
set persistent environment variables for your Qshell Interpreter
session.
Parameter Description
-instance The required value <instance_name> specifies the name of the instance.
The script creates the new administrative server instance in the
/QIBM/UserData/WebASAdv/instance_name directory.
-bootstrap The required value <boostrap_port> specifies the number of the TCP/IP port
from which the client (such as the Administrative Console) connects to the
administrative server instance. Specify an unused port number on your
iSeries server. Port 900 is used by the default administrative server instance
and should not be used for other instances. Use the Work with TCP/IP
Network Status (NETSTAT *CNN) command to display a list of port numbers
that are currently being used.
-lsd The required value <lsd port> specifies the number of the TCP/IP port on
which the Location Service Daemon (LSD) service listens. Specify an
unused port number on your iSeries server. Port 9000 is used by the default
administrative server instance and should not be used for other instances.
Use the Work with TCP/IP Network Status (NETSTAT *CNN) command to
display a list of port numbers that are currently being used.
The remaining parameters are optional and were not used for the purposes of
this redpaper. For a description of these parameters, refer to the Web site at:
http://www.iseries.ibm.com/products/websphere/index.htm
Parameters Description
-instance The required value <instance_name> specifies the name of the instance.
-http The optional value <web_server_instance> specifies the name of the Web
server instance that you configured in 2.2.2.3, “Creating an HTTP server
instance” on page 21. The script starts the instance for you.
-job The optional value <job_name> specifies the name of the monitoring job. If
you do not specify this parameter, the default value is
instance_nameMNTR, where instance_name is the name of your instance.
Alternately, you could run the following command (as a single command) on
an OS/400 command line:
SBMJOB CMD(CALL PGM(QEJB/QEJBMNTR) PARM('-p'
’myDirectory/properties/admin.properties')) JOB(my_mntr)
JOBD(QEJB/QEJBJOBD) JOBQ(QEJB/QEJBJOBQ) USER(QEJB)
Here, myDirectory is the fully qualified path name of the root directory on
which the additional administrative server core directories reside (for example,
/QIBM/UserData/WebASAdv/myAdmin). my_mntr is the job name you want
your monitor to appear as within the QEJBSBS subsystem.
Note
The user profile that issues the command must have *USE authority to the
QEJB user profile, the QEJB/QEJBJOBD job description, and the
QEJB/QEJBJOBQ job queue. Use the Edit Object Authority (EDTOBJAUT)
command to add or verify that *USE authority is granted to your user profile.
4. Verify that the ITSO2ADMIN job is ready for use. From an OS/400 command
line, follow these steps:
a. Enter the command:
WRKACTJOB SBS(QEJBSBS)
b. Find the ITSO2ADMN administrative server job.
c. Specify option 5 (Work with job) and then specify option 10 (Display joblog).
d. Press F5 to refresh the joblog messages until the following message
appears (Figure 17 on page 32):
WebSphere administration server itso2ADMN ready.
e. Position the cursor on the message and press F1. See Figure 18 on page
32.
Bottom
Press Enter to continue.
Bottom
Press Enter to continue.
b. Add the Basic details. Set the Host name to TORAS48F, and set the Default
port to 792 as shown in Figure 20 on page 34.
c. From the Servlets page, select WebSphere version 3, and click the
Servlets and JavaServer Pages box as shown in Figure 21.
b. Highlight default_host.
IBM HTTP Server for AS/400 runs in the QHTTPSVR subsystem, and each
HTTP server instance starts multiple jobs. The WebSphere Application Server
code that plugs into IBM HTTP Server for AS/400 runs in the HTTP server job
that communicates with the administrative server and one or more application
servers.
The HTTP server instance can also be started from an OS/400 command line
by typing:
STRTCPSVR SERVER(*HTTP) HTTPSVR(my_instance)
Here, my_instance is the name of your HTTP server instance.
If you change your HTTP server instance configuration, stop and then start
your HTTP server instance. To stop your HTTP server instance, enter the
following command from the OS/400 command line:
ENDTCPSVR SERVER(*HTTP) HTTPSVR(my_instance)
Here, my_instance is the of name your HTTP server instance.
The Configuration and Administration forms also provide the option of
restarting your HTTP server instance. When you restart the server instance,
the HTTP server recognizes all configuration changes, except for changes to
the Basic and Security configuration forms.
6. Verifying the installation.
You can verify the installation by running the HelloWorldServlet. Successful
execution of the HelloWorldServlet verifies that your application server is
working correctly.
Open a browser, and go to the following URL:
http://your.server.name:port/servlet/hello
IBM WebSphere Studio for AS/400 is designed to allow OS/400 users to quickly
enable new applications on the Web. It does this by extending IBM WebSphere
Studio with wizards that provide the AS/400 interface and allows the user to take
advantage of their current iSeries or AS/400 skill set.
The wizards allow the user to define the data and program interfaces between the
Web pages that they design and AS/400 ILE programs. WebSphere Studio for
AS/400 generates the JSPs, servlets, and beans for handling the interface
between the Web pages and the iSeries or AS/400 programs written by the user.
There are cases where the application logic requires that one of several different
pages be used for output. This changes the normal flow of input and output pages
as defined by WebSphere Studio. These exceptions can be handled by a feature
called flow control, which can be accessed by the Web Interaction Wizard. While
this gives the developer some control over the application, you should remember
that this is a browser-based application rather than a 5250 application. It provides
different functions than a 5250 application, which has the ability to output multiple
formats to one screen.
Once a browser user makes a request with a Web input page, that request
causes a Java application code to be executed in the WAS, which calls an ILE
program. This causes a job to be started on the iSeries server, and the requested
ILE program loads and executes. The input fields from the Web input page are
passed to the ILE program via parameters. The ILE program then executes and
passes the results back to the Java application code running in the WAS. The
WAS application code, servlets, and JSP map the ILE program parameters to the
output fields for the results or output page and send the output page to the
browser user.
Code your ILE program the way you normally would, except that you do not code
DDS screens or create display files. This aspect of your application is now
handled by the Web interface you created.
Note that the parameters you code in your program need to be in the same order
as the parameter definitions you created in the Web Interaction wizard. Of
primary importance is the business logic you need to code to correctly run the
program calls submitted through the Web interface. For a more detailed example
of a Web application, see “Creating Web Applications” in the Getting Started with
Also take into account the requirements for running a cleanup program if your
Web application times out, or if the user inadvertently ends the browser session
(the default session time out is 30 minutes, but it can be changed in the Session
Manager of WAS). If this occurs, a call is automatically made to the cleanup
program @AFFCLNUP. You need to create this program to invoke any program
cleanup routines that close open files or restore database records. This program
must not contain any input or output parameters. You also need to ensure that it
is in a library that you specified in the library list in the Publishing Setup wizard. If
the program does not exist, or is not located in the library list, your program
cleanup will not occur even though the browser session ends.
Some control over the flow of the screen within the application is provided by
WebSphere Studio for AS/400. The developer can ask to use flow control with the
Web Interaction Wizard. One of the parameters is designated for the flow control.
This ILE program dictates which page is presented next and moves the name of
the JSP that controls a page’s output into the flow control parameter. WebSphere
Studio for AS/400 also provides:
• The ability to use AS/400 message files
• Code to do input field editing, such as restricting numeric input fields to
numeric only
• The ability to access UDB DB2 for AS/400 table definitions and synchronize
the definition in the application code with the database so that changes made
to the database are reflected in the application.
The sample application covers the AS/400 features in WebSphere Studio for
AS/400. This sample assumes that you are familiar with the other features of IBM
WebSphere Studio. If you require more information, refer to Web Enabling
AS/400 Applications with IBM WebSphere Studio, SG24-5634.
We have an ILE RPG program called ORDENTR (the sample code can be viewed
in Appendix B, “Sample code” on page 93), and we are using the ITSO2 instance
of the WAS.
4. Select OK. The window displaying the project appears as shown in Figure 30.
7. The custno.jsp now appears in the Theme folder. Expand the Theme folder
and double-click the custno.jsp to open the design widow for custno as
shown in Figure 32 on page 46.
8. Some images and a simple logo are added to this page. Since you are
interested in the iSeries aspect, skip directly to that stage. As shown in Figure
33, you are ready to begin defining the fields.
The Design Time Controls dialog box appears as shown in Figure 36 on page
48.
13.The Design Time Control box lists the types of OS/400 objects that you can
use to communicate to the ILE program. Note that these items must appear
inside a form, such as the one you just generated. Otherwise, the information
associated with items is not sent to the iSeries server. The capabilities that are
listed include combination boxes and check boxes. Two entries that are of
immediate interest to you are the AS/400 Subfile DTC, which is used to define
subfiles, and the AS/400 Entryfield DTC.
Select the AS/400 Entryfield DTC to define the input entry fields for the Web
page. The outline of the entry field appears within the form (Figure 37).
14.Right-click the data entry box. Select Control Properties from the pop-up
menu. The AS/400 Entryfield DTC Properties box appears (Figure 38).
The Properties dialog allows you to define the Web page field characteristics.
In our case, we named the field “custno” and defined it as a 4-byte character
field. Note that you are defining the display characteristics of the field, not
whether the field is to be used for input or output. That is done when you
define the Web interaction.
There is also an opportunity to define how the field should be edited and if it
should be a hidden field. There is an additional option for importing the
definitions from the DB2 UDB for AS/400 database. If you click the DB
Reference box, you are taken through a series of displays and prompts that
allows you to connect to an iSeries server and retrieve the characteristics of a
data field.
Using the Events tab, you can also define that certain actions on this field
cause an associated Java script to execute. The developer must supply the
desired Java Script.
15.Select OK. You have now defined how your Web page will look and the data
fields that you want on the Web page. You must define the action that can be
taken.
16.Place the cursor after the input box that was just defined and press Enter. The
cursor is now positioned under the “Enter Customer Number” text. You now
define the Submit button that causes the Web page to be submitted.
17.Select Insert->Design-time Control, and the Design-time Control dialog box
appears. Select AS/400 Pushbutton DTC as illustrated in Figure 39 on page
50.
19.This displays the AS/400 Pushbutton DTC Properties dialog, which is shown
in Figure 41.
Your page is now designed and saved, and you are ready to proceed to the next
step: publishing your results.
3. The Published Setup Wizard dialog shown in Figure 44 appears. This wizard
allows you to define the WebSphere Application environment.
A
B
A
WebSphere Application Server
Administrative console
D
C
Figure 45. Relationship between the Publishing setup wizard and the WAS configuration
Parameter Description
Host Name This is the name of the WebSphere Application node where your
instance of the WAS is running. The name must be described in full; the
complete IP address is shown.
XML node name This is the name of the XML node and is used by WebSphere Studio for
(A in Figure 45) AS/400 to configure the WebSphere Application server for you. You see
the results of this in the next step when it creates the application on the
WebSphere Application Server.
WAS bootstrap This is the port number that is used to create your instance of the WAS.
port In your case, you created an instance called ITSO2 using bootstrap port
790. The default port is 900. You created your own instance of the WAS
to provide a unique testing environment.
Web application This is the name of our application. Notice that it is filled in automatically
name and has the same name as the project that you have been working on
(B in Figure 45) in WebSphere Studio for AS/400. In your case, it is called ABCDemo.
Web application WAS uses this path for several reasons. It is used by WAS instance. It
path is also used by WAS to locate the elements of your application, such as
(C in Figure 45) the JSPs and servlets. In your case, the application is stored in the
/QIBM/Userdata/WebAsAdv/ITSO2/hosts/default_host/ABCDemo/web
directory as defined in the root directory. The servlets for the applicator
are stored in /QIBM/Userdata/WebAsAdv/ITSO2/hosts/default_host/
ABCDemo/servlets.
The Web application path, in your case /getorder, serves as the root
directory for the folders /web and /servlets. With this mapping, the user
may enter /getorder/custinq.jsp to call your application.
Root directory These two are grouped together because of the directory structure. This
and Class path structure is one of the more puzzling aspects to the new user, including
(D in Figure 45) what it means and what effect it has on the application. See the note in
the following table cell.
Note:
The structure is explained here directory by directory:
• /QIBM: This is simply defined as the root directory for WAS information.
• /Userdata: This is used to distinguish user data that applies to WAS versus the
ProdData directory that contains the IBM-supplied properties files etc. You should
not use ProdData for your information since any PTFs or fixes are typically applied
to the ProdData directory and you could lose your information.
• /WebAsAdv: This directory is designed to contain the information about the WAS
that you are using.
• /itso2: This directory is used to contain the information about the instance of WAS
that you are using. In your case, it is itso2. The supplied is the default. You can still
use the default value even if you are using your own instance of the WAS. This value
of itso2 does not tie you into the instance itso2 by itself. However, you are using a
special directory so you can more easily isolate your object from other applications
or user objects.
• /hosts: WAS allows the use of an alias, which means that you can have a number of
host names for your particular host. This directory is used to hold the names and
information pertaining to all hosts. It also contains directories for any alias or other
host that may have been defined.
• /default_host: This directory contains information relating to the host or host alias
that you are using. In your case, you are not using any aliases. You are using the
default directory.
• /ABCDemo: This is the directory that contains all the information pertaining to your
application. It defaults to the project name that you used in WebSphere Studio for
AS/400.
• /web: This is the directory supplied by WebSphere Studio for AS/400 and contains
application objects such as the JSPs.
• /servlet: This is part of the Class path directory and should not be changed. It is
used to store the Java code by WebSphere Studio for AS/400.
4. It is not necessary to change any of the directory entries, unless you desire to
separate your object for your instance of WAS. In this case, you would enter
your instance name here in place of our itso2. You may also use your own
directory structure
5. Click the Validate button. This checks to see if the directories exist on the IFS.
If they do not, it creates them. You may be asked for an AS/400 user ID and
password.
Enter the name of the host system used and the user ID and password for the
user who executes the ILE programs on the iSeries server. It is important that
this user has the appropriate authority to run the application.
Enter the library name that the application uses. In our case, it was APILIB.
Remember, if the library is specified here, it is not necessary to specify the
library in the user library list. It does not cause problems, but it logs extra error
messages as the application is running.
7. Click Next to display the Review panel shown in Figure 47. This panel
provides the opportunity to review your input and to go back to make any
desired changes.
Figure 47. Review the publishing settings for the Web application
3.3.2.1 Publishing
Now that the Web page is designed, the Web page data fields are defined, and
the publishing options are specified, you are ready to publish. In this step,
WebSphere Studio for AS/400 creates application code, configures the WAS, and
moves the objects to the appropriate directories on the iSeries server.
Before you publish, start the Administration Client for your WAS instance and take
note of the contents. To start the Administration Client, on a command prompt,
enter:
cd /websphere/appserver/bin
adminclient TORAS48F 790
TORAS48F is your node or system name, and 790 is the bootstrap port number
for your WAS instance.
The default configuration is displayed and should look like the dialog in Figure 48.
Our node for the WAS shown in Figure 48 is TORAS48F, and that node has
defined a Default Server and a Default Servlet Engine. This configuration is
updated by WebSphere Studio for AS/400 during publishing. This configuration is
revisited after publishing to see the effects of WebSphere Studio for AS/400.
This allows the user to specify the types of warning, prompts, and reports that
they want to have during the publishing phase. For our example, we chose not
to verify published files via HTTP and to publish all the files, as opposed to
only publishing the modified files.
2. Click OK. The Files to Publish dialogue appears and asks which files you want
to publish. This display only appears if some of the files are checked out. If the
dialog appears, check the files you want to publish and click OK.
3. WebSphere Studio for AS/400 displays the Set Publishing Option dialog
shown in Figure 50 on page 58. Choose to view the Web page after publishing
and supply the Web page name and the HTTP port you want to use. In our
example, we used port 702 from our earlier configurations.
Check the configurations by supplying the version of the WAS you are using
and the name of the WAS instance (which, in our example, was itso2). If the
Check Configuration box is selected, WebSphere Studio for AS/400 checks to
see if there is an application server configured on this instance of the WAS. It
creates one if none exist. There is no requirement to have WebSphere Studio
for AS/400 create these items. You may create them yourself using the
Administrative Server and simply publish them to the correct path.
4. If you selected the Check Configuration box, a WebSphere Studio for AS/400
message box appears explaining that it is retrieving configuration information.
This may take some time, so be patient. It returns with the Configuration
Check Result dialog, which is shown in Figure 51.
WebSphere Studio for AS/400 also configured the WAS instance for you. If you
start the Admin Client, you see that new entries have been added.
On the display shown in Figure 53, click the Advanced tab and note the entries
for the Document Root and for the Class path. These entries were entered and
used during the publishing phase. They must agree with those that are used
during the publishing phase.
Remember that the basic architecture provided by WebSphere Studio for AS/400
is a Web page in (with some input fields) and a Web page out (with some output
fields) as well as an associated error page. As mentioned earlier, this can be
modified with tools such as Flow control. The basic elements that you are dealing
with and trying to tie together are:
• Web pages and their input and output fields
• The parameters that are passed to and from the ILE program
In your example, use the page you designed earlier as an input page. Let
WebSphere Studio for AS/400 define the output page and request an associated
error page. Also, let WebSphere Studio for AS/400 design and create the error
page. Follow these steps:
2. Click Next. Then, the “Specify a name for your web interaction” dialog
appears. Figure 55 on page 62 shows an example of how you can provide a
name for the particular interaction that you are about to define. If you
previously defined Web interactions for this or other pages, you can also
select the Edit existing button and choose the page that you want to work on
from the associated drop-down list.
The Invalidate session after the interaction occurs option allows you to inform
the session manager that the session should be terminated after this
interaction. This is specified on the last interaction in a series of interactions.
The “No host program call” option allows you to define a Web interaction
without specifying ILE program parameters. This is used when defining
interactions for JSPs that use subfiles.
In our case, we selected Create and called our name interaction “getcustno”.
3. Click Next. Then, the “Specify the input and output pages for your Web
application” dialog appears. This dialog allows you to specify which input and
output pages you want to use, or if you want WebSphere Studio for AS/400 to
create the pages for you. You can also request that WebSphere Studio for
AS/400 create an error page (Figure 56).
4. In this example, you want to use the page that you just created for your input.
To do this, select Use existing input pages. Click Add.
The Select JSP box shown in Figure 57 appears.
In your case, let WebSphere Studio for AS/400 design your output or results
page and error page. Select Create a new results page. Select Create an
error page.
6. Click Next.
The “Specify the input and output parameters for your ILE program” dialog box
appears (Figure 59). It contains an icon for a program and one default data
field.
8. You have now defined the ILE program you want to call and are now ready to
define the parameters that you want to pass to the program. In the next step,
you assign names and characteristics to these parameters. The number of
parameters and their characteristics must match those defined in your ILE
program.
In the “Create a new structure” dialog box, name the structure CSSTRUC, and
click Set.
This adds another field below the getcustnoPGM icon and a structure. The
structure CSSTRUC has a default field added to it called Field2 as shown in
Figure 62. You can now begin to define your parameters with this field name.
10.Select Field2. In the program, select the *Field name under Program element
attributes, and change the name to CZIP. Change Length to 10 so that the
characteristics of this parameter (a 10-byte character parameter) matches the
definition in the ILE program.
Right-click CZIP, and select Add->Field to add the next field. Continue this
until all of the remaining parameters are defined as shown in Table 6. The
program call definition box appears as shown in Figure 63 on page 68.
Table 6. Field of structure "CSSTRUC"
CID Character 4
ORDNBR Character 4
CUSTOMER Character 30
CADDR1 Character 20
CADDR2 Character 20
CCITY Character 20
CSTATE Character 2
CZIP Character 4
Notice that the getcustnoPGM now also has a structure called Field3. You
should rename this structure by following these steps (Figure 64):
a. Click Field3.
b. Select the Field name entry field on the right side.
c. Change the name to Custparm.
So far, under getcustPGM, you defined your parameters, including one for
input, and the structure containing the parameters for output. You need to
You are now ready to continue to the next step. However, before exiting this
dialog, there are several items you should note.
If you right-click CSSTRUC, you notice that you can add fields from a
database. You can also add this structure to a repository for later use.
If you right-click the getcustnoPGM icon, you also notice that, if you enter the
Program source in the right list of attributes, that you can now click the Show
Source push button at the bottom. This starts a session of CODE400 and
allows you to have the ILE program open for reference as you define the
parameters.
13.Click Next. The Map and link input parameters to input fields panel appears
(Figure 66 on page 70). The list of Input Parameters reflects the parameters
and their field names that we defined in the previous steps and are shown on
the left-hand side. The input fields for the Web page are defined on the
right-hand side. Perform the following steps:
14.Click Next.
The Select the output parameters to be included dialog that appears in Figure
67 defines the parameters that you want included on your output or results
page. You can also change the order of the parameters.
The value of your error return parameter should not appear on the output or
results page. Highlight the RETURN parameter in the parameter list, and click
Include on the right-hand side to exclude this parameter.
15.Click Next.
You are now presented with the “Specify the layout and error messages for the
error pages dialog” box. You can use an existing error page or create a new
error page as shown in Figure 68. You can also define program and user error
handling. If you do not choose to define the program and user error, and
request the Create new error page, the error text listed in the box appears on
the error page.
In your case:
a. Click the Create new error page button.
b. Click the Define program and error handling check box.
To display more meaningful messages, create a message file called
ORDMSGF in the APILIB and add an error message (ORD0001) that is
displayed if the customer number is not found. Also, determine that, if the
customer number is found, a return value of 0 appears in the RETURN
parameter. Figure 69 shows the results of your selection. If the customer
number is found, your ILE program sets RETURN=0. If the customer number
is not found, your ILE program sets RETURN=ORD0001. This is required
because there may be many error conditions and the application must know
which one to use. This means that, if RETURN does not equal 0, and there is
no valid return code, a blank page is displayed.
16.Click Finish.
WebSphere Studio for AS/400 is now ready to begin generating the application
code and generate the JSP files and Java files listed in Figure 69.
WebSphere Studio for AS/400 creates the Results and Error page JSPs,
servlets, and DataBeans that are required for this interaction. This is
expected, so click the OK button.
17.WebSphere Studio for AS/400 displays a dialog box indicating that it is
creating the objects (Figure 70).
Some other dialog boxes appear asking if you want to restart the WAS. You
should answer Yes.
18.Publish the results and place the generated code on the iSeries server. Return
to the publishing view and publish the project.
Figure 71 shows an example of the type and number of items that WebSphere
Studio for AS/400 generated.
Now that the objects are created, test them to see how they are working.
19.Request the initial JSP. Start your JavaScript-enabled browser. In the URL
location or address window, type:
http://your.server.name:port/getorder/custno.jsp
Here, your.server.name is the host name of your iSeries server, and port is the
port number using the HTTP server (Figure 72 on page 74). In our example,
we used: http://TORAS48F:702
20.Type a valid customer number and check the results (Figure 73). In our
example, we entered 0001.
21.If you typed invalid results, you receive the error message that you defined
earlier (Figure 74).
3.3.4 Tips
Whenever you are developing applications with WebSphere Studio for AS/400
and encounter problems, be sure to check the following items:
• Is the HTTP server running?
• Is your WAS instance active?
• Is AS/400 NetServer host job active (used during publishing)?
• Is the Web application’s Web path, in the publishing set up, correct and
unique?
• Did you specify the correct port numbers where required?
• Was the host name fully qualified in the first step of the publishing wizard?
• Did you fully qualify the XML host name? If so, this is incorrect and may cause
problems.
• Are the fields that you expected to see as input or output for the iSeries server
defined within a form?
• Are the paths correct (this is the most common problem)?
• If there are runtime errors when navigating the Web pages, one can get more
detailed error message on the error page by selecting the “Display Detailed
Errors” check box in “Set Publishing Options” during publishing.
3.3.5 Considerations
WebSphere Studio for AS/400 is designed to allow iSeries users to quickly Web
enable new applications by using their current iSeries skills. WebSphere Studio
for AS/400 does this by generating the Java code that is required to execute and
by providing an easy-to-use interface to the ILE programs.
One other consideration is the use of subfiles. In WebSphere Studio for AS/400,
the Web pages that use subfiles must interact with *SRVPGM objects, and there
is no input allowed into the subfile. This consideration can cause a considerable
modification to current programs. Subfiles are implemented by APIs in the
*SRVPGM. The particulars for these APIs are contained in Appendix A, “Subfile
Design Time Control” on page 87.
IBM introduced a WebFacing Tool Early Adopter Program for its AS/400 Solution
Providers. This program has two goals. First, by helping solution providers
convert 5250 applications to graphical applications running on a Web browser,
IBM hopes to increase the number of available iSeries Web-enabled applications.
Second, through its work with the solution providers, IBM wants to help define the
DDS keyword support required to make the transformation process simpler and
usable when the product becomes generally available.
The Early Adopter Program is a closed beta program with a difference. IBM plans
to provide sales and marketing support for solution provider applications that
have been successfully converted using the WebFacing Tool. For such
applications, IBM will publish a joint IBM and Solution Provider press release
regarding the successful Web-enabled version of the solution provider product.
Solution providers can apply to participate in the Early Adopter Program by filling
out a form on the WebSphere Development Tools Web site at:
http://www-4.ibm.com/software/ad/wdt400/
The WebFacing Tool provides a simple mechanism for facing existing 5250
applications with HTML user-interfaces. This allows users to interact with the
same application from a Web browser.
The WebFacing Tool allows users to convert their existing 5250 display file
source (DDS) to corresponding JSP and associated JavaBeans. The user
interface is converted to JSPs only once (at development time). The WebFacing
Tool is not a 5250 emulation or screen-scraper product. This approach provides
significant performance improvements over the “screen-scraping” approach that
attempts to convert a 5250 data stream to HTML on the fly.
The JSPs maintain the look and feel of the original application. JavaBeans are
used to communicate input and output data between the JSPs and the original
iSeries application. The JSPs and JavaBeans are then deployed to the
WebSphere Application Server running on the server.
DSPF
WAS
5250 Workstation Alternate display option RPG pgm
5250 UI Function for 5250 customers
(+ CL, CBL, PFs,
Data Manager LFs, Prtfs...)
Beans
data data data
JSPs WebFace WebFace Virtual Workstation
Servlet Server Terminal Data RPG runtime
Server Management
When the WebFacing runtime has output data from the program, it converts it into
a Java data bean and sends it off to the appropriate JSP for displaying in a Web
browser. When the WebFacing runtime receives a Java data bean from the
browser, it converts it into a program buffer that can be understood by the original
iSeries program.
Depending on how the application was started, the WebFacing runtime allows the
same iSeries application to run in either a 5250 display device or in Web mode.
This is made possible by the WebFace runtime switching application I/O data
from the 5250 data-stream generation path to a Web-publishing path when the
application is invoked from a browser.
To support the WebFacing Tool, you must install Websphere Application Server
Version 3.5 and configure it on your iSeries server.
In this example, the application presents a 5250 screen and requests that the
user enter a customer number as shown in Figure 76.
When the user enters the customer number, the application returns the next order
number and the customer information. The screen also allows the input of the
part number and the quantity ordered as shown in Figure 77.
If the user does not know the correct part number, they can use CMD 4 to prompt
for a listing of parts as shown in Figure 78 on page 80.
This sample uses WebFacing Tools to convert the DDSs and allows the
application to run on the Web. Since this is a preview, all of the steps involved are
not covered. Rather, the major areas are covered and the results achieved with
the WebFacing Tool are shown.
Start the WebFacing Tool and choose to create a new project called webface.
Once you connect to the iSeries server, you are presented with a library list.
Choose the DDSs that you want to convert. You can then select them as shown in
Figure 79.
There are several more choices that must be made, such as Web page style,
before you request that the project be created.
Once the project is created, you see a dialog box similar to the one displayed in
Figure 79. You have already supplied WebFacing information via the Publish
Information icon telling WebFacing the name of the iSeries server that runs your
application.
You are now ready to convert any or all of the DDSs that you selected for this
project. As shown in Figure 79, you chose to convert the three DDSs since you
know from experience that these are the DDSs that you require to run your
application. Once you select the DDSs, WebFacing converts them and supplies
the JSPs, servlets, and beans that you require to run your application.
Figure 80 on page 82 shows the results of the conversion and all of the classes
that were generated for the ORDENTD DDS.
You must now move these objects to the iSeries server to execute them. Indicate
to the WebFacing tool which iSeries server you want to use, and select
File->Export. Then, the Export dialog in Figure 81 appears.
The DDSs for your application has been converted and exported to the iSeries
server and you are ready to test the results. Figure 82 through Figure 84 on page
85 show the results.
Now you have an application that you can access from the Web as well as from
the 5250 screens. As you have seen in this chapter, this example does not
require any changes to the RPG source program.
Your ILE program interacts with the subfile by coding to the APIs that are
documented in the following section. The data for a subfile is actually stored in a
user space object (*USRSPC object type) on the iSeries server. This user space
is created in library QTEMP for the job that is executing the ILE program.
When you create a subfile DTC on one of your JSPs, one of the properties you
set is the name of the service program that should be called each time the subfile
is shown. It should also be called when the user presses the Page Up or Page
Down push buttons that are generated by the subfile. This service program
should provide the procedures (shown in Table 7) that are called by the subfile
DTC. Note that these procedure names are case sensitive. Each of these
procedures are passed two parameters. The first parameter is a 10-character
string that is the name of the subfile DTC as defined in the subfile DTC control
properties settings (this name is required by each of the subfile APIs). The second
parameter of the Subfile service program procedure is a structure that maps to the
parameter-list defined in the Subfile DTC properties page.
Table 7. Procedure of Subfile DTC
Procedure Description
INIT This procedure is called each time the page containing the subfile DTC is
about to be displayed. You can use this procedure to initially fill the subfile
with records or a page worth of records. INIT is only invoked by the Subfile
DTC when the DTC is first displayed (in other words, created).
PGUP This procedure is called when the user presses the Page Up button
associated with the subfile to view the previous page of records. If previous
records exist in the user space, this procedure is not called and the subfile
automatically displays the previous page.
PGDN This procedure is called when the user presses the Page Down button
associated with the subfile to view the next page of records. If the next page
of records exist in the subfile, this procedure is not called and the subfile
automatically displays the next page.
CLUP This procedure is called when the session ends and performs a cleanup
operation.
CL0N01Factor1+++++++Opcode&ExtExtended-factor2+++++++++++++++++++++++++++++
DName+++++++++++ETDsFrom+++To/L+++IDc.Keywords+++++++++++++++++++++++++++++
D write PR 10U 0 Extproc(QdtsAppendSF)
D pSFName * Value
D pRcd * Value
D len 10U 0 Value
D spaceName S Inz('SFL1')
D Record DS
D Name 20A
D City 30A
D len S 10U 0 Inz(%Size(Record))
D uRC S 10U 0
*
CL0N01Factor1+++++++Opcode&ExtExtended-factor2+++++++++++++++++++++++++++++
Eval Name='Larry'
Eval City='Pickering'
CallP write(%Addr(SFName: %Addr(Record): len)
CL0N01Factor1+++++++Opcode&ExtExtended-factor2+++++++++++++++++++++++++++++
Eval uRC=QdtsChainSF(pSFName: pRcd: length, uRRN)
DName+++++++++++ETDsFrom+++To/L+++IDc.Keywords+++++++++++++++++++++++++++++
D chain PR 10U 0 Extproc(QdtsChainSF)
D pSFName * Value
D pRcd * Value
D len 10U 0 Value
D SFName S Inz('SFL1')
D Record DS
D Name 20A
D City 30A
D len S 10U 0 Inz(%Size(Record))
D uRC S 10U 0
D uRRN S 10U 0
*
CL0N01Factor1+++++++Opcode&ExtExtended-factor2+++++++++++++++++++++++++++++
Eval uRRN = 3
Eval uRC=chain(%Addr(SFName: %Addr(Record): len: uRN)
* Name = Donna (possibly)
* City = Guelph (possibly)
* uRRC = 3 (possibly)
CL0N01Factor1+++++++Opcode&ExtExtended-factor2+++++++++++++++++++++++++++++
Eval uRC=QdtsInitSF(pSFName: pReserved: length)
DName+++++++++++ETDsFrom+++To/L+++IDc.Keywords+++++++++++++++++++++++++++++
D initSF PR 10U 0 Extproc(QdtsInitSF)
D pSpaceName * Value
D pReserved * Value
D len 10U 0 Value
D spaceName S Inz('SFL1')
D rsvd S 10A
D len S 10U 0
D uRC S 10U 0
*
CL0N01Factor1+++++++Opcode&ExtExtended-factor2+++++++++++++++++++++++++++++
Eval uRC=initSF(%Addr(spaceName: %Addr(rsvd): len)
CL0N01Factor1+++++++Opcode&ExtExtended-factor2+++++++++++++++++++++++++++++
Eval uRRN=QdtsReadc(pSFName: pRcd: length: ustartRRN)
DName+++++++++++ETDsFrom+++To/L+++IDc.Keywords+++++++++++++++++++++++++++++
D readc PR 10U 0 Extproc(QdtsReadcSF)
D pSFName * Value
D pRcd * Value
D len 10U 0 Value
D SFName S Inz('SFL1')
D Record DS
D Name 20A
D City 30A
D len S 10U 0 Inz(%Size(Record))
D urrn S 10U 0
D uRRN S 10U 0
*
CL0N01Factor1+++++++Opcode&ExtExtended-factor2+++++++++++++++++++++++++++++
Eval uRRN=readc(%Addr(SFName:%Addr(Record):len:)
* Name = Donna (possibly)
* City = Guelph (possibly)
* uRRN = 3 (possibly)
CL0N01Factor1+++++++Opcode&ExtExtended-factor2+++++++++++++++++++++++++++++
Eval uRC=QdtsClearSF(pSFName)
DName+++++++++++ETDsFrom+++To/L+++IDc.Keywords+++++++++++++++++++++++++++++
D clear PR 10U 0 Extproc(QdtsClearSF)
D pSFName * Value
D uRC S 10U 0
D SFName S 10A Inz('SFL1')
*
CL0N01Factor1+++++++Opcode&ExtExtended-factor2+++++++++++++++++++++++++++++
Eval uRC=clear(%Addr(SFName)
CL0N01Factor1+++++++Opcode&ExtExtended-factor2+++++++++++++++++++++++++++++
Eval uRC=QdtsUpdateSF(pSFName: pRcd: length, uRRN)
Information in this book was developed in conjunction with use of the equipment
specified, and is limited in application to those specific hardware and software
products and levels.
IBM may have patents or pending patent applications covering subject matter in
this document. The furnishing of this document does not give you any license to
these patents. You can send license inquiries, in writing, to the IBM Director of
Licensing, IBM Corporation, North Castle Drive, Armonk, NY 10504-1785.
Licensees of this program who wish to have information about it for the purpose
of enabling: (i) the exchange of information between independently created
programs and other programs (including this one) and (ii) the mutual use of the
information which has been exchanged, should contact IBM Corporation, Dept.
600A, Mail Drop 1329, Somers, NY 10589 USA.
The information contained in this document has not been submitted to any formal
IBM test and is distributed AS IS. The use of this information or the
implementation of any of these techniques is a customer responsibility and
depends on the customer's ability to evaluate and integrate them into the
customer's operational environment. While each item may have been reviewed
by IBM for accuracy in a specific situation, there is no guarantee that the same or
similar results will be obtained elsewhere. Customers attempting to adapt these
techniques to their own environments do so at their own risk.
Any pointers in this publication to external Web sites are provided for
convenience only and do not in any manner serve as an endorsement of these
Web sites.
C-bus is a trademark of Corollary, Inc. in the United States and/or other countries.
Java and all Java-based trademarks and logos are trademarks or registered
trademarks of Sun Microsystems, Inc. in the United States and/or other countries.
Microsoft, Windows, Windows NT, and the Windows logo are trademarks of
Microsoft Corporation in the United States and/or other countries.
UNIX is a registered trademark in the United States and other countries licensed
exclusively through The Open Group.
SET, SET Secure Electronic Transaction, and the SET Logo are trademarks owned
by SET Secure Electronic Transaction LLC.
Other company, product, and service names may be trademarks or service marks
of others.