The FLAM Record interface

The record interface (access method) is the core of FLAM4 and the predecessor version. Through this interface FLAMFILEs are written and read again. It is the basis for transforming of original files into "flambéed" datasets by means of the FLAM utility, subprogram, or subsystem. It helps mapping the access method for compressed and encrypted files onto one for individual records. Via this interface (API) applications can place data platform-independently into a FLAMFILE, perform searches and retrieve the results. This is implemented very much like the regular file I/O for normal recod-structured files so adaptation of manframe applications involve minimal effort.

 

Benefits

  • Access to logical units of data (records)
  • The API is implemented like an I/O operation which simplifies integration into applications (put=flmput)
  • Enhances security. No need to decompress/decrypt entire files. Small piece of data is sufficient for a particular access
  • No temporary files involved
  • Same universal access to any physical file types
 

 

The product

  • Implemented as an API (function call)
  • Opening and closing members in a FLAMFILE
  • Reading and writing data records in compressed and encrypted FLAMFILEs of any type by API calls
  • Additional functions for record-level seek/modify/delete/insert operations in VSAM-KSDS-FLAMFILEs by key of original record
  • Available on many platforms and for various programming languages
  • The record interface roughly corresponds to file I/O in a Cobol/PLI/Assembler host program

 

Example: FLAMREC for z/OS

Frankenstein-Limes-Access-Method is implemented - based on the record interface - as a manufacturer-independent compressing and encrypting data access method.

It supports sequential, relative, and index-sequential access to particular original records within compressed files that can be stored on storage media of different operating systems and can be exchanged between them.

The record interface is composed of a set of subroutines that can be invoked by programming languages like COBOL, FORTRAN, C, or ASSEMBLER.

This interface is identical for all /390 operating systems for which FLAM is available.

 

FLMCLS

FLMCLS (Close) terminates porocessing after all records were passed to FLAM or, at decompression, all original records were read.

 

FLMDEL

FLMDEL (Delete) deletes from an index-sequential FLAMFILE the last record read.

 

FLMEME

FLMEME (End Member) is called at compression to finalize a member in a FLAMFILE archive. It causes compressed code still in memory, if any, to be written to the FLAMFILE and, where required, a member trailer to be generated. Statistics data are returned, and when AES encryption is used, also a member MAC. In contrast to FLMCLS the FLAMFILE is not closed so another member can be appended.

 

FLMFKY

FLMFKY (Find Key) is used to position within an index-sequential FLAMFILE that was created from an index-sequential file. The resulting position is determined by the key-argument and causes a subsequent FLMGET to read the the record with the respective key or the next higher one.

 

FLMFLU

When FLMFLU (Flush) is called compressed code still in memory, if any, is written to the FLAMFILE and statistics data are requested. In contrast to FLMCLS the FLAMFILE is not closed so additional compressed code can be appended.

 

FLMFRN

FLMFRN (Find Record Number) is used to position within an index-sequential FLAMFILE that was created from an index-sequential file. The resulting position is determined by the record-number-argument and causes a subsequent FLMGET to read the the record with the respective record-number.

 

FLMGET

FLMGET (Get Record) reads a decompressed original record into an allocated buffer.

 

FLMGHD

With FLMGHD (Get Fileheader), fileheader information regarding the original file can be retrieved. If several fileheaders exist in a FLAMFILE this information concern the original records that are returned by the subsequent FLMGET, FLMLOC operations.

 

FLMGKY

FLMGKY (Get Key) reads by key a record from a FLAMFILE that was created from an index-sequential original file. This operation also includes positioning for sequential reading with FLMGET or FLMLOC to the record with next higher key.

 

FLMGRN

FLMGRN (Get Record Number) reads from a  FLAMFILE that was created from a relative or an index-sequential original file the record with the specified record number.

 

FLMGTR

FLMGTR (Get Reverse) positions backwards by one decompressed original record and reads it into an allocated buffer.

 

FLMGUH

FLMGUH (Get User Header) retrieves information inserted into the FLAMFILE during compression bei means of FLMPUH.

 

FLMIKY

FLMIKY (Insert Key) is used to insert into the compressed file a new record with a new key. The key must not exist yet

 

FLMLCR

FLMLCR (Locate Reverse) positions backwards by one decompressed original record and reads it in locate mode.

 

FLMLOC

FLMLOC (Locate Record) may be used instead of FLMGET. However, it does, not copy the record into the user's buffer but just returns the record's address.

 

FLMOPN

In order to limit the number of parameters per function the FLMOPN (Open) function was split up into three partial functions, FLMOPN, FLMOPD, and FLMOPF. FLMOPN passes the main settings to FLAM (e.g. compress or decompress). By FLMOPD, you define the FLAMFILE's attributes while FLMOPF determines the compressed code's characteristics. When FLMOPD and FLMOPF are omitted, standard settings are applied.

 

FLMPHD

By means of FLMPHD (Put Fileheader) file attributes of the original records can be described and saved in the fileheader. The fileheader only relates to the original records subsequently passed by FLMPUT. Each FLMPHD invocation initiates a new member in an archive FLAMFILE.

 

FLMPKY

By FLMPKY (Put Key), a record with the specified key can be inserted or modified in an index-sequential FLAMFILE.

 

FLMPOS

FLMPOS (Position) serves for relative positioning in any sort of files and to create gaps in relative files.

 

FLMPUH

By calling FLMPUH (Put User Header), a character string of arbitrary contents can be appended to the information saved by FLMPHD. Such a call is only valid immediately after calling FLMPHD.

 

FLMPUT

FLMPUT (Put Record) passes to FLAM an original record for compressing.

 

FLMPWD

FLMPWD passes to FLAM a key for encrypting or decrypting.

 

FLMQRY

FLMQRY queries for parameter values currently used by FLAM.

 

FLMSET

FLMSET sets parameter values currently to be used by FLAM.

 

FLMUPD

FLMUPD (Update) changes the original record read last from an index-sequential FLAMFILE.