MythTV  master
mythbackend_commandlineparser.cpp
Go to the documentation of this file.
1 #include <QString>
2 
5 
9 
11 {
12  addHelp();
13  addVersion();
14  addDaemon();
16  addUPnP();
17  addDVBv3();
18  addLogging();
19  addPIDFile();
20 
21  CommandLineArg::AllowOneOf(QList<CommandLineArg*>()
22  << add("--pidfile", "pidfile", "",
23  "Filename to save the application pid.", "")
24  << add("--printsched", "printsched", false,
25  "Print upcoming list of scheduled recordings.", "")
26 // ->SetDeprecated("use mythutil instead")
27  << add("--testsched", "testsched", false,
28  "do some scheduler testing.", "")
29 // ->SetDeprecated("use mythutil instead")
30  << add("--resched", "resched", false, "", "")
31  ->SetRemoved("mythbackend is no longer used to trigger\n"
32  " rescheduling. Please use mythutil.", "34")
33  << add("--scanvideos", "scanvideos", false,"", "")
34  ->SetRemoved("mythbackend is no longer used to trigger\n"
35  " scanning media content. Please use mythutil.", "34")
36  << add("--event", "event", "", "", "")
37  ->SetRemoved("mythbackend is no longer used send an event.", "34")
38  << add("--systemevent", "systemevent", "", "", "")
39  ->SetRemoved("mythbackend is no longer used send a SYSTEM_EVENT.", "34")
40  << add("--clearcache", "clearcache", false, "", "")
41  ->SetRemoved("mythbackend is no longer used to clear\n"
42  " the database caches. Please use mythutil.", "34")
43  << add("--printexpire", "printexpire", "ALL",
44  "Print upcoming list of recordings to be expired.", "")
45 // ->SetDeprecated("use mythutil instead")
46  << add("--setverbose", "setverbose", "",
47  "Change debug mask of the existing master backend.", "")
48 // ->SetDeprecated("use mythutil instead")
49  << add("--setloglevel", "setloglevel", "",
50  "Change logging level of the existing master backend.", "")
51 // ->SetDeprecated("use mythutil instead");
52  );
53 
54  add("--webonly", "webonly", false, "Start in web-server-only mode.",
55  "Start the backend in web server mode, where only the "
56  "web server is running. "
57  "This is only for use when the backend crashes due "
58  " to an invalid configuration, and you need to use setup "
59  "to rectify it. Scheduler is disabled in this mode.");
60  add("--nosched", "nosched", false, "",
61  "Intended for debugging use only, disable the scheduler "
62  "on this backend if it is the master backend, preventing "
63  "any recordings from occuring until the backend is "
64  "restarted without this option.");
65  add("--nojobqueue", "nojobqueue", false, "",
66  "Intended for debugging use only, disable the jobqueue "
67  "on this backend. As each jobqueue independently selects "
68  "jobs, this will only have any affect on this local "
69  "backend.");
70  add("--nohousekeeper", "nohousekeeper", false, "",
71  "Intended for debugging use only, disable the housekeeper "
72  "on this backend if it is the master backend, preventing "
73  "any guide processing, recording cleanup, or any other "
74  "task performed by the housekeeper.");
75  add("--noautoexpire", "noautoexpire", false, "",
76  "Intended for debugging use only, disable the autoexpirer "
77  "on this backend if it is the master backend, preventing "
78  "recordings from being expired to clear room for new "
79  "recordings.");
80  add("--user", "username", "",
81  "Drop permissions to username after starting.", "");
82 
83  add("--upnprebuild", "upnprebuild", false, "", "")
84  ->SetRemoved("The UPnP server no longer maintains its own list\n"
85  " of video content, and instead uses the shared\n"
86  " list of the Video Library. Update the Video Library\n"
87  " content list from within mythfrontend, or on the\n"
88  " command line using 'mythutil --scanvideos'.",
89  "0.25");
90  add("--infile", "inputfile", "", "", "")
91  ->SetRemoved("mythbackend is no longer used for preview\n"
92  " generation. Please use mythpreviewgen.", "0.25");
93  add("--outfile", "outputfile", "", "", "")
94  ->SetRemoved("mythbackend is no longer used for preview\n"
95  " generation. Please use mythpreviewgen.", "0.25");
96  add("--chanid", "chanid", "", "", "")
97  ->SetRemoved("mythbackend is no longer used for preview\n"
98  " generation. Please use mythpreviewgen.", "0.25");
99  add("--starttime", "starttime", "", "", "")
100  ->SetRemoved("mythbackend is no longer used for preview\n"
101  " generation. Please use mythpreviewgen.", "0.25");
102 }
103 
105 {
106  return "MythBackend is the primary server application for MythTV. It is \n"
107  "used for recording and remote streaming access of media. Only one \n"
108  "instance of this application is allowed to run on one host at a \n"
109  "time, and one must be configured to operate as a master, performing \n"
110  "additional scheduler and housekeeper tasks.";
111 }
CommandLineArg::AllowOneOf
static void AllowOneOf(const QList< CommandLineArg * > &args)
Mark a list of arguments as mutually exclusive.
Definition: mythcommandlineparser.cpp:933
MythCommandLineParser
Parent class for defining application command line parsers.
Definition: mythcommandlineparser.h:116
MythBackendCommandLineParser::LoadArguments
void LoadArguments(void) override
Definition: mythbackend_commandlineparser.cpp:10
MythCommandLineParser::addPIDFile
void addPIDFile(void)
Canned argument definition for –pidfile.
Definition: mythcommandlineparser.cpp:2705
MythCommandLineParser::addVersion
void addVersion(void)
Canned argument definition for –version.
Definition: mythcommandlineparser.cpp:2534
MythCommandLineParser::addLogging
void addLogging(const QString &defaultVerbosity="general", LogLevel_t defaultLogLevel=LOG_INFO)
Canned argument definition for all logging options, including –verbose, –logpath, –quiet,...
Definition: mythcommandlineparser.cpp:2638
CommandLineArg::SetRemoved
CommandLineArg * SetRemoved(QString remstr="", QString remver="")
Set option as removed.
Definition: mythcommandlineparser.cpp:809
mythbackend_commandlineparser.h
MythCommandLineParser::add
CommandLineArg * add(const QString &arg, const QString &name, bool def, QString help, QString longhelp)
Definition: mythcommandlineparser.cpp:1760
MYTH_APPNAME_MYTHBACKEND
static constexpr const char * MYTH_APPNAME_MYTHBACKEND
Definition: mythcorecontext.h:19
mythcorecontext.h
MythCommandLineParser::addHelp
void addHelp(void)
Canned argument definition for –help.
Definition: mythcommandlineparser.cpp:2521
MythBackendCommandLineParser::MythBackendCommandLineParser
MythBackendCommandLineParser()
Definition: mythbackend_commandlineparser.cpp:6
MythCommandLineParser::addSettingsOverride
void addSettingsOverride(void)
Canned argument definition for –override-setting and –override-settings-file.
Definition: mythcommandlineparser.cpp:2585
MythBackendCommandLineParser::GetHelpHeader
QString GetHelpHeader(void) const override
Definition: mythbackend_commandlineparser.cpp:104
MythCommandLineParser::addUPnP
void addUPnP(void)
Canned argument definition for –noupnp.
Definition: mythcommandlineparser.cpp:2623
MythCommandLineParser::addDaemon
void addDaemon(void)
Canned argument definition for –daemon.
Definition: mythcommandlineparser.cpp:2573
MythCommandLineParser::addDVBv3
void addDVBv3(void)
Canned argument definition for –dvbv3.
Definition: mythcommandlineparser.cpp:2630