dialogwebcrawler.h
Go to the documentation of this file.
1 /***************************************************************************
2  SocNetV: Social Network Visualizer
3  version: 3.1
4  Written in Qt
5 
6  dialogwebcrawler.h - description
7  -------------------
8  copyright : (C) 2005-2023 by Dimitris B. Kalamaras
9  email : dimitris.kalamaras@gmail.com
10  website: : http://dimitris.apeiro.gr
11  project site : https://socnetv.org
12 
13  ***************************************************************************/
14 
15 /*******************************************************************************
16 * This program is free software: you can redistribute it and/or modify *
17 * it under the terms of the GNU General Public License as published by *
18 * the Free Software Foundation, either version 3 of the License, or *
19 * (at your option) any later version. *
20 * *
21 * This program is distributed in the hope that it will be useful, *
22 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
23 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
24 * GNU General Public License for more details. *
25 * *
26 * You should have received a copy of the GNU General Public License *
27 * along with this program. If not, see <http://www.gnu.org/licenses/>. *
28 ********************************************************************************/
29 
30 #ifndef WEBCRAWLERDIALOG_H
31 #define WEBCRAWLERDIALOG_H
32 
33 class QUrl;
34 
35 #include <QDialog>
36 
37 #include "ui_dialogwebcrawler.h"
38 
39 
40 class DialogWebCrawler: public QDialog
41 {
42  Q_OBJECT
43 public:
44  explicit DialogWebCrawler (QWidget *parent = Q_NULLPTR);
45 
46 public slots:
47  void checkErrors ();
48  void getUserChoices ();
49  QStringList parseTextEditInput(const QString &html);
50 signals:
51  void userChoices( const QUrl &startUrl,
52  const QStringList &,
53  const QStringList &,
54  const QStringList &,
55  const int &maxNodes,
56  const int &maxLinks,
57  const bool &intLinks,
58  const bool &childLinks,
59  const bool &parentLinks,
60  const bool &selfLinks,
61  const bool &extLinksAllowed,
62  const bool &extLinksCrawl,
63  const bool &socialLinks,
64  const bool &delayedRequests
65  );
66  void webCrawlerDialogError(QString);
67 private:
68  Ui::DialogWebCrawler ui;
69  QString seedUrlInputStr;
70  QUrl seedUrl ;
76  QStringList linkClasses;
77  QStringList urlPatternsIncluded;
78  QStringList urlPatternsExcluded;
79 
80 };
81 
82 
83 
84 #endif
Definition: dialogwebcrawler.h:41
void getUserChoices()
gathers data from web crawler form
Definition: dialogwebcrawler.cpp:341
bool childLinks
Definition: dialogwebcrawler.h:74
void userChoices(const QUrl &startUrl, const QStringList &, const QStringList &, const QStringList &, const int &maxNodes, const int &maxLinks, const bool &intLinks, const bool &childLinks, const bool &parentLinks, const bool &selfLinks, const bool &extLinksAllowed, const bool &extLinksCrawl, const bool &socialLinks, const bool &delayedRequests)
QStringList parseTextEditInput(const QString &html)
Parses HTML-formatted input string and returns a list of all strings inside.
Definition: dialogwebcrawler.cpp:285
int maxUrlsToCrawl
Definition: dialogwebcrawler.h:71
bool parentLinks
Definition: dialogwebcrawler.h:74
QStringList urlPatternsIncluded
Definition: dialogwebcrawler.h:77
QUrl seedUrl
Definition: dialogwebcrawler.h:70
bool intLinks
Definition: dialogwebcrawler.h:72
int maxLinksPerPage
Definition: dialogwebcrawler.h:71
QStringList linkClasses
Definition: dialogwebcrawler.h:76
bool extLinksAllowed
Definition: dialogwebcrawler.h:73
QStringList urlPatternsExcluded
Definition: dialogwebcrawler.h:78
bool socialLinks
Definition: dialogwebcrawler.h:75
Ui::DialogWebCrawler ui
Definition: dialogwebcrawler.h:68
bool extLinks
Definition: dialogwebcrawler.h:72
DialogWebCrawler(QWidget *parent=Q_NULLPTR)
Definition: dialogwebcrawler.cpp:36
void webCrawlerDialogError(QString)
void checkErrors()
Checks crawler form for user input errors.
Definition: dialogwebcrawler.cpp:118
QString seedUrlInputStr
Definition: dialogwebcrawler.h:69