This is an automated email from the git hooks/post-receive script. plessy pushed a commit to branch debian/unstable in repository libgtextutils.
commit 84583f5ec5fee0189f58c0b6c2f35ded051d4bcb Author: A. Gordon <[email protected]> Date: Sun Nov 22 17:43:50 2009 -0500 Backed out changeset 74a844a0a4fd - remove boost-crap, 1 --- src/gtextutils/bpo_base.cpp | 2 +- src/gtextutils/bpo_base.h | 2 -- src/gtextutils/bpo_interval_file.cpp | 26 +++----------------------- src/gtextutils/bpo_interval_file.h | 10 ---------- src/gtextutils/bpo_io.cpp | 6 ++---- src/gtextutils/bpo_io.h | 3 +-- 6 files changed, 7 insertions(+), 42 deletions(-) diff --git a/src/gtextutils/bpo_base.cpp b/src/gtextutils/bpo_base.cpp index c64be39..b4bca17 100644 --- a/src/gtextutils/bpo_base.cpp +++ b/src/gtextutils/bpo_base.cpp @@ -11,7 +11,6 @@ using namespace std; using namespace std::tr1; using std::tr1::placeholders::_1; - namespace po = boost::program_options; BPO_EasyParser::BPO_EasyParser() @@ -44,3 +43,4 @@ void BPO_EasyParser::parse ( int argc, char* argv[] ) exit(1); } } + diff --git a/src/gtextutils/bpo_base.h b/src/gtextutils/bpo_base.h index 83d4bdb..0ea8cfe 100644 --- a/src/gtextutils/bpo_base.h +++ b/src/gtextutils/bpo_base.h @@ -1,10 +1,8 @@ #ifndef __BPO_BASE_H__ #define __BPO_BASE_H__ -#include <boost/program_options.hpp> #include <vector> - class GenericBoostProgramOptions { public: diff --git a/src/gtextutils/bpo_interval_file.cpp b/src/gtextutils/bpo_interval_file.cpp index 71b4350..ce771a4 100644 --- a/src/gtextutils/bpo_interval_file.cpp +++ b/src/gtextutils/bpo_interval_file.cpp @@ -9,38 +9,18 @@ namespace po = boost::program_options; IntervalFileColumnOptions::IntervalFileColumnOptions() : - column_options("Input file format"), - _bed_base(true), - _zero_base(false), - _one_base(false), - _zero_based_start_coord(true), - _zero_based_end_coord(false) + column_options("Input file format") { column_options.add_options() ("chrom-col,c", po::value<unsigned int>(&_chrom_column)->default_value(1), "chromosome column") ("start-col,s", po::value<unsigned int>(&_start_column)->default_value(2), "start-coordinate column") ("end-col,e", po::value<unsigned int>(&_end_column)->default_value(3), "end-coordinate column") ("orien-col,a", po::value<unsigned int>(&_orientation_column)->default_value(0), "orientation(+/-) column (default: no orientation information)") - ("multi-col,m", po::value<unsigned int>(&_multiplicity_column)->default_value(0), "multiplicity (=read count) column (default: no multiplicity information)") - ("BED-BASE", po::value<bool>(&_bed_base)->zero_tokens(), "Zero-based start coordinate, one-based end coordinate - like in BED files from UCSC.\nThis is the default." ) - ("ZERO-BASE", po::value<bool>(&_zero_base)->zero_tokens(),"BOTH start & end coordinates are zero based" ) - ("ONE-BASE", po::value<bool>(&_one_base)->zero_tokens(),"BOTH start & end coordinates are one based") - ; + ("multi-col,m", po::value<unsigned int>(&_multiplicity_column)->default_value(0), "multiplicity (=read count) column (default: no multiplicity information)") ; } void IntervalFileColumnOptions::validate() { - if ( _bed_base ) { - _zero_based_start_coord = true ; - _zero_based_end_coord = false ; - } else if ( _zero_base ) { - _zero_based_start_coord = true ; - _zero_based_end_coord = true ; - } else if ( _one_base ) { - _zero_based_start_coord = false ; - _zero_based_end_coord = false ; - } - std::stringstream os ; if (_chrom_column <= 0) { os << "Invalid chromosome-column value: '" << _chrom_column << "' - must be larger than zero" ; @@ -55,7 +35,7 @@ void IntervalFileColumnOptions::validate() throw po::error(os.str()) ; } - std::vector<unsigned int> columns; + std::vector<int> columns; columns.push_back ( _chrom_column ); if ( std::find(columns.begin(), columns.end(), _start_column ) != columns.end()) { diff --git a/src/gtextutils/bpo_interval_file.h b/src/gtextutils/bpo_interval_file.h index bbb9331..7d8ca86 100644 --- a/src/gtextutils/bpo_interval_file.h +++ b/src/gtextutils/bpo_interval_file.h @@ -20,13 +20,6 @@ class IntervalFileColumnOptions : public GenericBoostProgramOptions unsigned int _multiplicity_column ; unsigned int _max_used_column ; - - bool _bed_base ; - bool _zero_base ; - bool _one_base ; - - bool _zero_based_start_coord ; - bool _zero_based_end_coord ; public: IntervalFileColumnOptions() ; @@ -42,9 +35,6 @@ public: unsigned int max_used_column() const { return _max_used_column; } - bool zero_based_start_coord() const { return _zero_based_start_coord; } - bool zero_based_end_coord() const { return _zero_based_end_coord; } - virtual void validate() ; }; diff --git a/src/gtextutils/bpo_io.cpp b/src/gtextutils/bpo_io.cpp index 8f02c74..2166225 100644 --- a/src/gtextutils/bpo_io.cpp +++ b/src/gtextutils/bpo_io.cpp @@ -11,15 +11,13 @@ namespace po = boost::program_options; InputOutputOptions::InputOutputOptions() : io_options("Input/Output options"), _verbose(false), - _help(false), - _skip_first_line(false) + _help(false) { io_options.add_options() ("input-file,i", po::value<std::string>(&_input_filename), "Input file (default: stdin)") ("output-file,o", po::value<std::string>(&_output_filename), "Output file (default: stdout)" ) ("verbose,v", po::value<bool>(&_verbose)->zero_tokens(), "verbose (if output goes to STDOUT, verbose summary will be printed to STDERR. If output goes to afile, verbose summary will be printed to STDOUT).") - ("help,h", po::value<bool>(&_help)->zero_tokens(), "help and command line options") - ("skip-first-line,L", po::value<bool>(&_skip_first_line)->zero_tokens(),"skip first input line (use if input file contains header line)" ); + ("help,h", po::value<bool>(&_help)->zero_tokens(), "help and command line options") ; } diff --git a/src/gtextutils/bpo_io.h b/src/gtextutils/bpo_io.h index 5e463e7..163d1be 100644 --- a/src/gtextutils/bpo_io.h +++ b/src/gtextutils/bpo_io.h @@ -7,6 +7,7 @@ /* Future improvements: + option "SKIP_FIRST_LINE", option "DEBUG" make "VERBOSE" optional */ @@ -18,7 +19,6 @@ class InputOutputOptions : public GenericBoostProgramOptions std::string _output_filename ; bool _verbose ; bool _help ; - bool _skip_first_line ; public: InputOutputOptions(); @@ -30,7 +30,6 @@ public: std::string output_file() const { return _output_filename ; } bool verbose() const { return _verbose; } bool help() const { return _help ; } - bool skip_first_line() const { return _skip_first_line; } }; #endif -- Alioth's /git/debian-med/git-commit-notice on /srv/git.debian.org/git/debian-med/libgtextutils.git _______________________________________________ debian-med-commit mailing list [email protected] http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/debian-med-commit
