1dnl $Id: m4.flags,v 10.145 2007/10/26 15:01:32 bostic Exp $
2dnl ###################################################################
3dnl FLAGS
4dnl ###################################################################
5dnl
6dnl OR'ing language.
7dnl
8define(m4_or, [bitwise inclusively m4_bold(OR)'ing])
9
10dnl
11dnl Unused flags.
12dnl
13define(m4_unusedflags, [dnl
14m4_param(flags, [dnl
15The m4_arg(flags) parameter is currently unused, and must be set to 0.])])
16
17dnl
18dnl Flags must be 0 or one of the following OR'd values.
19dnl
20define(m4_sf_or_may, [dnl
21The m4_arg(flags) parameter must be set to 0 or by m4_or together one
22or more of the following values:])
23
24dnl
25dnl Flags must be one of the following OR'd values.
26dnl
27define(m4_sf_or_must, [dnl
28The m4_arg(flags) parameter must be set by m4_or together one or more
29of the following values:])
30
31dnl
32dnl Flags may be added to by OR'ing one of the following values.
33dnl	#1 "0" if a single flag, "1" if multiple flags
34dnl
35define(m4_sf_or_add, [dnl
36In addition, the following ifelse([$1],0, flag, flags) may be set by
37m4_or ifelse([$1],0, it, them) into the m4_arg(flags) parameter:])
38
39dnl
40dnl Flags must be one of the following values.
41dnl
42define(m4_sf_must, [dnl
43The m4_arg(flags) parameter must be set to one of the following values:])
44
45dnl
46dnl Flags must be 0 or one of the following values.
47dnl	#1 "0" if a single flag, "1" if multiple flags
48dnl
49define(m4_sf_zmust, [dnl
50The m4_arg(flags) parameter must be set to 0 or
51ifelse([$1],0, the following value:, one of the following values:)])
52
53dnl ###################################################################
54dnl Additional flags: DB_AUTO_COMMIT
55dnl   #1 method
56dnl ###################################################################
57define(m4_autocommit_flag, [dnl
58m4_tag(m4_idef(DB_AUTO_COMMIT), [dnl
59Enclose the m4_ref($1) call within a transaction.  If the call succeeds,
60changes made by the operation will be recoverable.  If the call fails,
61the operation will have made no changes.])])
62
63dnl ###################################################################
64dnl Additional flags: RMW
65dnl	#1 additional text
66dnl ###################################################################
67define(m4_rmw_flag, [dnl
68m4_tag(m4_idef(DB_RMW), [dnl
69Acquire write locks instead of read locks when doing the read, if
70locking is configured.  Setting this flag can eliminate deadlock during
71a read-modify-write cycle by acquiring the write lock during the read
72part of the cycle so that another thread of control acquiring a read
73lock for the same item, in its own read-modify-write cycle, will not
74result in deadlock.
75ifelse([$1],,, [m4_p([$1])])])])
76
77dnl ###################################################################
78dnl lock_detect, set_lk_detect flags.
79dnl ###################################################################
80define(m4_lk_detect_flags, [dnl
81m4_tagbegin
82m4_tag(m4_idef(DB_LOCK_DEFAULT), [dnl
83Use whatever lock policy was specified when the database environment
84was created.  If no lock policy has yet been specified, set the lock
85policy to DB_LOCK_RANDOM.])
86m4_tag(m4_idef(DB_LOCK_EXPIRE), [dnl
87Reject lock requests which have timed out.  No other deadlock detection
88is performed.])
89m4_tag(m4_idef(DB_LOCK_MAXLOCKS), [dnl
90Reject the lock request for the locker ID with the most locks.])
91m4_tag(m4_idef(DB_LOCK_MAXWRITE), [dnl
92Reject the lock request for the locker ID with the most write locks.])
93m4_tag(m4_idef(DB_LOCK_MINLOCKS), [dnl
94Reject the lock request for the locker ID with the fewest locks.])
95m4_tag(m4_idef(DB_LOCK_MINWRITE), [dnl
96Reject the lock request for the locker ID with the fewest write locks.])
97m4_tag(m4_idef(DB_LOCK_OLDEST), [dnl
98Reject the lock request for the locker ID with the oldest lock.])
99m4_tag(m4_idef(DB_LOCK_RANDOM), [dnl
100Reject the lock request for a random locker ID.])
101m4_tag(m4_idef(DB_LOCK_YOUNGEST), [dnl
102Reject the lock request for the locker ID with the youngest lock.])
103m4_tagend])
104
105dnl ###################################################################
106dnl Cache priority.
107dnl #1 method
108dnl ###################################################################
109define(m4_cache_priority_explain, [m4_p([dnl
110The priority of a page biases the replacement algorithm to be more or
111less likely to discard a page when space is needed in the buffer pool.
112The bias is temporary, and pages will eventually be discarded if they
113are not referenced again.  The m4_refT($1) is only advisory, and does
114not guarantee pages will be treated in a specific way.])])
115
116define(m4_cache_priority_parameter, [dnl
117m4_param(priority, [dnl
118The m4_arg(priority) parameter must be set to one of the following
119values:
120m4_tagbegin
121m4_tag(m4_idef(DB_PRIORITY_VERY_LOW), [dnl
122The lowest priority: pages are the most likely to be discarded.])
123m4_tag(m4_idef(DB_PRIORITY_LOW), [The next lowest priority.])
124m4_tag(m4_idef(DB_PRIORITY_DEFAULT), [The default priority.])
125m4_tag(m4_idef(DB_PRIORITY_HIGH), [The next highest priority.])
126m4_tag(m4_idef(DB_PRIORITY_VERY_HIGH), [dnl
127The highest priority: pages are the least likely to be discarded.])
128m4_tagend])])
129
130dnl ###################################################################
131dnl Stat flags:
132dnl ###################################################################
133define(m4_stat_flags, [dnl
134m4_sf_zmust(0)
135m4_tagbegin
136m4_tag(m4_idef(DB_STAT_CLEAR), [dnl
137Reset statistics after returning their values.])
138m4_tagend])
139