projid(3c) projid(3c)
projid, projname, fprojid, fprojname - get project ID information
#include <proj.h>
prid_t projid(const char *name);
int projname(prid_t prid, char *buf, size_t len);
prid_t fprojid(PROJ token, const char *name);
int fprojname(PROJ token, prid_t prid, char *buf, size_t len);
The projid, projname and getprojall functions are used to obtain
information from the projid file. The projid function searches the
projid file for the project name and returns the corresponding numeric
project ID. The projname function searches the projid file for the
project ID prid and stores the corresponding ASCII name in the buffer
buf, up to a maximum of len-1 characters. The resulting string will
always be null-terminated.
The fprojid and fprojname functions are variants of projid and projname
that use a PROJ token to make them more efficient for repeated use.
Otherwise their operation is identical. For more details on creating a
PROJ token, see openproj(3C).
/etc/projid System project name to project ID mappings.
closeproj(3C), getprojall(3C), getprojuser(3C), openproj(3C), projid(4),
projects(5).
projid and fprojid return the appropriate project ID if successful, or -1
if not.
projname and fprojname return 1 if successful, 0 if not.
Both functions use fopen(3S) and are thus subject to its limitations.
Project ID information should be (optionally) obtained via NIS.
PPPPaaaaggggeeee 1111 [ Back ]
|