|
LLVM
5.0.0
|
The Output class is used to generate a yaml document from in-memory structs and vectors. More...
#include "llvm/Support/YAMLTraits.h"
Public Member Functions | |
| Output (raw_ostream &, void *Ctxt=nullptr, int WrapColumn=70) | |
| ~Output () override | |
| void | setWriteDefaultValues (bool Write) |
| Set whether or not to output optional values which are equal to the default value. More... | |
| bool | outputting () override |
| bool | mapTag (StringRef, bool) override |
| void | beginMapping () override |
| void | endMapping () override |
| bool | preflightKey (const char *key, bool, bool, bool &, void *&) override |
| void | postflightKey (void *) override |
| std::vector< StringRef > | keys () override |
| void | beginFlowMapping () override |
| void | endFlowMapping () override |
| unsigned | beginSequence () override |
| void | endSequence () override |
| bool | preflightElement (unsigned, void *&) override |
| void | postflightElement (void *) override |
| unsigned | beginFlowSequence () override |
| bool | preflightFlowElement (unsigned, void *&) override |
| void | postflightFlowElement (void *) override |
| void | endFlowSequence () override |
| void | beginEnumScalar () override |
| bool | matchEnumScalar (const char *, bool) override |
| bool | matchEnumFallback () override |
| void | endEnumScalar () override |
| bool | beginBitSetScalar (bool &) override |
| bool | bitSetMatch (const char *, bool) override |
| void | endBitSetScalar () override |
| void | scalarString (StringRef &, bool) override |
| void | blockScalarString (StringRef &) override |
| void | setError (const Twine &message) override |
| bool | canElideEmptySequence () override |
| void | beginDocuments () |
| bool | preflightDocument (unsigned) |
| void | postflightDocument () |
| void | endDocuments () |
Public Member Functions inherited from llvm::yaml::IO | |
| IO (void *Ctxt=nullptr) | |
| virtual | ~IO () |
| template<typename T > | |
| void | enumCase (T &Val, const char *Str, const T ConstVal) |
| template<typename T > | |
| void | enumCase (T &Val, const char *Str, const uint32_t ConstVal) |
| template<typename FBT , typename T > | |
| void | enumFallback (T &Val) |
| template<typename T > | |
| void | bitSetCase (T &Val, const char *Str, const T ConstVal) |
| template<typename T > | |
| void | bitSetCase (T &Val, const char *Str, const uint32_t ConstVal) |
| template<typename T > | |
| void | maskedBitSetCase (T &Val, const char *Str, T ConstVal, T Mask) |
| template<typename T > | |
| void | maskedBitSetCase (T &Val, const char *Str, uint32_t ConstVal, uint32_t Mask) |
| void * | getContext () |
| void | setContext (void *) |
| template<typename T > | |
| void | mapRequired (const char *Key, T &Val) |
| template<typename T , typename Context > | |
| void | mapRequired (const char *Key, T &Val, Context &Ctx) |
| template<typename T > | |
| void | mapOptional (const char *Key, T &Val) |
| template<typename T > | |
| void | mapOptional (const char *Key, T &Val, const T &Default) |
| template<typename T , typename Context > | |
| std::enable_if < has_SequenceTraits< T > ::value, void >::type | mapOptionalWithContext (const char *Key, T &Val, Context &Ctx) |
| template<typename T , typename Context > | |
| void | mapOptionalWithContext (const char *Key, Optional< T > &Val, Context &Ctx) |
| template<typename T , typename Context > | |
| std::enable_if <!has_SequenceTraits< T > ::value, void >::type | mapOptionalWithContext (const char *Key, T &Val, Context &Ctx) |
| template<typename T , typename Context > | |
| void | mapOptionalWithContext (const char *Key, T &Val, const T &Default, Context &Ctx) |
The Output class is used to generate a yaml document from in-memory structs and vectors.
Definition at line 1260 of file YAMLTraits.h.
| Output::Output | ( | raw_ostream & | yout, |
| void * | Ctxt = nullptr, |
||
| int | WrapColumn = 70 |
||
| ) |
Definition at line 414 of file YAMLTraits.cpp.
|
overridedefault |
Implements llvm::yaml::IO.
Definition at line 593 of file YAMLTraits.cpp.
| void Output::beginDocuments | ( | ) |
Definition at line 503 of file YAMLTraits.cpp.
Referenced by llvm::yaml::operator<<().
|
overridevirtual |
Implements llvm::yaml::IO.
Definition at line 568 of file YAMLTraits.cpp.
|
overridevirtual |
Implements llvm::yaml::IO.
Definition at line 491 of file YAMLTraits.cpp.
References llvm::SmallVectorTemplateBase< T, isPodLike >::push_back().
|
overridevirtual |
Implements llvm::yaml::IO.
Definition at line 537 of file YAMLTraits.cpp.
References llvm::SmallVectorTemplateBase< T, isPodLike >::push_back().
|
overridevirtual |
Implements llvm::yaml::IO.
Definition at line 423 of file YAMLTraits.cpp.
References llvm::SmallVectorTemplateBase< T, isPodLike >::push_back().
|
overridevirtual |
Implements llvm::yaml::IO.
Definition at line 520 of file YAMLTraits.cpp.
References llvm::SmallVectorTemplateBase< T, isPodLike >::push_back().
Implements llvm::yaml::IO.
Definition at line 601 of file YAMLTraits.cpp.
|
overridevirtual |
Implements llvm::yaml::IO.
Definition at line 646 of file YAMLTraits.cpp.
References llvm::SmallVectorBase::empty(), llvm::MemoryBuffer::getMemBuffer(), I, and llvm::SmallVectorTemplateCommon< T, typename >::size().
|
overridevirtual |
Implements llvm::yaml::IO.
Definition at line 667 of file YAMLTraits.cpp.
References llvm::SmallVectorTemplateCommon< T, typename >::back(), and llvm::SmallVectorTemplateCommon< T, typename >::size().
|
overridevirtual |
Implements llvm::yaml::IO.
Definition at line 611 of file YAMLTraits.cpp.
| void Output::endDocuments | ( | ) |
Definition at line 516 of file YAMLTraits.cpp.
Referenced by llvm::yaml::operator<<().
|
overridevirtual |
Implements llvm::yaml::IO.
Definition at line 588 of file YAMLTraits.cpp.
References llvm_unreachable().
|
overridevirtual |
Implements llvm::yaml::IO.
Definition at line 498 of file YAMLTraits.cpp.
References llvm::SmallVectorTemplateBase< T, isPodLike >::pop_back().
|
overridevirtual |
Implements llvm::yaml::IO.
Definition at line 546 of file YAMLTraits.cpp.
References llvm::SmallVectorTemplateBase< T, isPodLike >::pop_back().
|
overridevirtual |
Implements llvm::yaml::IO.
Definition at line 457 of file YAMLTraits.cpp.
References llvm::SmallVectorTemplateBase< T, isPodLike >::pop_back().
|
overridevirtual |
Implements llvm::yaml::IO.
Definition at line 526 of file YAMLTraits.cpp.
References llvm::SmallVectorTemplateBase< T, isPodLike >::pop_back().
|
overridevirtual |
Implements llvm::yaml::IO.
Definition at line 461 of file YAMLTraits.cpp.
References llvm::report_fatal_error().
Implements llvm::yaml::IO.
Definition at line 428 of file YAMLTraits.cpp.
References llvm::SmallVectorTemplateCommon< T, typename >::back(), llvm::SmallVectorTemplateBase< T, isPodLike >::pop_back(), llvm::SmallVectorTemplateBase< T, isPodLike >::push_back(), and llvm::SmallVectorTemplateCommon< T, typename >::size().
|
overridevirtual |
Implements llvm::yaml::IO.
Definition at line 581 of file YAMLTraits.cpp.
Implements llvm::yaml::IO.
Definition at line 572 of file YAMLTraits.cpp.
|
overridevirtual |
Implements llvm::yaml::IO.
Definition at line 419 of file YAMLTraits.cpp.
| void Output::postflightDocument | ( | ) |
Definition at line 513 of file YAMLTraits.cpp.
Referenced by llvm::yaml::operator<<().
|
overridevirtual |
Implements llvm::yaml::IO.
Definition at line 534 of file YAMLTraits.cpp.
|
overridevirtual |
Implements llvm::yaml::IO.
Definition at line 564 of file YAMLTraits.cpp.
|
overridevirtual |
Implements llvm::yaml::IO.
Definition at line 481 of file YAMLTraits.cpp.
References llvm::SmallVectorTemplateCommon< T, typename >::back(), llvm::SmallVectorTemplateBase< T, isPodLike >::pop_back(), and llvm::SmallVectorTemplateBase< T, isPodLike >::push_back().
Definition at line 507 of file YAMLTraits.cpp.
Referenced by llvm::yaml::operator<<().
Implements llvm::yaml::IO.
Definition at line 530 of file YAMLTraits.cpp.
Implements llvm::yaml::IO.
Definition at line 551 of file YAMLTraits.cpp.
|
overridevirtual |
Implements llvm::yaml::IO.
Definition at line 465 of file YAMLTraits.cpp.
References llvm::SmallVectorTemplateCommon< T, typename >::back().
Implements llvm::yaml::IO.
Definition at line 615 of file YAMLTraits.cpp.
References llvm::StringRef::data(), llvm::StringRef::empty(), llvm::WebAssembly::End, and llvm::StringRef::size().
Implements llvm::yaml::IO.
Definition at line 664 of file YAMLTraits.cpp.
|
inline |
Set whether or not to output optional values which are equal to the default value.
By default, when outputting if you attempt to write a value that is equal to the default, the value gets ignored. Sometimes, it is useful to be able to see these in the resulting YAML anyway.
Definition at line 1270 of file YAMLTraits.h.
Referenced by llvm::MIRPrinter::print().
1.8.6