op_xml_out.c File Reference

#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include "op_xml_out.h"
Include dependency graph for op_xml_out.c:

Go to the source code of this file.

Defines

#define MAX_BUF_LEN   2048

Functions

char const * xml_tag_name (tag_t tag)
void open_xml_element (tag_t tag, int with_attrs, char *buffer, size_t max)
void close_xml_element (tag_t tag, int has_nested, char *buffer, size_t max)
void init_xml_int_attr (tag_t attr, int value, char *buffer, size_t max)
void init_xml_dbl_attr (tag_t attr, double value, char *buffer, size_t max)
static void xml_quote (char const *str, char *buffer, size_t max)
void init_xml_str_attr (tag_t attr, char const *str, char *buffer, size_t max)

Variables

char const * xml_tag_map []

Detailed Description

C utility routines for writing XML

Remarks:
Copyright 2008 OProfile authors
Read the file COPYING
Author:
Dave Nomura

Definition in file op_xml_out.c.


Define Documentation

#define MAX_BUF_LEN   2048

Definition at line 90 of file op_xml_out.c.


Function Documentation

void close_xml_element ( tag_t  tag,
int  has_nested,
char *  buffer,
size_t  max 
)

Definition at line 117 of file op_xml_out.c.

References buf, NONE, and xml_tag_name().

Referenced by close_element(), close_xml_events(), open_xml_events(), and xml_help_for_event().

Here is the call graph for this function:

Here is the caller graph for this function:

void init_xml_dbl_attr ( tag_t  attr,
double  value,
char *  buffer,
size_t  max 
)

Definition at line 158 of file op_xml_out.c.

References buf, and xml_tag_name().

Referenced by init_attr().

Here is the call graph for this function:

Here is the caller graph for this function:

void init_xml_int_attr ( tag_t  attr,
int  value,
char *  buffer,
size_t  max 
)

Definition at line 139 of file op_xml_out.c.

References buf, and xml_tag_name().

Referenced by init_attr(), xml_do_arch_specific_event_help(), and xml_help_for_event().

Here is the call graph for this function:

Here is the caller graph for this function:

void init_xml_str_attr ( tag_t  attr,
char const *  str,
char *  buffer,
size_t  max 
)

Definition at line 244 of file op_xml_out.c.

References buf, xml_quote(), and xml_tag_name().

Referenced by init_attr(), open_xml_events(), and xml_help_for_event().

Here is the call graph for this function:

Here is the caller graph for this function:

void open_xml_element ( tag_t  tag,
int  with_attrs,
char *  buffer,
size_t  max 
)

Definition at line 97 of file op_xml_out.c.

References buf, and xml_tag_name().

Referenced by open_element(), open_xml_events(), and xml_help_for_event().

Here is the call graph for this function:

Here is the caller graph for this function:

static void xml_quote ( char const *  str,
char *  buffer,
size_t  max 
) [static]

Definition at line 177 of file op_xml_out.c.

References buf.

Referenced by init_xml_str_attr().

Here is the caller graph for this function:

char const* xml_tag_name ( tag_t  tag  ) 

Definition at line 91 of file op_xml_out.c.

References xml_tag_map.

Referenced by close_xml_element(), init_xml_dbl_attr(), init_xml_int_attr(), init_xml_str_attr(), open_xml_element(), and tag_name().

Here is the caller graph for this function:


Variable Documentation

char const* xml_tag_map[]

Definition at line 16 of file op_xml_out.c.

Referenced by xml_tag_name().


Generated on 8 Nov 2012 for Oprofile by  doxygen 1.6.1