Grantlee  5.2.0
util.h
Go to the documentation of this file.
1 /*
2  This file is part of the Grantlee template system.
3 
4  Copyright (c) 2009,2010 Stephen Kelly <steveire@gmail.com>
5 
6  This library is free software; you can redistribute it and/or
7  modify it under the terms of the GNU Lesser General Public
8  License as published by the Free Software Foundation; either version
9  2.1 of the Licence, or (at your option) any later version.
10 
11  This library is distributed in the hope that it will be useful,
12  but WITHOUT ANY WARRANTY; without even the implied warranty of
13  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14  Lesser General Public License for more details.
15 
16  You should have received a copy of the GNU Lesser General Public
17  License along with this library. If not, see <http://www.gnu.org/licenses/>.
18 
19 */
20 
21 #ifndef GRANTLEE_UTIL_P_H
22 #define GRANTLEE_UTIL_P_H
23 
24 #include "context.h"
25 #include "grantlee_templates_export.h"
26 #include "safestring.h"
27 
28 #include <QtCore/QVariant>
29 
31 
32 namespace Grantlee
33 {
34 
40 GRANTLEE_TEMPLATES_EXPORT bool variantIsTrue(const QVariant &variant);
41 
48 GRANTLEE_TEMPLATES_EXPORT QString unescapeStringLiteral(const QString &input);
49 
53 GRANTLEE_TEMPLATES_EXPORT Grantlee::SafeString
55 
59 GRANTLEE_TEMPLATES_EXPORT Grantlee::SafeString
61 
65 GRANTLEE_TEMPLATES_EXPORT Grantlee::SafeString
66 getSafeString(const QVariant &input);
67 
71 GRANTLEE_TEMPLATES_EXPORT bool isSafeString(const QVariant &input);
72 
79 GRANTLEE_TEMPLATES_EXPORT bool supportedOutputType(const QVariant &input);
80 
87 GRANTLEE_TEMPLATES_EXPORT bool equals(const QVariant &lhs, const QVariant &rhs);
88 
89 #ifndef Q_QDOC
90 
95 GRANTLEE_TEMPLATES_EXPORT Grantlee::SafeString
96 toString(const QVariantList &list);
97 #endif
98 }
99 
100 #endif
Grantlee::getSafeString
Grantlee::SafeString getSafeString(const QVariant &input)
Grantlee::variantIsTrue
bool variantIsTrue(const QVariant &variant)
Grantlee::unescapeStringLiteral
QString unescapeStringLiteral(const QString &input)
Grantlee::markForEscaping
Grantlee::SafeString markForEscaping(const Grantlee::SafeString &input)
Grantlee::equals
bool equals(const QVariant &lhs, const QVariant &rhs)
Grantlee::SafeString
A QString wrapper class for containing whether a string is safe or needs to be escaped.
Definition: safestring.h:92
Grantlee::isSafeString
bool isSafeString(const QVariant &input)
Grantlee
The Grantlee namespace holds all public Grantlee API.
Definition: Mainpage.dox:8
Grantlee::supportedOutputType
bool supportedOutputType(const QVariant &input)
Grantlee::markSafe
Grantlee::SafeString markSafe(const Grantlee::SafeString &input)