pacemaker  2.1.9-49aab99839
Scalable High-Availability cluster resource manager
Data Structures | Macros | Typedefs | Functions
nvpair_internal.h File Reference
#include <glib.h>
#include <libxml/tree.h>
#include <crm/common/rules.h>
#include <crm/common/iso8601.h>
#include <crm/common/strings_internal.h>
Include dependency graph for nvpair_internal.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  unpack_data_s
 

Macros

#define pcmk__insert_meta(obj, name, value)
 

Typedefs

typedef struct unpack_data_s pcmk__nvpair_unpack_t
 

Functions

int pcmk__xe_get_datetime (const xmlNode *xml, const char *attr, crm_time_t **t)
 
int pcmk__xe_get_flags (const xmlNode *xml, const char *name, uint32_t *dest, uint32_t default_value)
 Retrieve a flag group from an XML attribute value. More...
 

Macro Definition Documentation

◆ pcmk__insert_meta

#define pcmk__insert_meta (   obj,
  name,
  value 
)
Value:
do { \
if (pcmk__str_eq((value), "#default", pcmk__str_casei)) { \
/* @COMPAT Deprecated since 2.1.8 */ \
pcmk__config_warn("Support for setting meta-attributes " \
"(such as %s) to the explicit value " \
"'#default' is deprecated and will be " \
"removed in a future release", (name)); \
} else if ((value) != NULL) { \
pcmk__insert_dup((obj)->meta, (name), (value)); \
} \
} while (0)
const char * name
Definition: cib.c:26

Definition at line 45 of file nvpair_internal.h.

Typedef Documentation

◆ pcmk__nvpair_unpack_t

Function Documentation

◆ pcmk__xe_get_datetime()

int pcmk__xe_get_datetime ( const xmlNode *  xml,
const char *  attr,
crm_time_t **  t 
)

Definition at line 728 of file nvpair.c.

◆ pcmk__xe_get_flags()

int pcmk__xe_get_flags ( const xmlNode *  xml,
const char *  name,
uint32_t *  dest,
uint32_t  default_value 
)

Retrieve a flag group from an XML attribute value.

This is like crm_element_value() except getting the value as a 32-bit unsigned integer.

Parameters
[in]xmlXML node to check
[in]nameAttribute name to check (must not be NULL)
[out]destWhere to store flags (may be NULL to just validate type)
[in]default_valueWhat to use for missing or invalid value
Returns
Standard Pacemaker return code

Definition at line 535 of file nvpair.c.