helics  3.6.1
coreTypeOperations.hpp
Go to the documentation of this file.
1 /*
2 Copyright (c) 2017-2025,
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 #include "CoreTypes.hpp"
9 
10 #include <string>
11 #include <string_view>
12 #include <utility>
13 #include <vector>
14 
19 namespace helics::core {
20 
22 std::string to_string(CoreType type);
28 CoreType coreTypeFromString(std::string_view type) noexcept;
29 
33 bool isCoreTypeAvailable(CoreType type) noexcept;
34 
40 bool matchingTypes(std::string_view type1, std::string_view type2);
41 
43 std::string systemInfo();
44 
46 std::pair<CoreType, std::string> extractCoreType(const std::string& configureString);
47 std::pair<CoreType, std::string> extractCoreType(const std::vector<std::string>& args);
48 std::pair<CoreType, std::string> extractCoreType(int argc, char* argv[]);
49 
50 } // namespace helics::core
CoreType
Definition: CoreTypes.hpp:46
bool isCoreTypeAvailable(CoreType type) noexcept
Definition: typeOperations.cpp:25
CoreType coreTypeFromString(std::string_view type) noexcept
Definition: typeOperations.cpp:20
std::string to_string(CoreType type)
Definition: typeOperations.cpp:15
std::string systemInfo()
Definition: typeOperations.cpp:30