| helics 3.6.1

Namespaces | Functions
coreTypeOperations.hpp File Reference
`#include "CoreTypes.hpp"`
`#include <string>`
`#include <string_view>`
`#include <utility>`
`#include <vector>`

Go to the source code of this file.

## Namespaces
| helics
| the main namespace for the helics co-simulation library User functions will be in the helics namespace with internal functions possible in a lower level namespace

## Functions
std::string | helics::core::to_string (CoreType type)
CoreType | helics::core::coreTypeFromString (std::string_view type) noexcept
bool | helics::core::isCoreTypeAvailable (CoreType type) noexcept
bool | helics::core::matchingTypes (std::string_view type1, std::string_view type2)
std::string | helics::core::systemInfo ()
std::pair< CoreType, std::string > | helics::core::extractCoreType (const std::string &configureString)
std::pair< CoreType, std::string > | helics::core::extractCoreType (const std::vector< std::string > &args)
std::pair< CoreType, std::string > | helics::core::extractCoreType (int argc, char *argv[])

## Detailed Description

function definitions for operations on core types

## Function Documentation

## ◆ coreTypeFromString()

CoreType helics::core::coreTypeFromString | ( | std::string_view | type | ) |
| noexcept

generate a core type value from a std::string

Parameters

  type | a string describing the desired core type

Returns
  a value of the helics::CoreType enumeration helics::CoreType::UNRECOGNIZED if the type is not valid

## ◆ extractCoreType()

std::pair< CoreType, std::string > helics::core::extractCoreType | ( | const std::string & | configureString | ) |

methods to extract the core type and name from various forms of arguments

## ◆ isCoreTypeAvailable()

bool helics::core::isCoreTypeAvailable | ( | CoreType | type | ) |
| noexcept

Returns true if core/broker type specified is available in current compilation.

## ◆ matchingTypes()

bool helics::core::matchingTypes | ( | std::string_view | type1,
|  | std::string_view | type2
| ) |  |

check if two data types are compatible with each other

Parameters

  type1 | the first type to match
  type2 | the second type to check

Returns
  true if the types are compatible with each other

## ◆ systemInfo()

std::string helics::core::systemInfo | ( |  | ) |

generate an extended version and system info string in json format

References helics::buildFlags, helics::compiler, helics::CoreFactory::getAvailableCoreTypes(), helics::versionBuild, helics::versionMajor, helics::versionMinor, helics::versionPatch, and helics::versionString.

## ◆ to_string()

std::string helics::core::to_string | ( | CoreType | type | ) |

generate a string based on the core type