OPAL (Object Oriented Parallel Accelerator Library) 2024.2
OPAL
Typedefs | Enumerations | Functions | Variables
SDDS::ast Namespace Reference

Typedefs

using variant_t = std::variant< float, double, short, long, char, std::string >
 
using columnData_t = std::vector< variant_t >
 

Enumerations

enum class  dataType {
  FLOAT , DOUBLE , SHORT , LONG ,
  CHARACTER , STRING
}
 
enum class  dataMode { ASCII , BINARY }
 

Functions

constexpr char toLowerAscii (char c)
 
constexpr bool equalsIgnoreCase (std::string_view lhs, std::string_view rhs)
 
constexpr std::optional< dataType > parseDataType (std::string_view typeName)
 
constexpr std::string_view getDataTypeString (dataType type)
 
constexpr std::string_view getDataModeString (dataMode mode)
 

Variables

constexpr std::array< std::pair< std::string_view, dataType >, 6 > dataTypeTable
 

Typedef Documentation

◆ columnData_t

using SDDS::ast::columnData_t = typedef std::vector<variant_t>

Definition at line 51 of file ast.hpp.

◆ variant_t

using SDDS::ast::variant_t = typedef std::variant<float, double, short, long, char, std::string>

Definition at line 44 of file ast.hpp.

Enumeration Type Documentation

◆ dataMode

enum class SDDS::ast::dataMode
strong
Enumerator
ASCII 
BINARY 

Definition at line 39 of file ast.hpp.

◆ dataType

enum class SDDS::ast::dataType
strong
Enumerator
FLOAT 
DOUBLE 
SHORT 
LONG 
CHARACTER 
STRING 

Definition at line 31 of file ast.hpp.

Function Documentation

◆ equalsIgnoreCase()

constexpr bool SDDS::ast::equalsIgnoreCase ( std::string_view  lhs,
std::string_view  rhs 
)
constexpr

Definition at line 66 of file ast.hpp.

References toLowerAscii().

Referenced by SDDS::parser::SimpleParser::parseData(), and parseDataType().

Here is the call graph for this function:

◆ getDataModeString()

constexpr std::string_view SDDS::ast::getDataModeString ( dataMode  mode)
constexpr

Definition at line 97 of file ast.hpp.

Referenced by SDDS::operator<<().

◆ getDataTypeString()

constexpr std::string_view SDDS::ast::getDataTypeString ( dataType  type)
constexpr

Definition at line 87 of file ast.hpp.

References dataTypeTable, and name.

◆ parseDataType()

constexpr std::optional< dataType > SDDS::ast::parseDataType ( std::string_view  typeName)
constexpr

Definition at line 78 of file ast.hpp.

References dataTypeTable, equalsIgnoreCase(), and name.

Referenced by SDDS::parser::SimpleParser::parseColumn(), and SDDS::parser::SimpleParser::parseParameter().

Here is the call graph for this function:

◆ toLowerAscii()

constexpr char SDDS::ast::toLowerAscii ( char  c)
constexpr

Definition at line 62 of file ast.hpp.

Referenced by equalsIgnoreCase().

Variable Documentation

◆ dataTypeTable

constexpr std::array<std::pair<std::string_view, dataType>, 6> SDDS::ast::dataTypeTable
constexpr
Initial value:
= {{
{ "float", dataType::FLOAT },
{ "double", dataType::DOUBLE },
{ "short", dataType::SHORT },
{ "long", dataType::LONG },
{ "character", dataType::CHARACTER },
{ "string", dataType::STRING }
}}

Definition at line 53 of file ast.hpp.

Referenced by getDataTypeString(), and parseDataType().