22 for (iter = list; iter != NULL; iter = iter->
next) {
35 for (iter = list; iter != NULL; iter = iter->
next) {
47 const char *agent_spec = va_arg(args,
const char *);
52 return xml_list(out, list,
"provider");
59 const char *agent_spec G_GNUC_UNUSED = va_arg(args,
const char *);
61 return default_list(out, list,
"Providers");
68 const char *agent_spec = va_arg(args,
const char *);
69 char *provider = va_arg(args,
char *);
72 "standard", agent_spec,
75 if (!pcmk__str_empty(provider)) {
79 return xml_list(out, list,
"agent");
86 const char *agent_spec = va_arg(args,
const char *);
87 char *provider = va_arg(args,
char *);
90 char *title =
crm_strdup_printf(
"%s agents", pcmk__str_empty(provider) ? agent_spec : provider);
92 rc = default_list(out, list, title);
101 const char *agent_spec = va_arg(args,
const char *);
107 if (agent_spec != NULL) {
111 return xml_list(out, list,
"provider");
118 const char *agent_spec G_GNUC_UNUSED = va_arg(args,
const char *);
120 return default_list(out, list,
"Providers");
128 return default_list(out, list,
"Standards");
132 {
"alternatives-list",
"default", lrmd__alternatives_list },
133 {
"alternatives-list",
"xml", lrmd__alternatives_list_xml },
134 {
"agents-list",
"default", lrmd__agents_list },
135 {
"agents-list",
"xml", lrmd__agents_list_xml },
136 {
"providers-list",
"default", lrmd__providers_list },
137 {
"providers-list",
"xml", lrmd__providers_list_xml },
138 {
"standards-list",
"default", lrmd__standards_list },
void lrmd_list_freeall(lrmd_list_t *head)
const char * crm_xml_add(xmlNode *node, const char *name, const char *value)
Create an XML attribute with specified name and value.
void(* end_list)(pcmk__output_t *out)
Formatted output for pacemaker tools.
void(* begin_list)(pcmk__output_t *out, const char *singular_noun, const char *plural_noun, const char *format,...) G_GNUC_PRINTF(4
struct lrmd_list_s * next
#define PCMK__OUTPUT_ARGS(ARGS...)
char * crm_strdup_printf(char const *format,...) G_GNUC_PRINTF(1
void lrmd__register_messages(pcmk__output_t *out)
This structure contains everything that makes up a single output formatter.
void pcmk__register_messages(pcmk__output_t *out, pcmk__message_entry_t *table)
xmlNodePtr pcmk__output_create_xml_text_node(pcmk__output_t *out, const char *name, const char *content)
xmlNodePtr pcmk__output_xml_create_parent(pcmk__output_t *out, const char *name,...)
void(*) void(* list_item)(pcmk__output_t *out, const char *name, const char *format,...) G_GNUC_PRINTF(3