class Input
Declaration
class Input : public IO { /* full declaration omitted */ };
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.
Declared at: llvm/include/llvm/Support/YAMLTraits.h:1387
Inherits from: IO
Method Overview
- public Input(llvm::StringRef InputContent, void * Ctxt = nullptr, SourceMgr::DiagHandlerTy DiagHandler = nullptr, void * DiagHandlerCtxt = nullptr)
- public Input(llvm::MemoryBufferRef Input, void * Ctxt = nullptr, SourceMgr::DiagHandlerTy DiagHandler = nullptr, void * DiagHandlerCtxt = nullptr)
- public std::error_code error()
- public const llvm::yaml::Node * getCurrentNode() const
- public bool nextDocument()
- public bool setCurrentDocument()
- public ~Input()
Inherited from IO:
- public beginBitSetScalar
- public beginEnumScalar
- public beginFlowMapping
- public beginFlowSequence
- public beginMapping
- public beginSequence
- public bitSetCase
- public bitSetCase
- public bitSetMatch
- public blockScalarString
- public canElideEmptySequence
- public endBitSetScalar
- public endEnumScalar
- public endFlowMapping
- public endFlowSequence
- public endMapping
- public endSequence
- public enumCase
- public enumCase
- public enumFallback
- public getContext
- public getNodeKind
- public keys
- public mapOptional
- public mapOptional
- public mapOptionalWithContext
- public mapOptionalWithContext
- public mapOptionalWithContext
- public mapOptionalWithContext
- public mapRequired
- public mapRequired
- public mapTag
- public maskedBitSetCase
- public maskedBitSetCase
- public matchEnumFallback
- public matchEnumScalar
- public outputting
- public postflightElement
- public postflightFlowElement
- public postflightKey
- public preflightElement
- public preflightFlowElement
- public preflightKey
- public scalarString
- public scalarTag
- public setContext
- public setError
Methods
¶Input(llvm::StringRef InputContent,
void* Ctxt = nullptr,
SourceMgr::DiagHandlerTy DiagHandler =
nullptr,
void* DiagHandlerCtxt = nullptr)
Input(llvm::StringRef InputContent,
void* Ctxt = nullptr,
SourceMgr::DiagHandlerTy DiagHandler =
nullptr,
void* DiagHandlerCtxt = nullptr)
Declared at: llvm/include/llvm/Support/YAMLTraits.h:1392
Parameters
- llvm::StringRef InputContent
- void* Ctxt = nullptr
- SourceMgr::DiagHandlerTy DiagHandler = nullptr
- void* DiagHandlerCtxt = nullptr
¶Input(llvm::MemoryBufferRef Input,
void* Ctxt = nullptr,
SourceMgr::DiagHandlerTy DiagHandler =
nullptr,
void* DiagHandlerCtxt = nullptr)
Input(llvm::MemoryBufferRef Input,
void* Ctxt = nullptr,
SourceMgr::DiagHandlerTy DiagHandler =
nullptr,
void* DiagHandlerCtxt = nullptr)
Declared at: llvm/include/llvm/Support/YAMLTraits.h:1396
Parameters
- llvm::MemoryBufferRef Input
- void* Ctxt = nullptr
- SourceMgr::DiagHandlerTy DiagHandler = nullptr
- void* DiagHandlerCtxt = nullptr
¶std::error_code error()
std::error_code error()
Declared at: llvm/include/llvm/Support/YAMLTraits.h:1403
¶const llvm::yaml::Node* getCurrentNode() const
const llvm::yaml::Node* getCurrentNode() const
Description
Returns the current node that's being parsed by the YAML Parser.
Declared at: llvm/include/llvm/Support/YAMLTraits.h:1523
¶bool nextDocument()
bool nextDocument()
Declared at: llvm/include/llvm/Support/YAMLTraits.h:1520
¶bool setCurrentDocument()
bool setCurrentDocument()
Declared at: llvm/include/llvm/Support/YAMLTraits.h:1519
¶~Input()
~Input()
Declared at: llvm/include/llvm/Support/YAMLTraits.h:1400