Retrieves metadata from the information catalog and translates it to tag language in a file.
Authorization
Administrator or authorized user
Syntax
APIRET APIENTRY FLGExport( PSZ pszTagFileID,
PSZ pszLogFileID,
PSZ pszIcoPath,
PFLGHEADERAREA pListStruct,
PFLGEXTCODE pExtCode );
Parameters
This parameter contains the drive, directory path, and file name, and must be valid for a file allocation table (FAT) or HPFS file. The target drive for this file can be either a fixed or removable disk. If you type only the file name, the Information Catalog Manager places the tag language file on the drive and path pointed to by the DGWPATH environment variable.
The target tag language file must not exist; the Information Catalog Manager does not overwrite existing tag files.
The file name and extension (excluding the drive and directories) cannot exceed 240 characters. The entire tag language file ID cannot exceed 259 characters.
This parameter contains the drive, directory path, and file name, and must be valid for a FAT or HPFS file. The target drive for the log file must be a fixed disk. The log file ID cannot exceed 259 characters. If you specify only a file name, the Information Catalog Manager places the log file on the drive and path pointed to by the DGWPATH environment variable.
If the log file specified in this parameter does not exist, a new file is created. If the log file specified in this parameter already exists, then the FLGExport API call appends to it.
This parameter is optional. If this parameter is NULL, no icon files are exported.
This parameter contains the drive and directories and must be valid for a FAT or HPFS file. This parameter cannot be longer than 246 characters.
If this parameter is specified, the target drive for the icon files must be a fixed disk.
See Appendix D, Information Catalog Manager reason codes for an explanation of the returned reason codes.
Input structure
To use FLGExport, you must define the input structure shown in Figure 65. This structure contains the header area, the definition area, and the object area.
Figure 65. FLGExport input structure
For an explanation of the meanings of the byte offsets, see The Information Catalog Manager API input structure.
Usage
Input structure
The definition area for the FLGExport input structure must be specified exactly as shown in Figure 65.
The input structure for FLGExport contains the following information:
Characters 1-6 of this ID identify the object type of this instance.
Characters 7-16 of this ID are the system-generated unique instance identifier.
You can export any Information Catalog Manager object instances.
Generated tag language file
FLGExport generates a tag language file that contains tags for each object
instance exported. Depending on what you specify for the indicators,
object instances are exported as shown in Table 16.
Table 16. Object instances exported to tag language file for indicator combinations
Indicator value | Exports: | |||||
---|---|---|---|---|---|---|
CONTAINEE | CONTACT | ATTACHMENT | LINK | |||
Y | Y | Y | Y | a through j | ||
Y | Y | Y | N | a, b, c, d, g, h, i, j | ||
Y | Y | N | Y | a, b, e, f, g, h | ||
Y | Y | N | N | a, b, g, h | ||
Y | N | Y | Y | a, b, c, d, e, f | ||
Y | N | Y | N | a, b, c, d | ||
Y | N | N | N | a, b | ||
Y | N | N | Y | a, b, e, f | ||
N | Y | Y | Y | a, c, e, g, i | ||
N | Y | Y | N | a, c, g, i | ||
N | Y | N | Y | a, e, g | ||
N | N | Y | Y | a, c, e | ||
N | N | Y | N | a, c | ||
N | N | N | Y | a, e | ||
N | N | N | N | a only | ||
|
FLGExport generates frequent COMMIT tags in the tag language file.
FLGExport places a copy of the icon associated with each object type in the specified icon path. FLGExport does not export the default category icons if no other icon is associated with the object type. The name of the exported icon file is the object type DP NAME (short name) with an extension of .ICO for OS/2 icons or .ICW for Windows icons.
Linking your VisualAge C++ program when it exports metadata to diskettes
If your C language program issues an FLGExport call that exports the Information Catalog Manager information to diskettes, link your program with an application type of WINDOWAPI so that the Information Catalog Manager can use Presentation Manager(R) (PM) interface display messages that prompt the user for diskettes when necessary.
You can perform this linking using one of these methods:
Figure 66 shows the C language code required to invoke the FLGExport API call. This sample code exports three Information Catalog Manager objects. All three objects are Grouping objects:
Figure 66. Sample C language call to FLGExport
APIRET rc; // Declare reason code
UCHAR pszTagFileID[FLG_TAG_FILE_ID_MAXLEN + 1]; // Tag file id
UCHAR pszLogFileID[FLG_LOG_FILE_ID_MAXLEN + 1]; // Log file id
UCHAR pszIcoPath[FLG_ICON_PATH_MAXLEN + 1]; // icon files path
PFLGHEADERAREA pListStruct; // pointer to the input structure
FLGEXTCODE ExtCode=0; // declare an extended code for API
.
. /* set values for Tag file/ Log file/ Icon path */
. /* create object list */
.
rc = FLGExport (pszTagFileID,
pszLogFileID,
pszIcoPath,
pListStruct, // Pass input structure
&ExtCode); // Pass pointer to extended code
Figure 67 shows the input structure for the FLGExport call.
Figure 67. Sample input structure for FLGExport