• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 //===- NativeSourceFile.h - Native source file implementation ---*- C++ -*-===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 
9 #ifndef LLVM_DEBUGINFO_PDB_NATIVE_NATIVESOURCEFILE_H
10 #define LLVM_DEBUGINFO_PDB_NATIVE_NATIVESOURCEFILE_H
11 
12 #include "llvm/DebugInfo/CodeView/DebugChecksumsSubsection.h"
13 #include "llvm/DebugInfo/PDB/IPDBSourceFile.h"
14 #include "llvm/DebugInfo/PDB/Native/PDBFile.h"
15 #include "llvm/DebugInfo/PDB/Native/PDBStringTable.h"
16 
17 namespace llvm {
18 namespace pdb {
19 class NativeSession;
20 
21 class NativeSourceFile : public IPDBSourceFile {
22 public:
23   explicit NativeSourceFile(NativeSession &Session, uint32_t FileId,
24                             const codeview::FileChecksumEntry &Checksum);
25 
26   std::string getFileName() const override;
27   uint32_t getUniqueId() const override;
28   std::string getChecksum() const override;
29   PDB_Checksum getChecksumType() const override;
30   std::unique_ptr<IPDBEnumChildren<PDBSymbolCompiland>>
31   getCompilands() const override;
32 
33 private:
34   NativeSession &Session;
35   uint32_t FileId;
36   const codeview::FileChecksumEntry Checksum;
37 };
38 } // namespace pdb
39 } // namespace llvm
40 #endif
41