Edit File by line
/home/barbar84/public_h.../wp-conte.../plugins/sujqvwi/ExeBy/smexe_ro.../usr/include/bind9/isc
File: stats.h
/*
[0] Fix | Delete
* Copyright (C) Internet Systems Consortium, Inc. ("ISC")
[1] Fix | Delete
*
[2] Fix | Delete
* This Source Code Form is subject to the terms of the Mozilla Public
[3] Fix | Delete
* License, v. 2.0. If a copy of the MPL was not distributed with this
[4] Fix | Delete
* file, you can obtain one at https://mozilla.org/MPL/2.0/.
[5] Fix | Delete
*
[6] Fix | Delete
* See the COPYRIGHT file distributed with this work for additional
[7] Fix | Delete
* information regarding copyright ownership.
[8] Fix | Delete
*/
[9] Fix | Delete
[10] Fix | Delete
[11] Fix | Delete
#ifndef ISC_STATS_H
[12] Fix | Delete
#define ISC_STATS_H 1
[13] Fix | Delete
[14] Fix | Delete
/*! \file isc/stats.h */
[15] Fix | Delete
[16] Fix | Delete
#include <inttypes.h>
[17] Fix | Delete
[18] Fix | Delete
#include <isc/types.h>
[19] Fix | Delete
[20] Fix | Delete
ISC_LANG_BEGINDECLS
[21] Fix | Delete
[22] Fix | Delete
/*%<
[23] Fix | Delete
* Flag(s) for isc_stats_dump().
[24] Fix | Delete
*/
[25] Fix | Delete
#define ISC_STATSDUMP_VERBOSE 0x00000001 /*%< dump 0-value counters */
[26] Fix | Delete
[27] Fix | Delete
/*%<
[28] Fix | Delete
* Dump callback type.
[29] Fix | Delete
*/
[30] Fix | Delete
typedef void (*isc_stats_dumper_t)(isc_statscounter_t, uint64_t, void *);
[31] Fix | Delete
[32] Fix | Delete
isc_result_t
[33] Fix | Delete
isc_stats_create(isc_mem_t *mctx, isc_stats_t **statsp, int ncounters);
[34] Fix | Delete
/*%<
[35] Fix | Delete
* Create a statistics counter structure of general type. It counts a general
[36] Fix | Delete
* set of counters indexed by an ID between 0 and ncounters -1.
[37] Fix | Delete
*
[38] Fix | Delete
* Requires:
[39] Fix | Delete
*\li 'mctx' must be a valid memory context.
[40] Fix | Delete
*
[41] Fix | Delete
*\li 'statsp' != NULL && '*statsp' == NULL.
[42] Fix | Delete
*
[43] Fix | Delete
* Returns:
[44] Fix | Delete
*\li ISC_R_SUCCESS -- all ok
[45] Fix | Delete
*
[46] Fix | Delete
*\li anything else -- failure
[47] Fix | Delete
*/
[48] Fix | Delete
[49] Fix | Delete
void
[50] Fix | Delete
isc_stats_attach(isc_stats_t *stats, isc_stats_t **statsp);
[51] Fix | Delete
/*%<
[52] Fix | Delete
* Attach to a statistics set.
[53] Fix | Delete
*
[54] Fix | Delete
* Requires:
[55] Fix | Delete
*\li 'stats' is a valid isc_stats_t.
[56] Fix | Delete
*
[57] Fix | Delete
*\li 'statsp' != NULL && '*statsp' == NULL
[58] Fix | Delete
*/
[59] Fix | Delete
[60] Fix | Delete
void
[61] Fix | Delete
isc_stats_detach(isc_stats_t **statsp);
[62] Fix | Delete
/*%<
[63] Fix | Delete
* Detaches from the statistics set.
[64] Fix | Delete
*
[65] Fix | Delete
* Requires:
[66] Fix | Delete
*\li 'statsp' != NULL and '*statsp' is a valid isc_stats_t.
[67] Fix | Delete
*/
[68] Fix | Delete
[69] Fix | Delete
int
[70] Fix | Delete
isc_stats_ncounters(isc_stats_t *stats);
[71] Fix | Delete
/*%<
[72] Fix | Delete
* Returns the number of counters contained in stats.
[73] Fix | Delete
*
[74] Fix | Delete
* Requires:
[75] Fix | Delete
*\li 'stats' is a valid isc_stats_t.
[76] Fix | Delete
*
[77] Fix | Delete
*/
[78] Fix | Delete
[79] Fix | Delete
void
[80] Fix | Delete
isc_stats_increment(isc_stats_t *stats, isc_statscounter_t counter);
[81] Fix | Delete
/*%<
[82] Fix | Delete
* Increment the counter-th counter of stats.
[83] Fix | Delete
*
[84] Fix | Delete
* Requires:
[85] Fix | Delete
*\li 'stats' is a valid isc_stats_t.
[86] Fix | Delete
*
[87] Fix | Delete
*\li counter is less than the maximum available ID for the stats specified
[88] Fix | Delete
* on creation.
[89] Fix | Delete
*/
[90] Fix | Delete
[91] Fix | Delete
void
[92] Fix | Delete
isc_stats_decrement(isc_stats_t *stats, isc_statscounter_t counter);
[93] Fix | Delete
/*%<
[94] Fix | Delete
* Decrement the counter-th counter of stats.
[95] Fix | Delete
*
[96] Fix | Delete
* Requires:
[97] Fix | Delete
*\li 'stats' is a valid isc_stats_t.
[98] Fix | Delete
*/
[99] Fix | Delete
[100] Fix | Delete
void
[101] Fix | Delete
isc_stats_dump(isc_stats_t *stats, isc_stats_dumper_t dump_fn, void *arg,
[102] Fix | Delete
unsigned int options);
[103] Fix | Delete
/*%<
[104] Fix | Delete
* Dump the current statistics counters in a specified way. For each counter
[105] Fix | Delete
* in stats, dump_fn is called with its current value and the given argument
[106] Fix | Delete
* arg. By default counters that have a value of 0 is skipped; if options has
[107] Fix | Delete
* the ISC_STATSDUMP_VERBOSE flag, even such counters are dumped.
[108] Fix | Delete
*
[109] Fix | Delete
* Requires:
[110] Fix | Delete
*\li 'stats' is a valid isc_stats_t.
[111] Fix | Delete
*/
[112] Fix | Delete
[113] Fix | Delete
void
[114] Fix | Delete
isc_stats_set(isc_stats_t *stats, uint64_t val,
[115] Fix | Delete
isc_statscounter_t counter);
[116] Fix | Delete
/*%<
[117] Fix | Delete
* Set the given counter to the specified value.
[118] Fix | Delete
*
[119] Fix | Delete
* Requires:
[120] Fix | Delete
*\li 'stats' is a valid isc_stats_t.
[121] Fix | Delete
*/
[122] Fix | Delete
[123] Fix | Delete
void
[124] Fix | Delete
isc_stats_set(isc_stats_t *stats, uint64_t val,
[125] Fix | Delete
isc_statscounter_t counter);
[126] Fix | Delete
/*%<
[127] Fix | Delete
* Set the given counter to the specified value.
[128] Fix | Delete
*
[129] Fix | Delete
* Requires:
[130] Fix | Delete
*\li 'stats' is a valid isc_stats_t.
[131] Fix | Delete
*/
[132] Fix | Delete
[133] Fix | Delete
void isc_stats_update_if_greater(isc_stats_t *stats,
[134] Fix | Delete
isc_statscounter_t counter,
[135] Fix | Delete
uint64_t value);
[136] Fix | Delete
/*%<
[137] Fix | Delete
* Atomically assigns 'value' to 'counter' if value > counter.
[138] Fix | Delete
*
[139] Fix | Delete
* Requires:
[140] Fix | Delete
*\li 'stats' is a valid isc_stats_t.
[141] Fix | Delete
*
[142] Fix | Delete
*\li counter is less than the maximum available ID for the stats specified
[143] Fix | Delete
* on creation.
[144] Fix | Delete
*/
[145] Fix | Delete
[146] Fix | Delete
uint64_t
[147] Fix | Delete
isc_stats_get_counter(isc_stats_t *stats, isc_statscounter_t counter);
[148] Fix | Delete
/*%<
[149] Fix | Delete
* Returns value currently stored in counter.
[150] Fix | Delete
*
[151] Fix | Delete
* Requires:
[152] Fix | Delete
*\li 'stats' is a valid isc_stats_t.
[153] Fix | Delete
*
[154] Fix | Delete
*\li counter is less than the maximum available ID for the stats specified
[155] Fix | Delete
* on creation.
[156] Fix | Delete
*/
[157] Fix | Delete
[158] Fix | Delete
ISC_LANG_ENDDECLS
[159] Fix | Delete
[160] Fix | Delete
#endif /* ISC_STATS_H */
[161] Fix | Delete
[162] Fix | Delete
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function