summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2012-06-20 10:11:01 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2012-06-20 10:11:01 +0200
commit07eb1add3c500ca4c53d499340bf5d524e288b39 (patch)
treedd22e27434b3bb5c787b1682e9849e5ea32b1f2e
parentd12531b8c82d7c728df660f9268df993079ba261 (diff)
Rename --*logue options to --*logue-file
-rw-r--r--cli/generator.cxx8
-rw-r--r--cli/options.cli8
-rw-r--r--cli/options.cxx100
-rw-r--r--cli/options.hxx36
-rw-r--r--cli/options.ixx20
-rw-r--r--doc/cli.18
-rw-r--r--doc/cli.xhtml8
-rw-r--r--doc/makefile8
8 files changed, 98 insertions, 98 deletions
diff --git a/cli/generator.cxx b/cli/generator.cxx
index 1ebde25..8d14bd7 100644
--- a/cli/generator.cxx
+++ b/cli/generator.cxx
@@ -310,14 +310,14 @@ generate (options const& ops, semantics::cli_unit& unit, path const& p)
//
ifstream prologue, epilogue;
{
- string file (ops.man_prologue ());
+ string file (ops.man_prologue_file ());
if (!file.empty ())
open (prologue, file);
}
{
- string file (ops.man_epilogue ());
+ string file (ops.man_epilogue_file ());
if (!file.empty ())
open (epilogue, file);
@@ -368,14 +368,14 @@ generate (options const& ops, semantics::cli_unit& unit, path const& p)
//
ifstream prologue, epilogue;
{
- string file (ops.html_prologue ());
+ string file (ops.html_prologue_file ());
if (!file.empty ())
open (prologue, file);
}
{
- string file (ops.html_epilogue ());
+ string file (ops.html_epilogue_file ());
if (!file.empty ())
open (epilogue, file);
diff --git a/cli/options.cli b/cli/options.cli
index fe48219..aef408e 100644
--- a/cli/options.cli
+++ b/cli/options.cli
@@ -121,25 +121,25 @@ class options
"Generate documentation in the HTML format."
};
- std::string --man-prologue
+ std::string --man-prologue-file
{
"<file>",
"Insert the content of <file> at the beginning of the man page file."
};
- std::string --man-epilogue
+ std::string --man-epilogue-file
{
"<file>",
"Insert the content of <file> at the end of the man page file."
};
- std::string --html-prologue
+ std::string --html-prologue-file
{
"<file>",
"Insert the content of <file> at the beginning of the HTML file."
};
- std::string --html-epilogue
+ std::string --html-epilogue-file
{
"<file>",
"Insert the content of <file> at the end of the HTML file."
diff --git a/cli/options.cxx b/cli/options.cxx
index 0b79417..9cd7407 100644
--- a/cli/options.cxx
+++ b/cli/options.cxx
@@ -23,9 +23,9 @@ namespace cli
}
void unknown_option::
- print (std::ostream& os) const
+ print (::std::ostream& os) const
{
- os << "unknown option '" << option () << "'";
+ os << "unknown option '" << option ().c_str () << "'";
}
const char* unknown_option::
@@ -42,9 +42,9 @@ namespace cli
}
void unknown_argument::
- print (std::ostream& os) const
+ print (::std::ostream& os) const
{
- os << "unknown argument '" << argument () << "'";
+ os << "unknown argument '" << argument ().c_str () << "'";
}
const char* unknown_argument::
@@ -61,9 +61,9 @@ namespace cli
}
void missing_value::
- print (std::ostream& os) const
+ print (::std::ostream& os) const
{
- os << "missing value for option '" << option () << "'";
+ os << "missing value for option '" << option ().c_str () << "'";
}
const char* missing_value::
@@ -80,10 +80,10 @@ namespace cli
}
void invalid_value::
- print (std::ostream& os) const
+ print (::std::ostream& os) const
{
- os << "invalid value '" << value () << "' for option '"
- << option () << "'";
+ os << "invalid value '" << value ().c_str () << "' for option '"
+ << option ().c_str () << "'";
}
const char* invalid_value::
@@ -95,7 +95,7 @@ namespace cli
// eos_reached
//
void eos_reached::
- print (std::ostream& os) const
+ print (::std::ostream& os) const
{
os << what ();
}
@@ -114,9 +114,9 @@ namespace cli
}
void file_io_failure::
- print (std::ostream& os) const
+ print (::std::ostream& os) const
{
- os << "unable to open file '" << file () << "' or read failure";
+ os << "unable to open file '" << file ().c_str () << "' or read failure";
}
const char* file_io_failure::
@@ -133,9 +133,9 @@ namespace cli
}
void unmatched_quote::
- print (std::ostream& os) const
+ print (::std::ostream& os) const
{
- os << "unmatched quote in argument '" << argument () << "'";
+ os << "unmatched quote in argument '" << argument ().c_str () << "'";
}
const char* unmatched_quote::
@@ -568,10 +568,10 @@ options ()
generate_cxx_ (),
generate_man_ (),
generate_html_ (),
- man_prologue_ (),
- man_epilogue_ (),
- html_prologue_ (),
- html_epilogue_ (),
+ man_prologue_file_ (),
+ man_epilogue_file_ (),
+ html_prologue_file_ (),
+ html_epilogue_file_ (),
class__ (),
stdout__ (),
hxx_suffix_ (".hxx"),
@@ -614,10 +614,10 @@ options (int& argc,
generate_cxx_ (),
generate_man_ (),
generate_html_ (),
- man_prologue_ (),
- man_epilogue_ (),
- html_prologue_ (),
- html_epilogue_ (),
+ man_prologue_file_ (),
+ man_epilogue_file_ (),
+ html_prologue_file_ (),
+ html_epilogue_file_ (),
class__ (),
stdout__ (),
hxx_suffix_ (".hxx"),
@@ -663,10 +663,10 @@ options (int start,
generate_cxx_ (),
generate_man_ (),
generate_html_ (),
- man_prologue_ (),
- man_epilogue_ (),
- html_prologue_ (),
- html_epilogue_ (),
+ man_prologue_file_ (),
+ man_epilogue_file_ (),
+ html_prologue_file_ (),
+ html_epilogue_file_ (),
class__ (),
stdout__ (),
hxx_suffix_ (".hxx"),
@@ -712,10 +712,10 @@ options (int& argc,
generate_cxx_ (),
generate_man_ (),
generate_html_ (),
- man_prologue_ (),
- man_epilogue_ (),
- html_prologue_ (),
- html_epilogue_ (),
+ man_prologue_file_ (),
+ man_epilogue_file_ (),
+ html_prologue_file_ (),
+ html_epilogue_file_ (),
class__ (),
stdout__ (),
hxx_suffix_ (".hxx"),
@@ -763,10 +763,10 @@ options (int start,
generate_cxx_ (),
generate_man_ (),
generate_html_ (),
- man_prologue_ (),
- man_epilogue_ (),
- html_prologue_ (),
- html_epilogue_ (),
+ man_prologue_file_ (),
+ man_epilogue_file_ (),
+ html_prologue_file_ (),
+ html_epilogue_file_ (),
class__ (),
stdout__ (),
hxx_suffix_ (".hxx"),
@@ -810,10 +810,10 @@ options (::cli::scanner& s,
generate_cxx_ (),
generate_man_ (),
generate_html_ (),
- man_prologue_ (),
- man_epilogue_ (),
- html_prologue_ (),
- html_epilogue_ (),
+ man_prologue_file_ (),
+ man_epilogue_file_ (),
+ html_prologue_file_ (),
+ html_epilogue_file_ (),
class__ (),
stdout__ (),
hxx_suffix_ (".hxx"),
@@ -886,16 +886,16 @@ print_usage (::std::ostream& os)
os << "--generate-html Generate documentation in the HTML format." << ::std::endl;
- os << "--man-prologue <file> Insert the content of <file> at the beginning of" << ::std::endl
+ os << "--man-prologue-file <file> Insert the content of <file> at the beginning of" << ::std::endl
<< " the man page file." << ::std::endl;
- os << "--man-epilogue <file> Insert the content of <file> at the end of the man" << ::std::endl
+ os << "--man-epilogue-file <file> Insert the content of <file> at the end of the man" << ::std::endl
<< " page file." << ::std::endl;
- os << "--html-prologue <file> Insert the content of <file> at the beginning of" << ::std::endl
+ os << "--html-prologue-file <file> Insert the content of <file> at the beginning of" << ::std::endl
<< " the HTML file." << ::std::endl;
- os << "--html-epilogue <file> Insert the content of <file> at the end of the" << ::std::endl
+ os << "--html-epilogue-file <file> Insert the content of <file> at the end of the" << ::std::endl
<< " HTML file." << ::std::endl;
os << "--class <fq-name> Generate the man page or HTML documentation only" << ::std::endl
@@ -994,14 +994,14 @@ struct _cli_options_map_init
&::cli::thunk< options, bool, &options::generate_man_ >;
_cli_options_map_["--generate-html"] =
&::cli::thunk< options, bool, &options::generate_html_ >;
- _cli_options_map_["--man-prologue"] =
- &::cli::thunk< options, std::string, &options::man_prologue_ >;
- _cli_options_map_["--man-epilogue"] =
- &::cli::thunk< options, std::string, &options::man_epilogue_ >;
- _cli_options_map_["--html-prologue"] =
- &::cli::thunk< options, std::string, &options::html_prologue_ >;
- _cli_options_map_["--html-epilogue"] =
- &::cli::thunk< options, std::string, &options::html_epilogue_ >;
+ _cli_options_map_["--man-prologue-file"] =
+ &::cli::thunk< options, std::string, &options::man_prologue_file_ >;
+ _cli_options_map_["--man-epilogue-file"] =
+ &::cli::thunk< options, std::string, &options::man_epilogue_file_ >;
+ _cli_options_map_["--html-prologue-file"] =
+ &::cli::thunk< options, std::string, &options::html_prologue_file_ >;
+ _cli_options_map_["--html-epilogue-file"] =
+ &::cli::thunk< options, std::string, &options::html_epilogue_file_ >;
_cli_options_map_["--class"] =
&::cli::thunk< options, std::vector<std::string>, &options::class__ >;
_cli_options_map_["--stdout"] =
diff --git a/cli/options.hxx b/cli/options.hxx
index 64c52e7..c513e03 100644
--- a/cli/options.hxx
+++ b/cli/options.hxx
@@ -41,11 +41,11 @@ namespace cli
{
public:
virtual void
- print (std::ostream&) const = 0;
+ print (::std::ostream&) const = 0;
};
- std::ostream&
- operator<< (std::ostream&, const exception&);
+ ::std::ostream&
+ operator<< (::std::ostream&, const exception&);
class unknown_option: public exception
{
@@ -59,7 +59,7 @@ namespace cli
option () const;
virtual void
- print (std::ostream&) const;
+ print (::std::ostream&) const;
virtual const char*
what () const throw ();
@@ -80,7 +80,7 @@ namespace cli
argument () const;
virtual void
- print (std::ostream&) const;
+ print (::std::ostream&) const;
virtual const char*
what () const throw ();
@@ -101,7 +101,7 @@ namespace cli
option () const;
virtual void
- print (std::ostream&) const;
+ print (::std::ostream&) const;
virtual const char*
what () const throw ();
@@ -126,7 +126,7 @@ namespace cli
value () const;
virtual void
- print (std::ostream&) const;
+ print (::std::ostream&) const;
virtual const char*
what () const throw ();
@@ -140,7 +140,7 @@ namespace cli
{
public:
virtual void
- print (std::ostream&) const;
+ print (::std::ostream&) const;
virtual const char*
what () const throw ();
@@ -158,7 +158,7 @@ namespace cli
file () const;
virtual void
- print (std::ostream&) const;
+ print (::std::ostream&) const;
virtual const char*
what () const throw ();
@@ -179,7 +179,7 @@ namespace cli
argument () const;
virtual void
- print (std::ostream&) const;
+ print (::std::ostream&) const;
virtual const char*
what () const throw ();
@@ -408,16 +408,16 @@ class options
generate_html () const;
const std::string&
- man_prologue () const;
+ man_prologue_file () const;
const std::string&
- man_epilogue () const;
+ man_epilogue_file () const;
const std::string&
- html_prologue () const;
+ html_prologue_file () const;
const std::string&
- html_epilogue () const;
+ html_epilogue_file () const;
const std::vector<std::string>&
class_ () const;
@@ -500,10 +500,10 @@ class options
bool generate_cxx_;
bool generate_man_;
bool generate_html_;
- std::string man_prologue_;
- std::string man_epilogue_;
- std::string html_prologue_;
- std::string html_epilogue_;
+ std::string man_prologue_file_;
+ std::string man_epilogue_file_;
+ std::string html_prologue_file_;
+ std::string html_epilogue_file_;
std::vector<std::string> class__;
bool stdout__;
std::string hxx_suffix_;
diff --git a/cli/options.ixx b/cli/options.ixx
index 1b56750..e095b95 100644
--- a/cli/options.ixx
+++ b/cli/options.ixx
@@ -14,8 +14,8 @@ namespace cli
// exception
//
- inline std::ostream&
- operator<< (std::ostream& os, const exception& e)
+ inline ::std::ostream&
+ operator<< (::std::ostream& os, const exception& e)
{
e.print (os);
return os;
@@ -311,27 +311,27 @@ generate_html () const
}
inline const std::string& options::
-man_prologue () const
+man_prologue_file () const
{
- return this->man_prologue_;
+ return this->man_prologue_file_;
}
inline const std::string& options::
-man_epilogue () const
+man_epilogue_file () const
{
- return this->man_epilogue_;
+ return this->man_epilogue_file_;
}
inline const std::string& options::
-html_prologue () const
+html_prologue_file () const
{
- return this->html_prologue_;
+ return this->html_prologue_file_;
}
inline const std::string& options::
-html_epilogue () const
+html_epilogue_file () const
{
- return this->html_epilogue_;
+ return this->html_epilogue_file_;
}
inline const std::vector<std::string>& options::
diff --git a/doc/cli.1 b/doc/cli.1
index 3e3a822..76bbfeb 100644
--- a/doc/cli.1
+++ b/doc/cli.1
@@ -131,16 +131,16 @@ Generate documentation in the man page format\.
.IP "\fB--generate-html\fP"
Generate documentation in the HTML format\.
-.IP "\fB--man-prologue\fP \fIfile\fP"
+.IP "\fB--man-prologue-file\fP \fIfile\fP"
Insert the content of \fIfile\fP at the beginning of the man page file\.
-.IP "\fB--man-epilogue\fP \fIfile\fP"
+.IP "\fB--man-epilogue-file\fP \fIfile\fP"
Insert the content of \fIfile\fP at the end of the man page file\.
-.IP "\fB--html-prologue\fP \fIfile\fP"
+.IP "\fB--html-prologue-file\fP \fIfile\fP"
Insert the content of \fIfile\fP at the beginning of the HTML file\.
-.IP "\fB--html-epilogue\fP \fIfile\fP"
+.IP "\fB--html-epilogue-file\fP \fIfile\fP"
Insert the content of \fIfile\fP at the end of the HTML file\.
.IP "\fB--class\fP \fIfq-name\fP"
diff --git a/doc/cli.xhtml b/doc/cli.xhtml
index c6ef7b4..bcd6959 100644
--- a/doc/cli.xhtml
+++ b/doc/cli.xhtml
@@ -156,16 +156,16 @@
<dt><code><b>--generate-html</b></code></dt>
<dd>Generate documentation in the HTML format.</dd>
- <dt><code><b>--man-prologue</b></code> <i>file</i></dt>
+ <dt><code><b>--man-prologue-file</b></code> <i>file</i></dt>
<dd>Insert the content of <i>file</i> at the beginning of the man page file.</dd>
- <dt><code><b>--man-epilogue</b></code> <i>file</i></dt>
+ <dt><code><b>--man-epilogue-file</b></code> <i>file</i></dt>
<dd>Insert the content of <i>file</i> at the end of the man page file.</dd>
- <dt><code><b>--html-prologue</b></code> <i>file</i></dt>
+ <dt><code><b>--html-prologue-file</b></code> <i>file</i></dt>
<dd>Insert the content of <i>file</i> at the beginning of the HTML file.</dd>
- <dt><code><b>--html-epilogue</b></code> <i>file</i></dt>
+ <dt><code><b>--html-epilogue-file</b></code> <i>file</i></dt>
<dd>Insert the content of <i>file</i> at the end of the HTML file.</dd>
<dt><code><b>--class</b></code> <i>fq-name</i></dt>
diff --git a/doc/makefile b/doc/makefile
index f05102a..00350a4 100644
--- a/doc/makefile
+++ b/doc/makefile
@@ -17,16 +17,16 @@ $(out_base)/cli.xhtml: $(src_root)/cli/options.cli \
$(src_base)/cli-prologue.xhtml \
$(src_base)/cli-epilogue.xhtml
$(call message,cli-html $<,$(out_root)/cli/cli --generate-html \
---output-dir $(out_base) --html-prologue $(src_base)/cli-prologue.xhtml \
---html-epilogue $(src_base)/cli-epilogue.xhtml $<)
+--output-dir $(out_base) --html-prologue-file $(src_base)/cli-prologue.xhtml \
+--html-epilogue-file $(src_base)/cli-epilogue.xhtml $<)
$(call message,,mv $(out_base)/options.html $(out_base)/cli.xhtml)
$(out_base)/cli.1: $(src_root)/cli/options.cli \
$(src_base)/cli-prologue.1 \
$(src_base)/cli-epilogue.1
$(call message,cli-man $<,$(out_root)/cli/cli --generate-man \
---output-dir $(out_base) --man-prologue $(src_base)/cli-prologue.1 \
---man-epilogue $(src_base)/cli-epilogue.1 $<)
+--output-dir $(out_base) --man-prologue-file $(src_base)/cli-prologue.1 \
+--man-epilogue-file $(src_base)/cli-epilogue.1 $<)
$(call message,,mv $(out_base)/options.1 $(out_base)/cli.1)
# Install.