FLM5UP-API
FLAM Subprogram Interface Version: 5.2.0-37009
Functions

Functions

const char * flamvsn (void)
 Version.
const char * flamabo (void)
 About.
const char * flamlic (void)
 Get license text.
const char * flamown (const char *own)
 Set/Get owner id.
const char * flampgm (const char *pgm)
 Set/Get program name.
int flamenv (const int sys, const int std, const char *env)
 Load the FLAM environment.
int flamarchive (const char *cmd, const char *pro, const char *out, const char *trc)
 FLAM ARCHIVE - Runs archive functions.
int flamrsn (void)
 Get reason code.
const char * flammsg (const int rsn)
 Get a message for a reason code.
void flamhlp (const int what, const int depth, const char *path, const char *out)
 Returns help information about the command string.
void flamsyn (const int what, const int depth, const char *path, const char *out)
 Return syntax information about the command string.
void flamdoc (const int what, const char *path, const char *out)
 Return documentation.
void flampro (const int what, const char *ipro, const char *prop, const char *opro, const char *out)
 Manage properties.

Detailed Description

Function Documentation

◆ flamvsn()

const char * flamvsn ( void )
extern

Version.

This function returns a string with version information for each used component. This should be used in a support case.

Returns
a pointer to a static area containing the zero-terminated version string

◆ flamabo()

const char * flamabo ( void )
extern

About.

This function returns a string with about information for this library on multiple lines and license information for used external libraries.

Returns
a pointer to a static area containing the zero-terminated about string

◆ flamlic()

const char * flamlic ( void )
extern

Get license text.

This function can be used to get the current license text on multiple lines. The license text defines the permissible use of this library.

Returns
a pointer to a static area with a zero-terminated string containing the current license text.

◆ flamown()

const char * flamown ( const char * own)
extern

Set/Get owner id.

This function can be used to get (pcOwn==NULL) or to set the current owner id. The owner id is a logical qualifier to separate different configurations for different clients in the same property file. If you want use a configuration for another owner as "limes", then you must define the owner id with this function first.

Parameters
[in]ownDefine owner name (DEFAULT: "limes")
Returns
a pointer to a static area with a zero-terminated string containing the current owner id.

◆ flampgm()

const char * flampgm ( const char * pgm)
extern

Set/Get program name.

This function can be used to get (pcPgm==NULL) or to set ("mypg") the current program name. If you implement an own property management or a program which does not conform to the FLCL infrastructure components, it might be useful to change the program name.

Parameters
[in]pgmDefine program name (DEFAULT: "flcl")
Returns
a pointer to a static area with a zero-terminated string containing the current program name.

◆ flamenv()

int flamenv ( const int sys,
const int std,
const char * env )
extern

Load the FLAM environment.

This function load the FLAM system variables (only on z/OS or in EDZ environment), the STDENV definitions ('DD:STDENV' or '<SYSUID>.STDENV' on z/OS or '.stdenv' file in working or home directory on other system) and a optional list if variables to the environment. You can adjust the environment before the first call to a FLAM API function is done. This function gives the possibility to work with the same environment used by FLAM utilities, subsystems, etc.

Parameters
[in]sysTrue to load system variables, false no system variables active
[in]stdTrue to load standard environment, false no standard environment variables active
[in]envOptional list (could be NULL or empty) of environment variables (KEYWORD=VALUE) separated by new line ('\n') or semicolon (';')
Returns
negative (<0) error else (>=0) amount of environment variable load

◆ flamarchive()

int flamarchive ( const char * cmd,
const char * pro,
const char * out,
const char * trc )
extern

FLAM ARCHIVE - Runs archive functions.

This function calls the ARCHIVE command of FLCL

Examples: e=flamarchive( "ARCHIVE.COMP(READ.TEXT(FILE='mydata.txt' SUPTWS CCSID='CP125' CHRMODE=SUBSTITUTE " "TABLE='ssh://format@formats.company.de/my_format_variant.txt/&UTF-8') " "TO.NEW(STORE.FOLDER(PATH='ssh://user@mysshd/myfl5arch' OVERWRITE) " "FLAM(CMPSUITE=ZSTD CRYSUITE=V06-A22-CRC MBRMODE=APPEND RECMODE=KEYED " "ENCRYPT.PGP(DATA(ID='myself') MEMBER(ID='archive') SIGNID='myself'))) " "MESSAGE(MINIMAL))",NULL,":STDERR",NULL);

Parameters
[in]cmdCommand string with ARCHIVE instructions (if starts with '=', a parameter file containing the command string must follow)
[in]proProperty string with ARCHIVE instructions (can be empty or NULL)
[in]outFilename for printouts (if NULL or empty then stderr is used)
[in]trcFilename for tracing (if NULL or empty then no trace is written)
Returns
signed integer with condition code for the command

◆ flamrsn()

int flamrsn ( void )
extern

Get reason code.

This function return the reason code (internal FLAM error code) if a call to a FLCL command fails.

Returns
signed integer with internal FLAM reason code

◆ flammsg()

const char * flammsg ( const int rsn)
extern

Get a message for a reason code.

Parameters
[in]rsnSigned integer containing the reason code
Returns
a pointer to a static area with a zero-terminated string containing the error message for that reason code.

◆ flamhlp()

void flamhlp ( const int what,
const int depth,
const char * path,
const char * out )
extern

Returns help information about the command string.

This function can be used to get all help messages or man pages for each parameter in the command string. If depth 0 or greater than 9 aliases are provided. In all other cases aliases are suppressed. Please use flamsyn() to see possible aliases for the same argument.

Parameters
[in]whatInteger constant for the corresponding command string (FLAM_ARCHIVE)
[in]depthNumber of levels to display (0-Man page, 1-One Level, 2-Two Level, ..., <9-All)
[in]pathPath (e.g. archive.list.store) to limit help to the (sub)tree of a certain object
[in]outFilename for printouts (if NULL or empty then stderr is used)

◆ flamsyn()

void flamsyn ( const int what,
const int depth,
const char * path,
const char * out )
extern

Return syntax information about the command string.

This function can be used to determine the complete syntax of the command strings.

Parameters
[in]whatInteger constant for the corresponding command string (FLAM_ARCHIVE)
[in]depthNumber of levels to display (0-Man page, 1-One Level, 2-Two Level, ..., <9-All)
[in]pathPath (e.g. archive.comp.store) to limit syntax to the (sub)tree of a certain object
[in]outFilename for printouts (if NULL or empty then stderr is used)

◆ flamdoc()

void flamdoc ( const int what,
const char * path,
const char * out )
extern

Return documentation.

This function can be used to determine the complete documentation of the corresponding command.

Parameters
[in]whatInteger constant for the corresponding command string (FLAM_ARCHIVE)
[in]pathPath (e.g. achive.deco.store) to limit docu to the (sub)tree of a certain object
[in]outFilename for printouts (if NULL or empty then stderr is used)

◆ flampro()

void flampro ( const int what,
const char * ipro,
const char * prop,
const char * opro,
const char * out )
extern

Manage properties.

This function can be used to manage a property file for one of the supported commands. You can generate a property file if 'ipro' NULL and 'opro' defined. You can printout the properties if 'ipro' defined and 'opro' is NULL. You can validate and copy property files if 'ipro' and 'opro' defined. You can adjust a property file if 'ipro' defined, 'prop' are used and 'opro' set.

Parameters
[in]whatInteger constant for the corresponding command (FLAM_ARCHIVE)
[in]iproProperty file to read (if NULL or empty then then no property file is read)
[in]propProperty string to manipulate the current properties (if NULL or empty then no update is done)
[in]oproProperty file to write (if NULL or empty then stdout is used)
[in]outFilename for printouts (if NULL or empty then is no printout produced)