1MrmOpenHierarchy(library call)                  MrmOpenHierarchy(library call)
2
3
4

NAME

6       MrmOpenHierarchy — Allocates a hierarchy ID and opens all the UID files
7       in the hierarchy
8

SYNOPSIS

10       #include <Mrm/MrmPublic.h>
11       Cardinal MrmOpenHierarchy(
12       MrmCount num_files,
13       String file_names_list[],
14       MrmOsOpenParamPtr *ancillary_structures_list,
15       MrmHierarchy *hierarchy_id);
16

DESCRIPTION

18       This routine is obsolete and exists  for  compatibility  with  previous
19       releases. It is replaced by MrmOpenHierarchyPerDisplay.  MrmOpenHierar‐
20       chy is identical to MrmOpenHierarchyPerDisplay except that MrmOpenHier‐
21       archy does not take a display argument.
22
23       num_files Specifies the number of files in the name list.
24
25       file_names_list
26                 Specifies an array of character strings that identify the UID
27                 files.
28
29       ancillary_structures_list
30                 A list  of  operating-system-dependent  ancillary  structures
31                 corresponding  to items such as filenames, clobber flags, and
32                 so forth.  This argument should be NULL for most  operations.
33                 If  you  need to reference this structure, see the definition
34                 of MrmOsOpenParamPtr in the MrmPublic.h header file for  more
35                 information.
36
37       hierarchy_id
38                 Returns  the  search  hierarchy  ID.  The search hierarchy ID
39                 identifies the list of UID files that MRM searches (in order)
40                 when performing subsequent fetch calls.
41
42       Each UID file string in file_names_list can specify either a full path‐
43       name or a filename.  If a UID file string has a leading slash  (/),  it
44       specifies a full pathname, and MRM opens the file as specified.  Other‐
45       wise, the UID file string specifies a  filename.   In  this  case,  MRM
46       looks  for  the file along a search path specified by the UIDPATH envi‐
47       ronment variable or by a default search path, which varies depending on
48       whether or not the XAPPLRESDIR environment variable is set.
49
50       The  UIDPATH  environment  variable  specifies a search path and naming
51       conventions associated with UID files.  It can contain the substitution
52       field  %U,  where the UID file string from the file_names_list argument
53       to MrmOpenHierarchyPerDisplay is substituted for %U.  It can also  con‐
54       tain  the  substitution fields accepted by XtResolvePathname.  The sub‐
55       stitution field %T is always mapped to uid.  The entire path  is  first
56       searched  with  %S mapped to .uid.  If no file is found, it is searched
57       again with %S mapped to NULL.
58
59       If no display is set prior to calling this function, the result of this
60       function's call to XtResolvePathname is undefined.
61
62       For  example,  the  following  UIDPATH  value and MrmOpenHierarchy call
63       cause MRM to open two separate UID files:
64
65       UIDPATH=/uidlib/%L/%U.uid:/uidlib/%U/%L
66         static char *uid_files[] = {"/usr/users/me/test.uid", "test2"};
67         MrmHierarchy  *Hierarchy_id;
68         MrmOpenHierarchy((MrmCount)2,uid_files, NULL, Hierarchy_id)
69
70       MRM opens the first file, /usr/users/me/test.uid, as specified  in  the
71       file_names_list  argument  to  MrmOpenHierarchy,  because  the UID file
72       string in the file_names_list argument specifies a full pathname.   MRM
73       looks  for  the  second  file, test2, first as /uidlib/%L/test2.uid and
74       second as /uidlib/test2/%L, where the display's language string is sub‐
75       stituted for %L.
76
77       After  MrmOpenHierarchy  opens the UID hierarchy, you should not delete
78       or modify the UID files until you close the UID  hierarchy  by  calling
79       MrmCloseHierarchy.
80
81       If  UIDPATH is not set but the environment variable XAPPLRESDIR is set,
82       MRM searches the following pathnames:
83
84          ·  %U%S
85
86          ·  $XAPPLRESDIR/%L/uid/%N/%U%S
87
88          ·  $XAPPLRESDIR/%l/uid/%N/%U%S
89
90          ·  $XAPPLRESDIR/uid/%N/%U%S
91
92          ·  $XAPPLRESDIR/%L/uid/%U%S
93
94          ·  $XAPPLRESDIR/%l/uid/%U%S
95
96          ·  $XAPPLRESDIR/uid/%U%S
97
98          ·  $HOME/uid/%U%S
99
100          ·  $HOME/%U%S
101
102          ·  /usr/lib/X11/%L/uid/%N/%U%S
103
104          ·  /usr/lib/X11/%l/uid/%N/%U%S
105
106          ·  /usr/lib/X11/uid/%N/%U%S
107
108          ·  /usr/lib/X11/%L/uid/%U%S
109
110          ·  /usr/lib/X11/%l/uid/%U%S
111
112          ·  /usr/lib/X11/uid/%U%S
113
114          ·  /usr/include/X11/uid/%U%S
115
116       If neither UIDPATH nor XAPPLRESDIR is set, MRM searches  the  following
117       pathnames:
118
119          ·  %U%S
120
121          ·  HOME/%L/uid/%N/%U%S
122
123          ·  HOME/%l/uid/%N/%U%S
124
125          ·  $HOME/uid/%N/%U%S
126
127          ·  $HOME/%L/uid/%U%S
128
129          ·  $HOME/%l/uid/%U%S
130
131          ·  $HOME/uid/%U%S
132
133          ·  $HOME/%U%S
134
135          ·  /usr/lib/X11/%L/uid/%N/%U%S
136
137          ·  /usr/lib/X11/%l/uid/%N/%U%S
138
139          ·  /usr/lib/X11/uid/%N/%U%S
140
141          ·  /usr/lib/X11/%L/uid/%U%S
142
143          ·  /usr/lib/X11/%l/uid/%U%S
144
145          ·  /usr/lib/X11/uid/%U%S
146
147          ·  /usr/include/X11/uid/%U%S
148
149       These  paths are defaults that vendors may change.  For example, a ven‐
150       dor   may   use   different   directories    for    /usr/lib/X11    and
151       /usr/include/X11.
152
153       The following substitutions are used in these paths:
154
155       %U        The UID file string, from the file_names_list argument.
156
157       %N        The class name of the application.
158
159       %L        The  display's language string.  This string is influenced by
160                 XtSetLanguageProc.  The default string is determined by call‐
161                 ing setlocale(LC_ALL, NULL).
162
163       %l        The language component of the display's language string.
164
165       %S        The  suffix  to  the  filename.   The  entire  path  is first
166                 searched with a suffix of .uid.  If no file is found,  it  is
167                 searched again with a NULL suffix.
168

RETURN

170       This function returns one of the following status return constants:
171
172       MrmSUCCESS
173                 The function executed successfully.
174
175       MrmNOT_FOUND
176                 File not found.
177
178       MrmFAILURE
179                 The function failed.
180
182       MrmOpenHierarchyPerDisplay(3) and MrmCloseHierarchy(3).
183
184
185
186                                                MrmOpenHierarchy(library call)
Impressum