home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 10 Tools
/
10-Tools.zip
/
VSCPPv8.zip
/
VACPP
/
IBMCPP
/
samples
/
IOC
/
TRANSTAB
/
TRANSTAB.REA
< prev
next >
Wrap
Text File
|
1995-06-07
|
4KB
|
111 lines
SAMPLE - Code Translation
DESCRIPTION:
This program allows EBCDIC to ASCII and ASCII to EBCDIC
translation of a string. It uses two maps, one with the EBCDIC
code as key (E2AMap) and one with the ASCII code as key (A2EMap).
It converts from EBCDIC to ASCII by finding the element whose key
matches the EBCDIC code in E2AMap (which has the EBCDIC code as
key) and taking the ASCII code information from that element. It
converts from ASCII to EBCDIC by finding the key that matches the
ASCII code in A2EMap (which has the ASCII code as key) and taking
the EBCDIC code information for that element.
TASK:
This program uses maps to translate strings from EBCDIC to ASCII
and from ASCCII to EBCDIC.
CONCEPT/FEATURE:
This program is a sample to demonstrate the use of the default
class IMap in connection with element operation classes.
PROJECT LOCATION:
Inside the IOC Samples folder (inside the VisualAge C++ Samples
folder).
SOURCE FILE LOCATION:
X:\ibmcpp\samples\ioc\transtab
where X: is the drive you installed the samples and document
component of VisualAge C++.
HOW TO RUN THE SAMPLE:
FROM WITHIN THE WORKFRAME ENVIRONMENT:
To run the prebuilt project, open the Samples folder on your
OS/2 desktop then double-click on the project's icon to open
the project view of the sample. Click on the RUN button of
the project's toolbar.
FROM THE COMMAND LINE:
Simply type the name of the .EXE file, that is:
TRANSTAB
If the sample fails to execute or abnormally ends, you can
get more information about the failure by turning on the
ICLUI trace. This is done by setting the environment
variable ICLUI_TRACE as follows:
SET ICLUI_TRACE=ON
SET ICLUI_TRACETO=STDERR
The second export controls where the trace information is
reported. With tracing turned on, ICLUI exception text will
be written to a standard error file. For example:
HELLO1 >HELLO1.OUT 2>&1
The exception data is now in the file hello1.out.
HOW TO BUILD THE SAMPLE PROJECT YOURSELF:
FROM WITHIN THE WORKFRAME ENVIRONMENT:
Open the Samples folder on your OS/2 desktop then
double-click on the project's icon to open the project view
of the sample. In the upper half of the project window you
will see the icons of the files associated with the sample.
From the Project pulldown, select Build -> Rebuild All. To run
the sample project, see HOW TO RUN THE SAMPLE PROJECT above.
FROM THE COMMAND LINE:
A command file is provided to allow rebuilding of the
WorkFrame projects from the command line. Simply type:
BUILD
To run the sample project, see HOW TO RUN THE SAMPLE PROJECT
above.
SOFTWARE/HARDWARE PREREQUISITES:
o IBM VisualAge C++
o OS/2 2.1 or Warp
o IBM or compatible 386 and up.
ADDITIONAL INFORMATION:
o For more information on the creation and use of projects in
the WorkFrame environment, see the VisualAge C++ for OS/2
User's Guide.
o For more information on the Collection Classes, see the
VisualAge C++ for OS/2 Open Class Library User's Guide.
Both books can be found online. To access an online book, simply
open the main VisualAge C++ desktop folder, then open the
Information Folder inside. To view a book, double-click on that
book's icon.
REQUIRED FILES - CODE TRANSLATION:
o transtab.rea
o build.cmd
o transtab.cpp
o transtab.xpc
o trmapops.h
o xebc2asc.h
o transelm.h
o transtab.exe