TTKMusicPlayer
4.1.3.0
TTKMusicPlayer imitates Kugou UI, the music player uses of qmmp core library based on Qt for windows and linux
Main Page
Related Pages
Namespaces
Classes
Files
File List
File Members
TTKThirdParty
TTKqmmp
qmmp
regularexpression.h
Go to the documentation of this file.
1
/***************************************************************************
2
* This file is part of the TTK qmmp plugin project
3
* Copyright (C) 2015 - 2024 Greedysky Studio
4
5
* This program is free software; you can redistribute it and/or modify
6
* it under the terms of the GNU General Public License as published by
7
* the Free Software Foundation; either version 3 of the License, or
8
* (at your option) any later version.
9
10
* This program is distributed in the hope that it will be useful,
11
* but WITHOUT ANY WARRANTY; without even the implied warranty of
12
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
* GNU General Public License for more details.
14
15
* You should have received a copy of the GNU General Public License along
16
* with this program; If not, see <http://www.gnu.org/licenses/>.
17
***************************************************************************/
18
19
#ifndef REGULAREXPRESSION_H
20
#define REGULAREXPRESSION_H
21
22
#include "
qmmp_export.h
"
23
#if QT_VERSION >= QT_VERSION_CHECK(5,0,0)
24
# include <QRegularExpression>
25
#else
26
# include <QRegExp>
27
#endif
28
32
class
QMMP_EXPORT
RegularExpression
33
{
34
public
:
35
RegularExpression
() =
default
;
36
explicit
RegularExpression
(
const
QString &pattern);
37
38
bool
hasMatch(
const
QString &str);
39
QString value(
int
index)
const
;
40
41
static
QString escape(
const
QString &str);
42
43
#if QT_VERSION >= QT_VERSION_CHECK(5,0,0)
44
operator
QRegularExpression ()
const
;
45
private
:
46
QRegularExpression
m_regular
;
47
# if QT_VERSION >= QT_VERSION_CHECK(5,1,0)
48
QRegularExpressionMatch
m_match
;
49
# else
50
QString m_match;
51
# endif
52
#else
53
operator
QRegExp ()
const
;
54
private
:
55
QRegExp m_regular;
56
#endif
57
58
};
59
60
#endif
RegularExpression::m_match
QRegularExpressionMatch m_match
Definition:
regularexpression.h:48
RegularExpression::m_regular
QRegularExpression m_regular
Definition:
regularexpression.h:46
qmmp_export.h
QMMP_EXPORT
#define QMMP_EXPORT
Definition:
qmmp_export.h:29
RegularExpression
The class of the regular expression.
Definition:
regularexpression.h:32
Generated on Tue Jan 21 2025 21:07:15 for TTKMusicPlayer by
1.8.8