drogon
C++14/17-based HTTP application framework
Toggle main menu visibility
Loading...
Searching...
No Matches
DrTemplateBase.h
Go to the documentation of this file.
1
14
15
#pragma once
16
17
#include <drogon/exports.h>
18
#include <
drogon/DrObject.h
>
19
#include <
drogon/HttpViewData.h
>
20
#include <memory>
21
#include <string>
22
23
namespace
drogon
24
{
25
using
DrTemplateData =
HttpViewData
;
26
28
33
class
DROGON_EXPORT DrTemplateBase :
public
virtual
DrObjectBase
34
{
35
public
:
37
43
static
std::shared_ptr<DrTemplateBase>
newTemplate
(
44
const
std::string &templateName);
45
47
51
virtual
std::string
genText
(
52
const
DrTemplateData &data = DrTemplateData()) = 0;
53
54
virtual
~DrTemplateBase(){};
55
DrTemplateBase
(){};
56
};
57
58
}
// namespace drogon
DrObject.h
HttpViewData.h
drogon::DrObjectBase
The base class for all drogon reflection classes.
Definition
DrObject.h:34
drogon::DrTemplateBase
The templating engine class.
Definition
DrTemplateBase.h:34
drogon::DrTemplateBase::genText
virtual std::string genText(const DrTemplateData &data=DrTemplateData())=0
Generate the text string.
drogon::DrTemplateBase::newTemplate
static std::shared_ptr< DrTemplateBase > newTemplate(const std::string &templateName)
Create an object of the implementation class.
drogon::HttpViewData
This class represents the data set displayed in views.
Definition
HttpViewData.h:33
drogon
Drogon Test is a minimal effort test framework developed because the major C++ test frameworks doesn'...
Definition
Attribute.h:23
lib
inc
drogon
DrTemplateBase.h
Generated by
1.17.0