#include <template_engine.hpp>
|
| template<class T > |
| static std::string | render (const std::string &format, const T &data) |
| |
| template<typename T > |
| static std::string | render (const std::string &format, const object_ptr< T > &data) |
| |
| static std::string | render (const std::string &format, const matador::json &data) |
| |
| static std::string | render (const char *format, size_t len, const matador::json &data) |
| |
|
static std::string | render (const std::shared_ptr< detail::template_part > &part, const matador::json &data) |
| |
|
static std::shared_ptr< detail::template_part > | build (const std::string &format) |
| |
This class provides static methods to render data (json, structure or object pointer) into a given format string
◆ render() [1/4]
| static std::string matador::http::template_engine::render |
( |
const char * |
format, |
|
|
size_t |
len, |
|
|
const matador::json & |
data |
|
) |
| |
|
static |
Render the given format string with the given json data object.
- Parameters
-
| format | Format string to render. |
| len | Length of the format string. |
| data | Json data object to be rendered in. |
- Returns
- The rendered string
◆ render() [2/4]
| static std::string matador::http::template_engine::render |
( |
const std::string & |
format, |
|
|
const matador::json & |
data |
|
) |
| |
|
static |
Render the given format string with the given json data object.
- Parameters
-
| format | Format string to render. |
| data | Json data object to be rendered in. |
- Returns
- The rendered string
◆ render() [3/4]
template<typename T >
| std::string matador::http::template_engine::render |
( |
const std::string & |
format, |
|
|
const object_ptr< T > & |
data |
|
) |
| |
|
static |
Render the format string with the given object pointer.
- Template Parameters
-
- Parameters
-
| format | Format string to render. |
| data | Data object to be rendered in. |
- Returns
- The rendered string
◆ render() [4/4]
template<class T >
| std::string matador::http::template_engine::render |
( |
const std::string & |
format, |
|
|
const T & |
data |
|
) |
| |
|
static |
Render the given format string with the given data object.
- Template Parameters
-
- Parameters
-
| format | Format string to render. |
| data | Data object to be rendered in. |
- Returns
- The rendered string
The documentation for this class was generated from the following file:
- matador/http/template_engine.hpp