File: filesystem.h.html

package info (click to toggle)
rudiments 0.31-2
  • links: PTS
  • area: main
  • in suites: lenny
  • size: 7,516 kB
  • ctags: 3,248
  • sloc: asm: 23,776; cpp: 22,792; sh: 7,769; ansic: 1,769; makefile: 1,054; xml: 169; perl: 19
file content (285 lines) | stat: -rw-r--r-- 26,477 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
<html>
<head>
<title>~/src/firstworks/rudiments-0.31/include/rudiments/filesystem.h.html</title>
<meta name="Generator" content="Vim/7.0">
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
</head>
<body bgcolor="#ffffff" text="#000000">
<pre>
<font color="#0000ff">// Copyright (c) 2003 David Muse</font>
<font color="#0000ff">// See the COPYING file for more information.</font>

<font color="#a020f0">#ifndef RUDIMENTS_FILESYSTEM_H</font>
<font color="#a020f0">#define RUDIMENTS_FILESYSTEM_H</font>

<font color="#a020f0">#include </font><font color="#ff00ff">&lt;rudiments/private/filesystemincludes.h&gt;</font>

<font color="#0000ff">// The filesystem class provides methods for discovering the properties</font>
<font color="#0000ff">// associated with a filesystem such as type, total and free blocks, total and</font>
<font color="#0000ff">// free inodes, etc.</font>
<font color="#0000ff">//</font>
<font color="#0000ff">// Use the static methods in this class if you need to get a a single property.</font>
<font color="#0000ff">//</font>
<font color="#0000ff">// If you need to get more that one property, create an instance of the class,</font>
<font color="#0000ff">// call initialize(), then use the non-static methods to access the properties</font>
<font color="#0000ff">// that you need.</font>

<font color="#a020f0">#ifdef RUDIMENTS_NAMESPACE</font>
<font color="#2e8b57"><b>namespace</b></font> rudiments {
<font color="#a020f0">#endif</font>

<font color="#2e8b57"><b>class</b></font> filesystemprivate;

<font color="#2e8b57"><b>class</b></font> filesystem {
        <font color="#a52a2a"><b>public</b></font>:
                                filesystem();
                                <font color="#0000ff">// Creates an uninitialized instance of the</font>
                                <font color="#0000ff">// filesystem class.</font>
                                filesystem(<font color="#2e8b57"><b>const</b></font> filesystem &amp;f);
                filesystem      &amp;<font color="#a52a2a"><b>operator</b></font>=(<font color="#2e8b57"><b>const</b></font> filesystem &amp;f);
                <font color="#2e8b57"><b>virtual</b></font>               ~filesystem();

                <font color="#2e8b57"><b>bool</b></font>  initialize(<font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> *path);
                        <font color="#0000ff">// Initializes the instance to use filesystem &quot;path&quot;.</font>
                        <font color="#0000ff">//</font>
                        <font color="#0000ff">// Returns true on success and false on failure.</font>
                <font color="#2e8b57"><b>bool</b></font>  initialize(<font color="#2e8b57"><b>int</b></font> fd);
                        <font color="#0000ff">// Initializes the instance to use already open file</font>
                        <font color="#0000ff">// descriptor &quot;fd&quot;.</font>
                        <font color="#0000ff">//</font>
                        <font color="#0000ff">// Returns true on success and false on failure.</font>

                <font color="#0000ff">// These methods return the filesystem type.</font>
                <font color="#0000ff">// (works on Linux, Net/Open/FreeBSD)</font>
                <font color="#0000ff">//</font>
                <font color="#0000ff">// The static methods return true on success and false on</font>
                <font color="#0000ff">// failure.</font>
                <font color="#2e8b57"><b>long</b></font>          getType() <font color="#2e8b57"><b>const</b></font>;
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getType(<font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> *path, <font color="#2e8b57"><b>long</b></font> *type);
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getType(<font color="#2e8b57"><b>int</b></font> fd, <font color="#2e8b57"><b>long</b></font> *type);

                <font color="#0000ff">// These methods return the fundamental block size of the</font>
                <font color="#0000ff">// filesystem.</font>
                <font color="#0000ff">// (works on Linux, Net/Open/FreeBSD, SCO OSR5, Solaris)</font>
                <font color="#0000ff">//</font>
                <font color="#0000ff">// The static methods return true on success and false on</font>
                <font color="#0000ff">// failure.</font>
                <font color="#2e8b57"><b>long</b></font>          getBlockSize() <font color="#2e8b57"><b>const</b></font>;
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getBlockSize(<font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> *path, <font color="#2e8b57"><b>long</b></font> *size);
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getBlockSize(<font color="#2e8b57"><b>int</b></font> fd, <font color="#2e8b57"><b>long</b></font> *size);

                <font color="#0000ff">// These methods return the optimum transfer block size.</font>
                <font color="#0000ff">// (works on Linux, Net/Open/FreeBSD, SCO OSR5, Solaris)</font>
                <font color="#0000ff">//</font>
                <font color="#0000ff">// The static methods return true on success and false on</font>
                <font color="#0000ff">// failure.</font>
                <font color="#2e8b57"><b>long</b></font>          getOptimumTransferBlockSize() <font color="#2e8b57"><b>const</b></font>;
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getOptimumTransferBlockSize(<font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> *path,
                                                                <font color="#2e8b57"><b>long</b></font> *size);
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getOptimumTransferBlockSize(<font color="#2e8b57"><b>int</b></font> fd, <font color="#2e8b57"><b>long</b></font> *size);

                <font color="#0000ff">// These methods return the total number of blocks.</font>
                <font color="#0000ff">// (works on Linux, Net/Open/FreeBSD, SCO OSR5, Solaris)</font>
                <font color="#0000ff">//</font>
                <font color="#0000ff">// The static methods return true on success and false on</font>
                <font color="#0000ff">// failure.</font>
                <font color="#2e8b57"><b>long</b></font>          getTotalBlocks() <font color="#2e8b57"><b>const</b></font>;
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getTotalBlocks(<font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> *path, <font color="#2e8b57"><b>long</b></font> *blocks);
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getTotalBlocks(<font color="#2e8b57"><b>int</b></font> fd, <font color="#2e8b57"><b>long</b></font> *blocks);

                <font color="#0000ff">// These methods return the number of free blocks.</font>
                <font color="#0000ff">// (works on Linux, Net/Open/FreeBSD, SCO OSR5, Solaris)</font>
                <font color="#0000ff">//</font>
                <font color="#0000ff">// The static methods return true on success and false on</font>
                <font color="#0000ff">// failure.</font>
                <font color="#2e8b57"><b>long</b></font>          getFreeBlocks() <font color="#2e8b57"><b>const</b></font>;
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getFreeBlocks(<font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> *path, <font color="#2e8b57"><b>long</b></font> *blocks);
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getFreeBlocks(<font color="#2e8b57"><b>int</b></font> fd, <font color="#2e8b57"><b>long</b></font> *blocks);

                <font color="#0000ff">// These methods return the number of blocks available to </font>
                <font color="#0000ff">// non-superuser accounts.</font>
                <font color="#0000ff">// (works on Linux, Net/Open/FreeBSD, SCO OSR5, Solaris)</font>
                <font color="#0000ff">//</font>
                <font color="#0000ff">// The static methods return true on success and false on</font>
                <font color="#0000ff">// failure.</font>
                <font color="#2e8b57"><b>long</b></font>          getAvailableBlocks() <font color="#2e8b57"><b>const</b></font>;
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getAvailableBlocks(<font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> *path,
                                                        <font color="#2e8b57"><b>long</b></font> *blocks);
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getAvailableBlocks(<font color="#2e8b57"><b>int</b></font> fd, <font color="#2e8b57"><b>long</b></font> *blocks);

                <font color="#0000ff">// These methods return the number of file nodes.</font>
                <font color="#0000ff">// (works on Linux, Net/Open/FreeBSD, SCO OSR5, Solaris)</font>
                <font color="#0000ff">//</font>
                <font color="#0000ff">// The static methods return true on success and false on</font>
                <font color="#0000ff">// failure.</font>
                <font color="#2e8b57"><b>long</b></font>          getTotalFileNodes() <font color="#2e8b57"><b>const</b></font>;
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getTotalFileNodes(<font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> *path,
                                                        <font color="#2e8b57"><b>long</b></font> *nodes);
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getTotalFileNodes(<font color="#2e8b57"><b>int</b></font> fd, <font color="#2e8b57"><b>long</b></font> *nodes);

                <font color="#0000ff">// These methods return the number of free file nodes.</font>
                <font color="#0000ff">// (works on Linux, Net/Open/FreeBSD, SCO OSR5, Solaris)</font>
                <font color="#0000ff">//</font>
                <font color="#0000ff">// The static methods return true on success and false on</font>
                <font color="#0000ff">// failure.</font>
                <font color="#2e8b57"><b>long</b></font>          getFreeFileNodes() <font color="#2e8b57"><b>const</b></font>;
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getFreeFileNodes(<font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> *path,
                                                        <font color="#2e8b57"><b>long</b></font> *nodes);
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getFreeFileNodes(<font color="#2e8b57"><b>int</b></font> fd, <font color="#2e8b57"><b>long</b></font> *nodes);

                <font color="#0000ff">// These methods return the number of file nodes available to </font>
                <font color="#0000ff">// non-superuser accounts.</font>
                <font color="#0000ff">// (works on SCO OSR5, Solaris)</font>
                <font color="#0000ff">//</font>
                <font color="#0000ff">// The static methods return true on success and false on</font>
                <font color="#0000ff">// failure.</font>
                <font color="#2e8b57"><b>long</b></font>          getAvailableFileNodes() <font color="#2e8b57"><b>const</b></font>;
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getAvailableFileNodes(<font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> *path,
                                                                <font color="#2e8b57"><b>long</b></font> *nodes);
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getAvailableFileNodes(<font color="#2e8b57"><b>int</b></font> fd, <font color="#2e8b57"><b>long</b></font> *nodes);

                <font color="#0000ff">// These methods return the file system id.</font>
                <font color="#0000ff">// (works on SCO OSR5, Solaris)</font>
                <font color="#0000ff">//</font>
                <font color="#0000ff">// The static methods return true on success and false on</font>
                <font color="#0000ff">// failure.</font>
                <font color="#2e8b57"><b>long</b></font>          getFileSystemId() <font color="#2e8b57"><b>const</b></font>;
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getFileSystemId(<font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> *path, <font color="#2e8b57"><b>long</b></font> *id);
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getFileSystemId(<font color="#2e8b57"><b>int</b></font> fd, <font color="#2e8b57"><b>long</b></font> *id);

                <font color="#0000ff">// These methods return the maximum length of filenames.</font>
                <font color="#0000ff">// (works on Linux, SCO OSR5, Solaris)</font>
                <font color="#0000ff">//</font>
                <font color="#0000ff">// The static methods return true on success and false on</font>
                <font color="#0000ff">// failure.</font>
                <font color="#2e8b57"><b>long</b></font>          getMaximumFileNameLength() <font color="#2e8b57"><b>const</b></font>;
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getMaximumFileNameLength(<font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> *path,
                                                        <font color="#2e8b57"><b>long</b></font> *length);
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getMaximumFileNameLength(<font color="#2e8b57"><b>int</b></font> fd,
                                                        <font color="#2e8b57"><b>long</b></font> *length);

                <font color="#0000ff">// These methods return the user that mounted the filesystem.</font>
                <font color="#0000ff">// (works on Net/Open/FreeBSD)</font>
                <font color="#0000ff">//</font>
                <font color="#0000ff">// The static methods return true on success and false on</font>
                <font color="#0000ff">// failure.</font>
                uid_t           getOwner() <font color="#2e8b57"><b>const</b></font>;
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getOwner(<font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> *path, uid_t *owner);
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getOwner(<font color="#2e8b57"><b>int</b></font> fd, uid_t *owner);

                <font color="#0000ff">// These methods return the number of synchronous writes that</font>
                <font color="#0000ff">// have occurred since the filesytem was mounted.</font>
                <font color="#0000ff">// (works on Net/Open/FreeBSD)</font>
                <font color="#0000ff">//</font>
                <font color="#0000ff">// The static methods return true on success and false on</font>
                <font color="#0000ff">// failure.</font>
                <font color="#2e8b57"><b>long</b></font>          getSyncWrites() <font color="#2e8b57"><b>const</b></font>;
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getSyncWrites(<font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> *path, <font color="#2e8b57"><b>long</b></font> *swrites);
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getSyncWrites(<font color="#2e8b57"><b>int</b></font> fd, <font color="#2e8b57"><b>long</b></font> *swrites);

                <font color="#0000ff">// These methods return the number of asynchronous writes that</font>
                <font color="#0000ff">// have occurred since the filesytem was mounted.</font>
                <font color="#0000ff">// (works on Net/Open/FreeBSD)</font>
                <font color="#0000ff">//</font>
                <font color="#0000ff">// The static methods return true on success and false on</font>
                <font color="#0000ff">// failure.</font>
                <font color="#2e8b57"><b>long</b></font>          getAsyncWrites() <font color="#2e8b57"><b>const</b></font>;
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getAsyncWrites(<font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> *path,
                                                        <font color="#2e8b57"><b>long</b></font> *aswrites);
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getAsyncWrites(<font color="#2e8b57"><b>int</b></font> fd, <font color="#2e8b57"><b>long</b></font> *aswrites);

                <font color="#0000ff">// These methods return the name of the filesystem type.</font>
                <font color="#0000ff">// (works on Net/Open/FreeBSD, SCO OSR5, Solaris)</font>
                <font color="#0000ff">//</font>
                <font color="#0000ff">// The static methods return true on success and false on</font>
                <font color="#0000ff">// failure.</font>
                <font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font>    *getTypeName() <font color="#2e8b57"><b>const</b></font>;
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getTypeName(<font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> *path,
                                                <font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> **name);
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getTypeName(<font color="#2e8b57"><b>int</b></font> fd, <font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> **name);

                <font color="#0000ff">// These methods return the mount point of the filesystem.</font>
                <font color="#0000ff">// (works on Net/Open/FreeBSD)</font>
                <font color="#0000ff">//</font>
                <font color="#0000ff">// The static methods return true on success and false on</font>
                <font color="#0000ff">// failure.</font>
                <font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font>    *getMountPoint() <font color="#2e8b57"><b>const</b></font>;
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getMountPoint(<font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> *path,
                                                        <font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> **mtpt);
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getMountPoint(<font color="#2e8b57"><b>int</b></font> fd, <font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> **mtpt);

                <font color="#0000ff">// These methods return the number of synchronous reads that</font>
                <font color="#0000ff">// have occurred since the filesytem was mounted.</font>
                <font color="#0000ff">// (works on FreeBSD)</font>
                <font color="#0000ff">//</font>
                <font color="#0000ff">// The static methods return true on success and false on</font>
                <font color="#0000ff">// failure.</font>
                <font color="#2e8b57"><b>long</b></font>          getSyncReads() <font color="#2e8b57"><b>const</b></font>;
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getSyncReads(<font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> *path, <font color="#2e8b57"><b>long</b></font> *sreads);
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getSyncReads(<font color="#2e8b57"><b>int</b></font> fd, <font color="#2e8b57"><b>long</b></font> *sreads);

                <font color="#0000ff">// These methods return the number of asynchronous reads that</font>
                <font color="#0000ff">// have occurred since the filesytem was mounted.</font>
                <font color="#0000ff">// (works on FreeBSD)</font>
                <font color="#0000ff">//</font>
                <font color="#0000ff">// The static methods return true on success and false on</font>
                <font color="#0000ff">// failure.</font>
                <font color="#2e8b57"><b>long</b></font>          getAsyncReads() <font color="#2e8b57"><b>const</b></font>;
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getAsyncReads(<font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> *path, <font color="#2e8b57"><b>long</b></font> *asreads);
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getAsyncReads(<font color="#2e8b57"><b>int</b></font> fd, <font color="#2e8b57"><b>long</b></font> *asreads);

                <font color="#0000ff">// These methods return the name of the device file for the</font>
                <font color="#0000ff">// filesystem.</font>
                <font color="#0000ff">// (works on Net/OpenBSD)</font>
                <font color="#0000ff">//</font>
                <font color="#0000ff">// The static methods return true on success and false on</font>
                <font color="#0000ff">// failure.</font>
                <font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font>    *getDeviceName() <font color="#2e8b57"><b>const</b></font>;
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getDeviceName(<font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> *path,
                                                        <font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> **devname);
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getDeviceName(<font color="#2e8b57"><b>int</b></font> fd, <font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> **devname);

                <font color="#0000ff">// These methods return the filesystem-specific string.</font>
                <font color="#0000ff">// (works on SCO OSR5, Solaris)</font>
                <font color="#0000ff">//</font>
                <font color="#0000ff">// The static methods return true on success and false on</font>
                <font color="#0000ff">// failure.</font>
                <font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font>    *getFilesystemSpecificString() <font color="#2e8b57"><b>const</b></font>;
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getFilesystemSpecificString(<font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> *path,
                                                        <font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> **str);
                <font color="#2e8b57"><b>static</b></font> <font color="#2e8b57"><b>bool</b></font>   getFilesystemSpecificString(<font color="#2e8b57"><b>int</b></font> fd,
                                                        <font color="#2e8b57"><b>const</b></font> <font color="#2e8b57"><b>char</b></font> **str);


                <font color="#0000ff">// NetBSD: u_short f_oflags - deprecated copy of mount flags</font>
                <font color="#0000ff">// NetBSD: u_short f_flags - mount flags</font>
                <font color="#0000ff">// OpenBSD: union mount_info mount_info - per fs mount options</font>
                <font color="#0000ff">// FreeBSD: int f_flags - mount flags</font>
                <font color="#0000ff">// SCO OSR5: unsigned long f_flag - mount flags</font>
                <font color="#0000ff">// solaris: u_long f_flag - mount flags</font>


                <font color="#2e8b57"><b>bool</b></font>  getCurrentProperties();
                        <font color="#0000ff">// Gets the current filesystem properties.</font>
                        <font color="#0000ff">//</font>
                        <font color="#0000ff">// Returns true on success and false on failure.</font>

                <font color="#0000ff">// This method returns a pointer to the statfs structure</font>
                <font color="#0000ff">// used internally.</font>
<font color="#a020f0">#if defined(RUDIMENTS_HAVE_STATVFS) || defined(RUDIMENTS_HAVE_NETBSD_STATVFS)</font>
                <font color="#2e8b57"><b>struct</b></font> statvfs        *getStatfs();
<font color="#a020f0">#else</font>
                <font color="#2e8b57"><b>struct</b></font> statfs *getStatfs();
<font color="#a020f0">#endif</font>

<font color="#a020f0">        #include </font><font color="#ff00ff">&lt;rudiments/private/filesystem.h&gt;</font>
};

<font color="#a020f0">#ifdef RUDIMENTS_NAMESPACE</font>
}
<font color="#a020f0">#endif</font>

<font color="#a020f0">#endif</font>
</pre>
</body>
</html>