CNum 0.2.1
CPU-optimized ML library for C++
Loading...
Searching...
No Matches
CNum::Deploy::PathString Struct Reference

The path of a route in the REST API. More...

#include <Deploy.h>

Public Member Functions

constexpr PathString (const char(&s)[MAX_URL_LEN])
constexpr operator crow::black_magic::const_str () const
constexpr operator::std::string () const

Public Attributes

char str [MAX_URL_LEN]

Detailed Description

The path of a route in the REST API.

This struct is necessary because of Crow C++ requirements for strings when adding a route. Typically a string literal is enough, but I wanted to create an abstraction for adding routes to the API so a struct that can be cast to a constexpr std::string and constexpr crow::black_magic::const_str is needed

Constructor & Destructor Documentation

◆ PathString()

CNum::Deploy::PathString::PathString ( const char(&) s[MAX_URL_LEN])
inlineconstexpr

Member Function Documentation

◆ operator crow::black_magic::const_str()

CNum::Deploy::PathString::operator crow::black_magic::const_str ( ) const
inlineconstexpr

◆ operator::std::string()

CNum::Deploy::PathString::operator::std::string ( ) const
inlineconstexpr

Member Data Documentation

◆ str

char CNum::Deploy::PathString::str[MAX_URL_LEN]

The documentation for this struct was generated from the following file: