ACloudViewer  3.9.4
A Modern Library for 3D Data Processing
CompilerInfo.h
Go to the documentation of this file.
1 // ----------------------------------------------------------------------------
2 // - CloudViewer: www.cloudViewer.org -
3 // ----------------------------------------------------------------------------
4 // Copyright (c) 2018-2024 www.cloudViewer.org
5 // SPDX-License-Identifier: MIT
6 // ----------------------------------------------------------------------------
7 #pragma once
8 
9 #include <memory>
10 #include <string>
11 
12 namespace cloudViewer {
13 namespace utility {
14 
16 class CompilerInfo {
17  // This does not need to be a class. It is a class just for the sake of
18  // consistency with CPUInfo.
19 public:
20  static CompilerInfo& GetInstance();
21 
22  ~CompilerInfo() = default;
23  CompilerInfo(const CompilerInfo&) = delete;
24  void operator=(const CompilerInfo&) = delete;
25 
26  std::string CXXStandard() const;
27 
28  std::string CXXCompilerId() const;
29  std::string CXXCompilerVersion() const;
30 
31  std::string CUDACompilerId() const;
32  std::string CUDACompilerVersion() const;
33 
34  void Print() const;
35 
36 private:
37  CompilerInfo();
38 };
39 
40 } // namespace utility
41 } // namespace cloudViewer
static CompilerInfo & GetInstance()
std::string CXXCompilerVersion() const
std::string CUDACompilerVersion() const
std::string CUDACompilerId() const
void operator=(const CompilerInfo &)=delete
CompilerInfo(const CompilerInfo &)=delete
Generic file read and write utility for python interface.