clang 20.0.0git
FileList.h
Go to the documentation of this file.
1//===- InstallAPI/FileList.h ------------------------------------*- 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/// The JSON file list parser is used to communicate input to InstallAPI.
10///
11//===----------------------------------------------------------------------===//
12
13#ifndef LLVM_CLANG_INSTALLAPI_FILELIST_H
14#define LLVM_CLANG_INSTALLAPI_FILELIST_H
15
19#include "llvm/Support/Error.h"
20#include "llvm/Support/MemoryBuffer.h"
21
22namespace clang {
23namespace installapi {
24
26public:
27 /// Decode JSON input and append header input into destination container.
28 /// Headers are loaded in the order they appear in the JSON input.
29 ///
30 /// \param InputBuffer JSON input data.
31 /// \param Destination Container to load headers into.
32 /// \param FM Optional File Manager to validate input files exist.
33 static llvm::Error
34 loadHeaders(std::unique_ptr<llvm::MemoryBuffer> InputBuffer,
35 HeaderSeq &Destination, clang::FileManager *FM = nullptr);
36
37 FileListReader() = delete;
38};
39
40} // namespace installapi
41} // namespace clang
42
43#endif // LLVM_CLANG_INSTALLAPI_FILELIST_H
Defines the Diagnostic-related interfaces.
Defines the clang::FileManager interface and associated types.
Implements support for file system lookup, file system caching, and directory search management.
Definition: FileManager.h:53
static llvm::Error loadHeaders(std::unique_ptr< llvm::MemoryBuffer > InputBuffer, HeaderSeq &Destination, clang::FileManager *FM=nullptr)
Decode JSON input and append header input into destination container.
Definition: FileList.cpp:179
std::vector< HeaderFile > HeaderSeq
Definition: HeaderFile.h:150
The JSON file list parser is used to communicate input to InstallAPI.