Guardian Programmer's Guide

Table Of Contents
Guardian Programmer’s Guide 421922-014
13 - 1
13
Manipulating File Names
This section describes how an application program can manipulate file names or the
names of entities, such as nodes or volumes, that make up parts of file names. See
Section 2, Using the File System, if you are unsure about the format of file names.
A typical use of the features described here is to manipulate file names or file-name
patterns presented to a program using a TACL command. You can use these features
to check or process the file names or patterns received in the Startup or Param
message. A program listing at the end of this section shows an example.
This section discusses how to perform the following operations on file names:
Scan a string of characters to find out whether it contains a valid file name
(FILENAME_SCAN_ procedure).
Resolve a file name into its fully qualified form (FILENAME_RESOLVE_
procedure).
Reduce a file name to its shortest usable form by removing the default node name,
volume, or subvolume portions (FILENAME_UNRESOLVE_ procedure).
Extract selected portions of a file name (FILENAME_DECOMPOSE_ procedure).
Modify portions of a file name (FILENAME_EDIT_ procedure).
Compare two file names to see whether they identify the same object
(FILENAME_COMPARE_ procedure).
Search for file names using file-name patterns (FILENAME_FINDSTART_,
FILENAME_FINDNEXT_, FILENAME_FINDFINISH_, and FILENAME_MATCH_
procedures).
Overview
The procedures described in this section can manipulate file names for disk files and
device files alike. Process file names can also be manipulated by the procedures
listed above.
Many of the procedures listed above can also be used with DEFINE names, as
described later in this section.
Refer to Section 16, Creating and Managing Processes, for information about
procedures that manipulate process handles.