Guardian Programmer's Guide

Table Of Contents
Guardian Programmer’s Guide 421922-014
14 - 1
14
Using the IOEdit Procedures
The IOEdit package is made up of a set of routines that allow an application to read
and write EDIT files (files with file code 101). The procedure call interface to the
IO-Edit routines allows access to EDIT files from any supported language: TAL, C,
COBOL85, Pascal, and FORTRAN.
This section describes how to use the procedure-call interface to the IOEdit routines.
Specifically, it describes how to perform the following operations:
Create, open, and initialize IOEdit files (OPENEDIT_ procedure)
Read and write EDIT files (READEDIT[P] and WRITEEDIT[P] procedures)
Pack and unpack text in an EDIT file line (PACKEDIT and UNPACKEDIT
procedures)
Delete lines from an EDIT file (DELETEEDIT procedure)
Renumber lines in an EDIT file (NUMBEREDIT procedure)
Get and set the current-record pointer (GETPOSITIONEDIT and POSITIONEDIT
procedures)
Handle “file full” errors (EXTENDEDIT procedure). The maximum edit file size is
128MB.
Get and set the record number increment (GETINCREMENTEDIT and
INCREMENTEDIT procedures)
Complete an IOEdit operation in an application that uses nowait I/O
(COMPLETEIOEDIT procedure)
Compress an IOEdit file (COMPRESSEDIT procedure)
Close an IOEdit file (CLOSEEDIT_ and CLOSEALLEDIT procedures)
When to Use and When Not to Use EDIT Files
Files in EDIT format are intended for text editing applications.
EDIT files are unsuitable for several kinds of applications. Specifically, you must
observe the following restrictions on the use of EDIT files:
You cannot use EDIT files for database purposes.
There is no locking available for EDIT files.
NonStop TM/MP protection is not supported for EDIT files.
You cannot use alternate keys with EDIT files.
Checkpointing is not supported if your application uses IOEdit procedures.