LLDB mainline
lldb_private::XMLDocument Class Reference

#include <XML.h>

Public Member Functions

 XMLDocument ()
 ~XMLDocument ()
 operator bool () const
bool IsValid () const
void Clear ()
bool ParseFile (const char *path)
bool ParseMemory (const char *xml, size_t xml_length, const char *url="untitled.xml")
XMLNode GetRootElement (const char *required_name=nullptr)
llvm::StringRef GetErrors () const

Static Public Member Functions

static void ErrorCallback (void *ctx, const char *format,...)
static bool XMLEnabled ()

Protected Attributes

XMLDocumentImpl m_document = nullptr
StreamString m_errors

Detailed Description

Definition at line 113 of file XML.h.

Constructor & Destructor Documentation

◆ XMLDocument()

XMLDocument::XMLDocument ( )
default

Referenced by ErrorCallback().

◆ ~XMLDocument()

XMLDocument::~XMLDocument ( )

Definition at line 21 of file XML.cpp.

References Clear().

Member Function Documentation

◆ Clear()

void XMLDocument::Clear ( )

Definition at line 23 of file XML.cpp.

References m_document.

Referenced by ParseFile(), ParseMemory(), and ~XMLDocument().

◆ ErrorCallback()

void XMLDocument::ErrorCallback ( void * ctx,
const char * format,
... )
static

◆ GetErrors()

llvm::StringRef XMLDocument::GetErrors ( ) const

Definition at line 81 of file XML.cpp.

References m_errors.

◆ GetRootElement()

◆ IsValid()

bool XMLDocument::IsValid ( ) const

Definition at line 33 of file XML.cpp.

References m_document.

Referenced by GetRootElement(), operator bool(), ParseFile(), and ParseMemory().

◆ operator bool()

lldb_private::XMLDocument::operator bool ( ) const
inlineexplicit

Definition at line 119 of file XML.h.

References IsValid().

◆ ParseFile()

bool XMLDocument::ParseFile ( const char * path)

Definition at line 44 of file XML.cpp.

References Clear(), ErrorCallback(), IsValid(), and m_document.

◆ ParseMemory()

◆ XMLEnabled()

Member Data Documentation

◆ m_document

XMLDocumentImpl lldb_private::XMLDocument::m_document = nullptr
protected

Definition at line 141 of file XML.h.

Referenced by Clear(), GetRootElement(), IsValid(), ParseFile(), and ParseMemory().

◆ m_errors

StreamString lldb_private::XMLDocument::m_errors
protected

Definition at line 142 of file XML.h.

Referenced by ErrorCallback(), and GetErrors().


The documentation for this class was generated from the following files: