helics  3.5.2
ProfilerBuffer.hpp
1 /*
2 Copyright (c) 2017-2024,
3 Battelle Memorial Institute; Lawrence Livermore National Security, LLC; Alliance for Sustainable
4 Energy, LLC. See the top-level NOTICE for additional details. All rights reserved.
5 SPDX-License-Identifier: BSD-3-Clause
6 */
7 #pragma once
8 
9 #include <string>
10 #include <utility>
11 #include <vector>
12 
13 namespace helics {
15  public:
16  ~ProfilerBuffer();
17  void addMessage(const std::string& data);
18  void addMessage(std::string&& data);
19  void writeFile();
26  void setOutputFile(std::string fileName, bool append = false);
27 
28  private:
29  std::vector<std::string> mBuffers;
30  std::string mFileName;
31 };
32 } // namespace helics
Definition: ProfilerBuffer.hpp:14
void setOutputFile(std::string fileName, bool append=false)
Definition: ProfilerBuffer.cpp:57
the main namespace for the helics co-simulation library User functions will be in the helics namespac...
Definition: AsyncFedCallInfo.hpp:14