]>
Commit | Line | Data |
---|---|---|
ef416fc2 | 1 | /* |
503b54c9 | 2 | * Policy definitions for the CUPS scheduler. |
ef416fc2 | 3 | * |
503b54c9 MS |
4 | * Copyright 2007-2010 by Apple Inc. |
5 | * Copyright 1997-2005 by Easy Software Products, all rights reserved. | |
ef416fc2 | 6 | * |
e3101897 | 7 | * Licensed under Apache License v2.0. See the file "LICENSE" for more information. |
ef416fc2 | 8 | */ |
9 | ||
10 | ||
11 | /* | |
12 | * Policy structure... | |
13 | */ | |
14 | ||
15 | typedef struct | |
16 | { | |
17 | char *name; /* Policy name */ | |
10d09e33 MS |
18 | cups_array_t *job_access, /* Private users/groups for jobs */ |
19 | *job_attrs, /* Private attributes for jobs */ | |
20 | *sub_access, /* Private users/groups for subscriptions */ | |
21 | *sub_attrs, /* Private attributes for subscriptions */ | |
22 | *ops; /* Operations */ | |
ef416fc2 | 23 | } cupsd_policy_t; |
24 | ||
10d09e33 MS |
25 | typedef struct cupsd_printer_s cupsd_printer_t; |
26 | ||
ef416fc2 | 27 | |
28 | /* | |
29 | * Globals... | |
30 | */ | |
31 | ||
2e4ff8af | 32 | VAR cups_array_t *Policies VALUE(NULL); |
ef416fc2 | 33 | /* Policies */ |
34 | ||
35 | ||
36 | /* | |
37 | * Prototypes... | |
38 | */ | |
39 | ||
40 | extern cupsd_policy_t *cupsdAddPolicy(const char *policy); | |
41 | extern cupsd_location_t *cupsdAddPolicyOp(cupsd_policy_t *p, | |
42 | cupsd_location_t *po, | |
43 | ipp_op_t op); | |
44 | extern http_status_t cupsdCheckPolicy(cupsd_policy_t *p, cupsd_client_t *con, | |
45 | const char *owner); | |
46 | extern void cupsdDeleteAllPolicies(void); | |
47 | extern cupsd_policy_t *cupsdFindPolicy(const char *policy); | |
48 | extern cupsd_location_t *cupsdFindPolicyOp(cupsd_policy_t *p, ipp_op_t op); | |
10d09e33 MS |
49 | extern cups_array_t *cupsdGetPrivateAttrs(cupsd_policy_t *p, |
50 | cupsd_client_t *con, | |
51 | cupsd_printer_t *printer, | |
52 | const char *owner); |