blob: 3690e3529d4a1ebcf476f38b9e3c8d36458d6956 [file] [log] [blame]
Zachary Turner7120a472016-06-06 20:37:05 +00001//===- YAMLOutputStyle.h -------------------------------------- *- C++ --*-===//
2//
3// The LLVM Compiler Infrastructure
4//
5// This file is distributed under the University of Illinois Open Source
6// License. See LICENSE.TXT for details.
7//
8//===----------------------------------------------------------------------===//
9
10#ifndef LLVM_TOOLS_LLVMPDBDUMP_YAMLOUTPUTSTYLE_H
11#define LLVM_TOOLS_LLVMPDBDUMP_YAMLOUTPUTSTYLE_H
12
13#include "OutputStyle.h"
14#include "PdbYaml.h"
15
Zachary Turner7120a472016-06-06 20:37:05 +000016#include "llvm/Support/ScopedPrinter.h"
17#include "llvm/Support/YAMLTraits.h"
18
19namespace llvm {
20namespace pdb {
Zachary Turner7cc13e52017-05-01 16:46:39 +000021class ModuleDebugStreamRef;
Zachary Turneree3b9c22017-04-25 20:22:02 +000022
Zachary Turner7120a472016-06-06 20:37:05 +000023class YAMLOutputStyle : public OutputStyle {
24public:
25 YAMLOutputStyle(PDBFile &File);
26
Zachary Turnera30bd1a2016-06-30 17:42:48 +000027 Error dump() override;
Zachary Turner7120a472016-06-06 20:37:05 +000028
29private:
Zachary Turner760ad4d2017-01-20 22:42:09 +000030 Error dumpStringTable();
Zachary Turnera30bd1a2016-06-30 17:42:48 +000031 Error dumpFileHeaders();
32 Error dumpStreamMetadata();
33 Error dumpStreamDirectory();
Zachary Turner8848a7a2016-07-06 18:05:57 +000034 Error dumpPDBStream();
Zachary Turnerdbeaea72016-07-11 21:45:26 +000035 Error dumpDbiStream();
Zachary Turnerac5763e2016-08-18 16:49:29 +000036 Error dumpTpiStream();
Zachary Turnerde9ba152016-09-15 18:22:31 +000037 Error dumpIpiStream();
Zachary Turnera30bd1a2016-06-30 17:42:48 +000038
39 void flush();
40
Zachary Turner7120a472016-06-06 20:37:05 +000041 PDBFile &File;
42 llvm::yaml::Output Out;
43
44 yaml::PdbObject Obj;
45};
46} // namespace pdb
47} // namespace llvm
48
49#endif // LLVM_TOOLS_LLVMPDBDUMP_YAMLOUTPUTSTYLE_H