This file is indexed.

/usr/include/collectd/client.h is in libcollectdclient-dev 4.10.1-2.1ubuntu7.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
/**
 * libcollectdclient - src/libcollectdclient/client.h
 * Copyright (C) 2008  Florian octo Forster
 *
 * This program is free software; you can redistribute it and/or modify it
 * under the terms of the GNU General Public License as published by the
 * Free Software Foundation; only version 2 of the License is applicable.
 *
 * This program is distributed in the hope that it will be useful, but
 * WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License along
 * with this program; if not, write to the Free Software Foundation, Inc.,
 * 51 Franklin St, Fifth Floor, Boston, MA  02110-1301 USA
 *
 * Authors:
 *   Florian octo Forster <octo at verplant.org>
 **/

#ifndef LIBCOLLECTD_COLLECTDCLIENT_H
#define LIBCOLLECTD_COLLECTDCLIENT_H 1

#include "lcc_features.h"

/*
 * Includes (for data types)
 */
#if HAVE_STDINT_H
# include <stdint.h>
#endif
#include <inttypes.h>
#include <time.h>

/*
 * Defines
 */
#define LCC_NAME_LEN 64
#define LCC_DEFAULT_PORT "25826"

/*
 * Types
 */
#define LCC_TYPE_COUNTER 0
#define LCC_TYPE_GAUGE   1
#define LCC_TYPE_DERIVE   2
#define LCC_TYPE_ABSOLUTE   3

LCC_BEGIN_DECLS

typedef uint64_t counter_t;
typedef double gauge_t;
typedef uint64_t derive_t;
typedef uint64_t absolute_t;

union value_u
{
  counter_t counter;
  gauge_t   gauge;
  derive_t  derive;
  absolute_t absolute;
};
typedef union value_u value_t;

struct lcc_identifier_s
{
  char host[LCC_NAME_LEN];
  char plugin[LCC_NAME_LEN];
  char plugin_instance[LCC_NAME_LEN];
  char type[LCC_NAME_LEN];
  char type_instance[LCC_NAME_LEN];
};
typedef struct lcc_identifier_s lcc_identifier_t;
#define LCC_IDENTIFIER_INIT { "localhost", "", "", "", "" }

struct lcc_value_list_s
{
  value_t *values;
  int     *values_types;
  size_t   values_len;
  time_t   time;
  int      interval;
  lcc_identifier_t identifier;
};
typedef struct lcc_value_list_s lcc_value_list_t;
#define LCC_VALUE_LIST_INIT { NULL, 0, 0, 0, LCC_IDENTIFIER_INIT }

struct lcc_connection_s;
typedef struct lcc_connection_s lcc_connection_t;

/*
 * Functions
 */
int lcc_connect (const char *address, lcc_connection_t **ret_con);
int lcc_disconnect (lcc_connection_t *c);
#define LCC_DESTROY(c) do { lcc_disconnect (c); (c) = NULL; } while (0)

int lcc_getval (lcc_connection_t *c, lcc_identifier_t *ident,
    size_t *ret_values_num, gauge_t **ret_values, char ***ret_values_names);

int lcc_putval (lcc_connection_t *c, const lcc_value_list_t *vl);

int lcc_flush (lcc_connection_t *c, const char *plugin,
    lcc_identifier_t *ident, int timeout);

int lcc_listval (lcc_connection_t *c,
    lcc_identifier_t **ret_ident, size_t *ret_ident_num);

/* TODO: putnotif */

const char *lcc_strerror (lcc_connection_t *c);

int lcc_identifier_to_string (lcc_connection_t *c,
    char *string, size_t string_size, const lcc_identifier_t *ident);
int lcc_string_to_identifier (lcc_connection_t *c,
    lcc_identifier_t *ident, const char *string);

LCC_END_DECLS

/* vim: set sw=2 sts=2 et : */
#endif /* LIBCOLLECTD_COLLECTDCLIENT_H */