LLVM API Documentation

Classes | Public Member Functions
llvm::yaml::Input Class Reference

#include <YAMLTraits.h>

Inheritance diagram for llvm::yaml::Input:
Inheritance graph
[legend]
Collaboration diagram for llvm::yaml::Input:
Collaboration graph
[legend]

List of all members.

Classes

class  EmptyHNode
class  HNode
class  MapHNode
class  ScalarHNode
class  SequenceHNode

Public Member Functions

 Input (StringRef InputContent, void *Ctxt=nullptr, SourceMgr::DiagHandlerTy DiagHandler=nullptr, void *DiagHandlerCtxt=nullptr)
 ~Input ()
std::error_code error ()
bool setCurrentDocument ()
bool nextDocument ()

Detailed Description

The Input class is used to parse a yaml document into in-memory structs and vectors.

It works by using YAMLParser to do a syntax parse of the entire yaml document, then the Input class builds a graph of HNodes which wraps each yaml Node. The extra layer is buffering. The low level yaml parser only lets you look at each node once. The buffering layer lets you search and interate multiple times. This is necessary because the mapRequired() method calls may not be in the same order as the keys in the document.

Definition at line 871 of file YAMLTraits.h.


Constructor & Destructor Documentation

Input::Input ( StringRef  InputContent,
void *  Ctxt = nullptr,
SourceMgr::DiagHandlerTy  DiagHandler = nullptr,
void *  DiagHandlerCtxt = nullptr 
)

Definition at line 45 of file YAMLTraits.cpp.

References llvm::SourceMgr::setDiagHandler().

Definition at line 57 of file YAMLTraits.cpp.


Member Function Documentation

std::error_code Input::error ( )

Definition at line 60 of file YAMLTraits.cpp.

Referenced by llvm::yaml::operator>>().

Definition at line 94 of file YAMLTraits.cpp.

Referenced by llvm::yaml::operator>>().

Definition at line 73 of file YAMLTraits.cpp.

References llvm::invalid_argument, llvm::make_error_code(), and N.

Referenced by llvm::yaml::operator>>().


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