### Overview

This document provides information about using the Frankenstein Limes Command Line (FLCL). It contains advanced guidelines and information to run the commands provided by this batch interface. FLCL is the main utility to run all the different subprograms of the FL5 infrastructure.

Beside FLCL, the FL5 infrastructure consists of the components below:

- FLCC - Frankenstein Limes Control Center (GUI)
  - Graphical user interface to build FLCL commands, property files and more
  - It is also useful to construct parameter strings for FLAM's APIs
  - Interactive help and documentations, can be used as replacement for this book

- FLUC - Subsystem for z/OS and Linux
  - Application-transparent conversion, compression and encryption of files
  - Can be used to make applications compliant to several security standards
  - Implemented on z/OS as I/O-Subsystem and on Unix as user space file system
  - Gives you complete control over the encrypted file
  - One logical file can be written to multiple (local and/or remote) targets
    - Note: Only one of these files can be read via this logical file view
  - Supports remote files via SSH and different archives formats

- FLUCUP - FLUC Subprogram as C interface (DLL)
  - Data source to target conversion as described in this document
  - Each command is available as function (flucconv())
  - FLCL command line = parameter string for subprogram
  - `ret=flucinfo("get.file=test.txt");`

- FLUCUPLB - FLUC Subprogram as load module interface
  - All functions of FLUCUP (flucconv) are provided as load modules for simple integration in COBOL, PL1 or assembler programs on mainframes.
  - `FCUCONV("read.file=DD:INPUT")`

- FLCBYT - Byte interface for original data (C like DLL)
  - You can transparently read and write each kind of data source or target as byte stream or records with a C like file-I/O interface using the read or write overlays of the FLCL-CONV/XCNV commands described in this document.
  - `f=fcbopen("read.file=text.txt","format.record()");`
  - `f=fcbopen("write.text(file=out.txt comp.bzip())","format.text()");`
  - Beside file to memory, memory to memory conversion is also supported
    - The memory to memory interface makes FLAM an enterprise service bus (ESB)

- FLCBYTBF - C++ streambuf class for I/O streams based on FLCBYT
  - You can pass an flcbyt_buffer object to an istream or ostream instance in C++ and use the byte interface as a regular stream.
  - `flcbyt_buffer buf("read.file=text.txt","format.bin()");` `std::istream in(&buf);`
  - `flcbyt_buffer buf("write.text(file=out.txt)","format.text()");` `std::ostream out(&buf);`

- FLCBYTJava - Java Native Interface (JNI) library for the FLUC byte interface and corresponding stream classes for Java (like FLCBYTBF for C++)
  - This Java-wrapper of the FLCBYT library enables Java developers to use all FLAM byte interface capabilities in any Java application. It contains several classes that make working with the byte interface much more comfortable, for example classes using the stream API or in-memory conversion classes for different access patterns.

- FLCRECLB - Record interface for original data (load modules)
  - You can transparently read (GET) and write (PUT) each kind of data source or target in a record-I/O-like interface also using the read and write unions of the CONV command or the input and output objects of the XCNV command in the corresponding file open function. All functions are provided as separate load module for simple usage in COBOL, PL1 or assembler programs.
  - `FCROPN("read.auto(file=<SYSUID>.VASM.KSDS ccsid=1141)")`
  - `FCROPN("write.text(method=win, ccsid=1252, comp.gzip(level=9))")`
  - Additionally, you can parse XML datasets, or convert variable records containing comma-separated values (CSV) into fixed-length data structures (COPYBOOKs/FB-Records) and use a set of functions to convert integers, floats, strings and binary blobs from various representations (e.g. a number as UTF-8 string in an XML element) into COBOL or PL1 data types (PIC S9(9) COMP).
  - In-memory conversion is also supported
  - Simple environment, system and JCL variable handling
  - Supports Micro Focus EDZ environments
  - The interface was designed to work with copybooks (static structures) in COBOL or PL1 and to produce XML, CSV or other (dynamic) data formats in clear, compressed and/or encrypted form.

- FLCICV - FLUC character conversion module (ICONV like DLL)
  - You can transparently use this libiconv-compatible interface for memory to memory character conversions. It supports all feature of our character conversion component (CNVCHR), including:
    - Stop, ignore, substitution and transliteration for invalid characters
    - EBCDIC new line to line feed management
    - User table, subset support (SEPA, String.Latin(XOEF/NPA), ...)
    - Normalization (NFC/NFD) and combined character support
    - UTF-8 with 5 and 6 byte long encodings
    - Case mapping, BOM management (including byte order change support)
    - Comprehensive reporting of error positions (SUB, IGN, XLT, ...)
  - `h=fliconv_open("IBM1141//ENL2LF","UTF-16LE//BOM//IGNORE//TRANSLIT(ICONV)//USRTAB(DELA)//REPORT(DD:REPORT)");`
  - `fliconv(h,&indat,&inlen,&outdat,&outlen);`
  - `fliconv_close(h);`
  - Look for FLICONV utility program and the corresponding sample source

This document is also useful for users of the stream, byte, record, element or subprogram interfaces of the FL5 infrastructure because all these interfaces use the same syntax as the command line. The format, conversion and state strings for these APIs are documented in Appendix A 'Other CLP strings' at the end of this book.

Various C/C++ sample programs for the APIs above can be found in the library SRCLIBC as part of the installation package for mainframe systems. The corresponding compile and link step is in JOBLIB(SBUILD).

Additional COBOL, PL1 and Assembler samples can be found in the library SRCLIB. The corresponding compile and link procedures are also located in JOBLIB(SBUILD) as separate steps.

For other platforms (Windows, UNIX) the C, C++ and Java sample program sources are located in the 'sample' directory and the compile and link procedures can be found in the Makefile of the same directory.

Beside all these new FL5 based components, the following FLAM4 components are still supported:

- FLAM4-Utility - The command line program, also available as command FLAM in FLCL or as separated executable FLAM4 with all advantages of the new FL5 architecture.
- FLAM4-Subprogram - Integration of file to file compression and decompression in other programs (works like FLUCUP[LB]. For new projects we recommend to use the flucflam() or FCUFLAM() functions, the FL5 project offers also the FLM4UP and flamupc() entries which are backward compatible with FLAM4).
- FLAM4-Record interface - Record-wise (length and data) read (GET) and write (PUT) access to compressed FLAMFILES.
- FLAM4-Subsystem (only on z/OS) - Application-transparent integration of FLAM at SVC99 file allocation
  - `FILE DD DSN=&SYSUID.TEST,DISP=...,...,SUBSYS=FLAM`

With FLAM5 new CLIST, PANELS and MESSAGES were added for ISPF on z/OS:

- FLINFO - ISPF line command to show determined file attributes
- FLVIEW - ISPF line command to show content of different files
  - normal host data sets, members of PDS/PDSE, VSAM data sets
  - Directory content of PDS/PDSE, FLAMFILES, GZIP/BZIP/XZ files
  - binary transfered XML or text files from other platforms
  - base encoded, encrypted, compressed files
  - and much more
- FLTEXT - ISPF line command like FLVIEW, but it produce dumps for binary files
- FLVEDIT- ISPF line command to edit content of different files
  - works like FLVIEW, but you can edit the data
  - the data is then written back in the original format
  - for example you can edit UTF-8 XML data in a GZIP file over ISPF
- FLVEDITx - Like FLVEDIT but with limited record length and no cut of records
- FLDEL - ISPF line command to delete each kind of file (incl. VSAM)
- FLGREP - ISPF command to search for a regular expression pattern in any of files using the directory walk (FLGREP pattern dsn)
- FLHLP - ISPF command for interactive help of FLCL commands
- FLSYN - ISPF command for interactive syntax of FLCL commands
- FLMAN - ISPF command for interactive manual pages of FLCL commands
- FLDOC - ISPF command for documentation generation of FLCL
- FLGRA - ISPF command to show grammar of FLCL commands
- FLLEX - ISPF command to show lexems of FLCL commands
- FLABO - ISPF command to show about information of FLCL
- FLVSN - ISPF command to show version information of FLCL
- FLLIC - ISPF command to show license information of FLCL
- FLSYS - ISPF command to show system information for FLCL

Also with FLAM5, GUI tool flgt -c=info/view/edit/checksum were added for use via the Windows context menu. Registering the Windows context menu is performed during installation.

- INFO - shows file properties such as file size, file format, data type, charset, ...
- VIEW - displays contents of a file; useful for compressed files or text data files in a wrong charset; This tool decompresses and/or decodes selected files and tries to open the result with the default program for the respective file type. It can also be used for encrypted files, which requires the appropriate key information to be set in your property file.
- EDIT - like flview, but can edit files (default if no command defined)
- CHECKSUM - easy way to calculate checksum (CRC/SHA/...)

On Unix systems, these utilities are also available on command line. The integration in the context menu of the different desktop systems, must be done manually.

On z/OS systems, we support zEDC, zIIP, CPACF, ICSF, RACF, SMF logging and a lot of mainframe-exclusive features. Please read the install.txt for z/OS carefully to set FLAM up correctly to allow it to use such features (e.g the FLAM started task (FLAMSTC), authorization and link list concatenation is often required).