Coda Distributed File System
coda-src
partition
vicetab.h
Go to the documentation of this file.
1
/* BLURB gpl
2
3
Coda File System
4
Release 6
5
6
Copyright (c) 1987-2003 Carnegie Mellon University
7
Additional copyrights listed below
8
9
This code is distributed "AS IS" without warranty of any kind under
10
the terms of the GNU General Public Licence Version 2, as shown in the
11
file LICENSE. The technical and financial contributors to Coda are
12
listed in the file CREDITS.
13
14
Additional copyrights
15
none currently
16
17
#*/
18
19
#ifndef VICETAB_INCLUDED
20
#define VICETAB_INCLUDED
21
22
#include <stdio.h>
23
24
/* this file is used for parsing routines of /vice/vicetab, the file
25
* describing server partitions.
26
* Its structure is similar to fstab:
27
* we have space or tab separated fields:
28
* part_host hostname of server
29
* part_dir a pathname identifying the server directory or partition
30
* part_type the type of server partition found under part_dir
31
* a comma separated list of options of the form:
32
* opt1=value1,opt2=value2,....
33
*
34
* the semantics of the functions setpartent, getpartent, endpartent
35
* and addpartent are very similar to the corresponding mntent
36
* functions (see getmntent (3)).
37
* However, for increased sanity the structure is not exposed.
38
*/
39
40
#define VICETAB "/vice/vicetab"
41
#define VICETAB_MAXSTR 256
/* max line length in VICETAB */
42
43
/* supported types of server partitions */
44
#define PTYPE_SIMPLE "simple"
45
#define PTYPE_FTREE "ftree"
46
47
typedef
struct
Partent_s
*
Partent
;
48
49
Partent
Partent_new
();
50
void
Partent_free
(
Partent
*
f
);
51
FILE *
Partent_set
(
const
char
*
file
,
const
char
*mode);
52
int
Partent_end
(FILE *__filep);
53
Partent
Partent_get
(FILE *filep);
54
int
Partent_add
(FILE *__filep,
Partent
mnt);
55
char
*
Partent_hasopt
(
Partent
mnt,
const
char
*opt);
56
int
Partent_intopt
(
Partent
ent,
const
char
*opt,
int
*value);
57
void
Partent_print
(
Partent
ent);
58
char
*
Partent_dir
(
Partent
p);
59
char
*
Partent_type
(
Partent
p);
60
char
*
Partent_host
(
Partent
p);
61
Partent
Partent_create
(
char
*host,
char
*
dir
,
char
*
type
,
char
*opts);
62
63
#endif
/* _VICETAB_H_ */
file
FILE * file
Definition:
dirtest.c:723
dir
struct @31::@33 dir
type
void(* type)()
Definition:
rp2main.c:424
f
@ f
Definition:
rvm_private.h:416
Partent_s
Definition:
vicetab.c:28
Partent_free
void Partent_free(Partent *f)
Definition:
vicetab.c:41
Partent
struct Partent_s * Partent
Definition:
vicetab.h:47
Partent_host
char * Partent_host(Partent p)
Definition:
vicetab.c:185
Partent_new
Partent Partent_new()
Definition:
vicetab.c:35
Partent_end
int Partent_end(FILE *__filep)
Definition:
vicetab.c:52
Partent_create
Partent Partent_create(char *host, char *dir, char *type, char *opts)
Definition:
vicetab.c:97
Partent_print
void Partent_print(Partent ent)
Partent_add
int Partent_add(FILE *__filep, Partent mnt)
Definition:
vicetab.c:116
Partent_set
FILE * Partent_set(const char *file, const char *mode)
Definition:
vicetab.c:47
Partent_type
char * Partent_type(Partent p)
Definition:
vicetab.c:194
Partent_intopt
int Partent_intopt(Partent ent, const char *opt, int *value)
Definition:
vicetab.c:74
Partent_hasopt
char * Partent_hasopt(Partent mnt, const char *opt)
Definition:
vicetab.c:63
Partent_dir
char * Partent_dir(Partent p)
Definition:
vicetab.c:203
Partent_get
Partent Partent_get(FILE *filep)
Definition:
vicetab.c:133
Generated by
1.9.4