2 #define GRAPH_IDENT_H 1
4 #define ANY_TOKEN "/any/"
5 #define ALL_TOKEN "/all/"
8 typedef struct graph_ident_s graph_ident_t;
10 graph_ident_t *ident_create (const char *host,
11 const char *plugin, const char *plugin_instance,
12 const char *type, const char *type_instance);
13 graph_ident_t *ident_clone (const graph_ident_t *ident);
15 #define IDENT_FLAG_REPLACE_ALL 0x01
16 #define IDENT_FLAG_REPLACE_ANY 0x02
17 graph_ident_t *ident_copy_with_selector (const graph_ident_t *selector,
18 const graph_ident_t *ident, unsigned int flags);
20 void ident_destroy (graph_ident_t *ident);
22 const char *ident_get_host (graph_ident_t *ident);
23 const char *ident_get_plugin (graph_ident_t *ident);
24 const char *ident_get_plugin_instance (graph_ident_t *ident);
25 const char *ident_get_type (graph_ident_t *ident);
26 const char *ident_get_type_instance (graph_ident_t *ident);
28 int ident_set_host (graph_ident_t *ident, const char *host);
29 int ident_set_plugin (graph_ident_t *ident, const char *plugin);
30 int ident_set_plugin_instance (graph_ident_t *ident,
31 const char *plugin_instance);
32 int ident_set_type (graph_ident_t *ident, const char *type);
33 int ident_set_type_instance (graph_ident_t *ident,
34 const char *type_instance);
36 int ident_compare (const graph_ident_t *i0,
37 const graph_ident_t *i1);
39 _Bool ident_matches (const graph_ident_t *selector,
40 const graph_ident_t *ident);
42 char *ident_to_string (const graph_ident_t *ident);
43 char *ident_to_file (const graph_ident_t *ident);
44 char *ident_to_json (const graph_ident_t *ident);
46 /* vim: set sw=2 sts=2 et fdm=marker : */
47 #endif /* GRAPH_IDENT_H */