This source file includes following definitions.
- pcmk__xe_history_key
1
2
3
4
5
6
7
8
9
10 #ifndef PCMK__CRM_COMMON_HISTORY_INTERNAL__H
11 #define PCMK__CRM_COMMON_HISTORY_INTERNAL__H
12
13 #include <stdio.h>
14 #include <libxml/tree.h>
15
16 #include <crm/common/xml.h>
17 #include <crm/common/internal.h>
18 #include <crm/common/xml_names_internal.h>
19
20 #ifdef __cplusplus
21 extern "C" {
22 #endif
23
24
25
26
27
28
29
30
31
32 static inline const char *
33 pcmk__xe_history_key(const xmlNode *xml)
34 {
35 if (xml == NULL) {
36 return NULL;
37 } else {
38
39
40
41
42 const char *key = crm_element_value(xml, PCMK__XA_OPERATION_KEY);
43
44 return pcmk__str_empty(key)? pcmk__xe_id(xml) : key;
45 }
46 }
47
48 #ifdef __cplusplus
49 }
50 #endif
51
52 #endif