Args parse for XrdClReplay.
More...
#include <XrdClReplayArgs.hh>
Args parse for XrdClReplay.
Definition at line 35 of file XrdClReplayArgs.hh.
◆ ReplayArgs()
XrdCl::ReplayArgs::ReplayArgs |
( |
int |
argc, |
|
|
char * |
argv[] |
|
) |
| |
|
inline |
Definition at line 38 of file XrdClReplayArgs.hh.
40 , option_summary(
false)
42 , option_create(
false)
43 , option_truncate(
false)
45 , option_suppress_error(
false)
46 , option_verify(
false)
52 static struct option long_options[]
53 = { {
"help", no_argument, 0,
'h' }, {
"print", no_argument, 0,
'p' },
54 {
"create", no_argument, 0,
'c' }, {
"truncate", no_argument, 0,
't' },
55 {
"long", no_argument, 0,
'l' }, {
"json", no_argument, 0,
'j' },
56 {
"summary", no_argument, 0,
's' }, {
"replace", required_argument, 0,
'r' },
57 {
"suppress", no_argument, 0,
'f' }, {
"verify", no_argument, 0,
'v' },
58 {
"speed", required_argument, 0,
'x' }, { 0, 0, 0, 0 } };
60 int c = getopt_long(argc, argv,
"vjpctshlfr:x:", long_options, &option_index);
78 option_truncate =
true;
90 option_summary =
true;
102 option_speed = std::strtod(optarg, 0);
103 if (option_speed <= 0)
110 option_regex.push_back(optarg);
114 option_suppress_error =
true;
122 if (option_json && (option_long || option_summary))
123 option_long = option_summary =
true;
128 option_create =
false;
129 option_truncate =
false;
138 if (
optind == (argc -1 )) {
References optind, and usage().
◆ create()
bool XrdCl::ReplayArgs::create |
( |
| ) |
|
|
inline |
◆ json()
bool XrdCl::ReplayArgs::json |
( |
| ) |
|
|
inline |
◆ longformat()
bool XrdCl::ReplayArgs::longformat |
( |
| ) |
|
|
inline |
◆ path()
std::string& XrdCl::ReplayArgs::path |
( |
| ) |
|
|
inline |
◆ print()
bool XrdCl::ReplayArgs::print |
( |
| ) |
|
|
inline |
◆ regex()
std::vector<std::string>& XrdCl::ReplayArgs::regex |
( |
| ) |
|
|
inline |
◆ speed()
double XrdCl::ReplayArgs::speed |
( |
| ) |
|
|
inline |
◆ summary()
bool XrdCl::ReplayArgs::summary |
( |
| ) |
|
|
inline |
◆ suppress_error()
bool XrdCl::ReplayArgs::suppress_error |
( |
| ) |
|
|
inline |
◆ truncate()
bool XrdCl::ReplayArgs::truncate |
( |
| ) |
|
|
inline |
◆ usage()
void XrdCl::ReplayArgs::usage |
( |
| ) |
|
|
inline |
Definition at line 144 of file XrdClReplayArgs.hh.
147 <<
"usage: xrdreplay [-p|--print] [-c|--create-data] [t|--truncate-data] [-l|--long] [-s|--summary] [-h|--help] [-r|--replace <arg>:=<newarg>] [-f|--suppress] [-v|--verify] [-x|--speed <value] p<recordfilename>]\n"
149 std::cerr <<
" -h | --help : show this help" << std::endl;
151 <<
" -f | --suppress : force to run all IO with all successful result status - suppress all others"
154 <<
" - by default the player won't run with an unsuccessful recorded IO"
156 std::cerr << std::endl;
158 <<
" -p | --print : print only mode - shows all the IO for the given replay file without actually running any IO"
161 <<
" -s | --summary : print summary - shows all the aggregated IO counter summed for all files"
164 <<
" -l | --long : print long - show all file IO counter for each individual file"
166 std::cerr <<
" -v | --verify : verify the existence of all input files"
169 <<
" -x | --speed <x> : change playback speed by factor <x> [ <x> > 0.0 ]"
172 <<
" -r | --replace <a>:=<b> : replace in the argument list the string <a> with <b> "
175 <<
" - option is usable several times e.g. to change storage prefixes or filenames"
177 std::cerr << std::endl;
179 <<
" [recordfilename] : if a file is given, it will be used as record input otherwise STDIN is used to read records!"
182 <<
"example: ... --replace file:://localhost:=root://xrootd.eu/ : redirect local file to remote"
184 std::cerr << std::endl;
Referenced by ReplayArgs().
◆ verify()
bool XrdCl::ReplayArgs::verify |
( |
| ) |
|
|
inline |
The documentation for this class was generated from the following file: