DB/C DX Technical SummaryDB/C DX is a complete program development and execution runtime system.
The following is an overview of the features of DB/C DX.
DB/C DX Implements the Industry Standard PL/B Language
All program control verbs are implemented including: ROLLOUT, EXECUTE,
All KEYIN and DISPLAY features are implemented, including: subwindows, color, underlining, reverse video, blinking, bold, and more. All subwindow functions including scrolling are supported for all terminals. The ability to save and restore either the current subwindow or the entire screen is also supported for all terminals.
File I/O is fully supported by the sequential, random, indexed, and associative access methods. FILEPI, partial READ and WRITE, tabbing, minus over punch, and zero fill are supported. The maximum record size is 65,500. Full space and digit compression is available. All I/O is completely multi-user; FILEPI 1 is unnecessary. Printer support is fully implemented, including: SPLOPEN, SPLCLOSE, PFILE, and all print control codes in PRINT.
DB/C DX Runs on Most Industry Standard Operating Systems
Programs compiled under DB/C DX can be run on any supported operating system without recompilation.
DB/C DX Commands Provide All Essential Functions
Highlights of DB/C DX
DB/C DX implements file I/O using two different methods. The traditional method is by accessing files using the local operating systemthe DB/C DX data and index files may be on local disks or on network file servers.
The second method of accessing files is with DB/C FS. The connection between the DB/C DX runtime and the DB/C FS server is a TCP/IP connection. Thus the connection may be anywhere on an intranet or on the Internet. This method has several advantages, including better fault tolerance and much better performance over slower wide area networks.
There are four new data types that used extensively in GUI programs. These data types are QUEUE, RESOURCE, DEVICE and IMAGE.
QUEUE variables provide for both stack and queue oriented message buffering and delivery. QUEUE variables are used to retrieve event messages (such as mouse movements, mouse clicks, and key strokes) that programs respond to.
RESOURCE and DEVICE variables are used to define various objects like windows, dialogs, menus, panels, icons, timers and the system clipboard.
IMAGE variables define a rectangular canvas that is painted with the DRAW statement. DRAW operations including drawing dots, lines, circles, text, and more. Other actions can be performed on IMAGE variables including loading an image from a TIFF, GIF or JPEG file, storing an image to a TIFF file, showing an image in a window, printing an image and more.
DB/C DX contains support for all of the standard GUI controls including text edit controls, pushbuttons, list boxes, drop boxes, check boxes, progress bars, tab groups and more. Creation of these controls is done with the PREPARE statement which allows for complete runtime creation of controls and their placement in dialogs and panels. This level of flexibility is not found in many other GUI programming environments.
Classes are implemented in a way that fits naturally into the DB/C language. Classes are implemented by the CLASS DEFINITION and ENDCLASS statements. Object variables are used to instantiate a class. DB/C is a dynamically linked language (there is no linker), so polymorphism and dynamic binding also fit well into DB/C.
TCP/IP actually consists of two communications protocols: TCP and UDP. The TCP/IP protocols are used on the Internet and on many corporate LANs and WANs. The COMFILE type data variable and the SEND, RECV and COMTST statements are used to send and receive messages using TCP and UDP.
Support for the Domain Name Service (DNS) interface is also included in DB/C DX. DNS is used to translate an Internet address (such as dbcsoftware.com) to an actual IP address (such as 126.96.36.199).
MOVE ((X-32) * 1.8) TO Y IF ((A > B) & (C = D)) DISPLAY "YES" ENDIF
For example, a programmer might create a user-defined verb called BOX. The syntax would include parameters for the size of the box and the position on the screen. Whenever the programmer wants to display a box on the screen, BOX can be used just like the built-in verbs.
Multiple module execution
. PROG1.TXT CHAR10 DIM 10 FUNC1 EXTERNAL MOVE "PARAMETER1" TO CHAR10 LOADMOD "PROG2" CALL FUNC1 WITH CHAR10, "PARAMETER2" STOP . PROG2.TXT PARM1 DIM @ PARM2 DIM @ FUNC1 ROUTINE PARM1, PARM2 DISPLAY *ES, PARM1, ", ", PARM2 RETURN
Support for various text, binary, and native files
The BINARY file type, when specified in a FILE declaration, means that the data file is a binary file (i.e. there are no end-of-record characters).
The NATIVE file type, when specified on a FILE or IFILE declaration, means that the data file and associated indexes are of a type native to the run-time operating system. In UNIX, the NATIVE file type can be C-ISAM. In this way, NATIVE file support can provide access to file types used by other languages (e.g. COBOL).
The DATA file type, when specified in a FILE, IFILE or AFILE declaration, means that the datafile is an ASCII, line-feed delimited text file, regardless of operating system.
Support for SQL (Structured Query Language)
SQLEXEC "SELECT NAME INTO :1 FROM BOOKS WHERE ID=:2", BOOK, ID
INTEGER and FLOAT data types
NUM6 INTEGER 6 NUM7P2 FLOAT 7.2
are equivalent to regular FORM declarations except that all calculations will be done using 32-bit integers and 64-bit floating point variables, respectively. In all other respects (such as WRITE to a file or DISPLAY on the screen), INTEGER and FLOAT declarations are handled as if they were FORM declarations.
Additional variable types
Local variable definition support
TRAPCLR ALL, TRAPSAVE, TRAPRESTORE, DISABLE, and ENABLE verbs
FLAGSAVE, FLAGRESTORE and SETFLAG verbs
Reuse of deleted record space
Industry standard function keys
Completely portable graphical DISPLAY control codes
*LFA left arrow *RFA right arrow *UPA up arrow *DNA down arrow *HLN horizontal line *VLN vertical line *CRS crossed lines *ULC upper left corner *URC upper right corner *LLC lower left corner *LRC lower right corner *RTK right tick mark *DTK down tick mark *LTK left tick mark *UTK up tick mark *DBLON double line on *DBLOFF double line off *HDBLON horizontal double line on *HDBLOFF horizontal double line off *VDBLON vertical double line on *VDBLOFF vertical double line off
These graphic control codes may be contained in KEYIN and DISPLAY lists.
They may also be used as the operands for *RPTCHAR, *RPTDOWN and *ESCHAR.
DISPLAY *ES, *ULC, *RPTCHAR=*HLN:78, *URC;
Multiple print file support
PRT1 PFILE PRT2 PFILE SPLOPEN PRINT1, "file1.prt" SPLOPEN PRINT2, "file2.prt" PRINT PRINT1; "This line goes to file1" PRINT PRINT2; "This line goes to file2" SPLCLOSE PRINT1 SPLCLOSE PRINT2
Automatic print spooling
SPLOPEN "PRTFILE.PRT", "D" PRINT "A PRINT LINE" SPLCLOSE "S,B,N=2,D"
The D parameter of SPLOPEN causes the print file to contain device control characters (CR, LF, FF) instead of ANSI carriage control characters. The S parameter of SPLCLOSE causes the file PRTFILE.PRT to be submitted to the system spooler. The B option causes a banner page to be printed. The N=2 option causes two copies to be printed. The D option causes PRTFILE.PRT to be deleted when printing is complete.
When used in conjunction with the
The setnull statement causes numeric and character variables to be set to the NULL state. The isnull operator is used in expressions to test the NULL state of a numeric or character variable. The setnull statement and the isnull operator are particularly useful in conjunction with SQL.
A call statement with parameters may pass label variables by prefixing
the variable name with the tilde (
The unlock statement allows a single record to be unlocked in a file.
The move statement of a list variable to another list variable causes each of the variables contained in the source list variable to be moved to each of the variables in the destination list.
In the character mode versions of DB/C DX, PDF, PCL and PostScript printer
output is supported with the
Single event and recurring timer support is available in conjunction with device and queue variables.
The CHAIN utility
The SORT utility
The BUILD and REFORMAT utilities