#include <printerdb.h>
void prdb_set(char *domain);
prdb_ent *prdb_get(void);
prdb_ent *prdb_getbyname(const char *name);
void prdb_end(void);
prdb_ent *prdb; prdb_set(NULL); while (prdb = prdb_get()) { handle(prdb); } prdb_end();
The structure returned by prdb_getbyname and prdb_get is defined as follows:
typedef struct prdb_property { char *pp_key; char *pp_value; } prdb_property; typedef struct prdb_ent { char **pe_name; unsigned pe_nprops; prdb_property *pe_prop; } prdb_ent;
pe_name the name of the printer entry. pe_nprops is the number of members of this printer entry. pe_props is an array of prdb_property structures, which each contain the name and value for various properties of the printer. See printcap(5) for a description of these values.
A call to any of the printerdb(3) routines invalidates the information returned from a previous call.
Created by unroff & hp-tools. © somebody (See intro for details). All Rights Reserved. Last modified 11/5/97