class RedirectingFileSystemParser

Declaration

class RedirectingFileSystemParser { /* full declaration omitted */ };

Description

A helper class to hold the common YAML parsing state.

Declared at: llvm/lib/Support/VirtualFileSystem.cpp:1567

Member Variables

private yaml::Stream& Stream

Method Overview

  • public RedirectingFileSystemParser(yaml::Stream & S)
  • private bool checkDuplicateOrUnknownKey(yaml::Node * KeyNode, llvm::StringRef Key, DenseMap<llvm::StringRef, llvm::vfs::RedirectingFileSystemParser::KeyStatus> & Keys)
  • private bool checkMissingKeys(yaml::Node * Obj, DenseMap<llvm::StringRef, llvm::vfs::RedirectingFileSystemParser::KeyStatus> & Keys)
  • private void error(yaml::Node * N, const llvm::Twine & Msg)
  • public static RedirectingFileSystem::Entry * lookupOrCreateEntry(llvm::vfs::RedirectingFileSystem * FS, llvm::StringRef Name, RedirectingFileSystem::Entry * ParentEntry = nullptr)
  • public bool parse(yaml::Node * Root, llvm::vfs::RedirectingFileSystem * FS)
  • private std::unique_ptr<RedirectingFileSystem::Entry> parseEntry(yaml::Node * N, llvm::vfs::RedirectingFileSystem * FS, bool IsRootEntry)
  • private Optional<RedirectingFileSystem::RedirectKind> parseRedirectKind(yaml::Node * N)
  • private bool parseScalarBool(yaml::Node * N, bool & Result)
  • private bool parseScalarString(yaml::Node * N, llvm::StringRef & Result, SmallVectorImpl<char> & Storage)
  • private void uniqueOverlayTree(llvm::vfs::RedirectingFileSystem * FS, RedirectingFileSystem::Entry * SrcE, RedirectingFileSystem::Entry * NewParentE = nullptr)

Methods

RedirectingFileSystemParser(yaml::Stream& S)

Declared at: llvm/lib/Support/VirtualFileSystem.cpp:1951

Parameters

yaml::Stream& S

bool checkDuplicateOrUnknownKey(
    yaml::Node* KeyNode,
    llvm::StringRef Key,
    DenseMap<
        llvm::StringRef,
        llvm::vfs::RedirectingFileSystemParser::
            KeyStatus>& Keys)

Declared at: llvm/lib/Support/VirtualFileSystem.cpp:1634

Parameters

yaml::Node* KeyNode
llvm::StringRef Key
DenseMap<llvm::StringRef, llvm::vfs::RedirectingFileSystemParser:: KeyStatus>& Keys

bool checkMissingKeys(
    yaml::Node* Obj,
    DenseMap<
        llvm::StringRef,
        llvm::vfs::RedirectingFileSystemParser::
            KeyStatus>& Keys)

Declared at: llvm/lib/Support/VirtualFileSystem.cpp:1650

Parameters

yaml::Node* Obj
DenseMap<llvm::StringRef, llvm::vfs::RedirectingFileSystemParser:: KeyStatus>& Keys

void error(yaml::Node* N, const llvm::Twine& Msg)

Declared at: llvm/lib/Support/VirtualFileSystem.cpp:1570

Parameters

yaml::Node* N
const llvm::Twine& Msg

static RedirectingFileSystem::Entry*
lookupOrCreateEntry(
    llvm::vfs::RedirectingFileSystem* FS,
    llvm::StringRef Name,
    RedirectingFileSystem::Entry* ParentEntry =
        nullptr)

Declared at: llvm/lib/Support/VirtualFileSystem.cpp:1662

Parameters

llvm::vfs::RedirectingFileSystem* FS
llvm::StringRef Name
RedirectingFileSystem::Entry* ParentEntry = nullptr

bool parse(yaml::Node* Root,
           llvm::vfs::RedirectingFileSystem* FS)

Declared at: llvm/lib/Support/VirtualFileSystem.cpp:1954

Parameters

yaml::Node* Root
llvm::vfs::RedirectingFileSystem* FS

std::unique_ptr<RedirectingFileSystem::Entry>
parseEntry(yaml::Node* N,
           llvm::vfs::RedirectingFileSystem* FS,
           bool IsRootEntry)

Declared at: llvm/lib/Support/VirtualFileSystem.cpp:1739

Parameters

yaml::Node* N
llvm::vfs::RedirectingFileSystem* FS
bool IsRootEntry

Optional<RedirectingFileSystem::RedirectKind>
parseRedirectKind(yaml::Node* N)

Declared at: llvm/lib/Support/VirtualFileSystem.cpp:1608

Parameters

yaml::Node* N

bool parseScalarBool(yaml::Node* N, bool& Result)

Declared at: llvm/lib/Support/VirtualFileSystem.cpp:1586

Parameters

yaml::Node* N
bool& Result

bool parseScalarString(
    yaml::Node* N,
    llvm::StringRef& Result,
    SmallVectorImpl<char>& Storage)

Declared at: llvm/lib/Support/VirtualFileSystem.cpp:1573

Parameters

yaml::Node* N
llvm::StringRef& Result
SmallVectorImpl<char>& Storage

void uniqueOverlayTree(
    llvm::vfs::RedirectingFileSystem* FS,
    RedirectingFileSystem::Entry* SrcE,
    RedirectingFileSystem::Entry* NewParentE =
        nullptr)

Declared at: llvm/lib/Support/VirtualFileSystem.cpp:1701

Parameters

llvm::vfs::RedirectingFileSystem* FS
RedirectingFileSystem::Entry* SrcE
RedirectingFileSystem::Entry* NewParentE = nullptr