code::W2Program Class Reference

Inheritance diagram for code::W2Program:

code::ControlFilter code::ExternalFilter List of all members.

Detailed Description

A WDSS-II program is typically lauched with a set of options either on the command-line or from a XML configuration file.

This class loads up such a configuration file.

Author:
Lakshman
Version:
Id
code_W2Program.h,v 1.9 2009/06/02 20:17:40 lakshman Exp


Public Types

typedef std::map< char, OptionOptionMap

Public Member Functions

void showUsageLine (const std::string &arg, const std::string &desc) const
void showUsage () const
const OptionMapoptions () const
 Returns the options that this command takes.
OptionMapoptions ()
 Returns the options that this command takes for changing.
void setOption (const Option &opt)
 set or change the value of an option.
 W2Program (const URL &configFile)
 load up options from this configuration file
 W2Program ()
 for STL only.
virtual ~W2Program ()
virtual int launch (const Index::Record &rec, const std::string &outputdir)
 Launch the program with this input, send the output to the given directory or write record to output control lb.
virtual const std::string & getName () const

Protected Attributes

OptionMap myOptions
XML::Element config

Classes

class  Option


Member Typedef Documentation

typedef std::map< char, Option > code::W2Program::OptionMap


Constructor & Destructor Documentation

code::W2Program::W2Program ( const URL configFile  ) 

load up options from this configuration file

code::W2Program::W2Program (  )  [inline]

for STL only.

virtual code::W2Program::~W2Program (  )  [inline, virtual]


Member Function Documentation

virtual const std::string& code::W2Program::getName (  )  const [inline, virtual]

Reimplemented in code::ControlFilter, and code::ExternalFilter.

virtual int code::W2Program::launch ( const Index::Record rec,
const std::string &  outputdir 
) [inline, virtual]

Launch the program with this input, send the output to the given directory or write record to output control lb.

Reimplemented in code::ControlFilter, and code::ExternalFilter.

OptionMap& code::W2Program::options (  )  [inline]

Returns the options that this command takes for changing.

const OptionMap& code::W2Program::options (  )  const [inline]

Returns the options that this command takes.

This information is obtained from the configuration file w2config/filters/executableName

void code::W2Program::setOption ( const Option opt  ) 

set or change the value of an option.

void code::W2Program::showUsage (  )  const

void code::W2Program::showUsageLine ( const std::string &  arg,
const std::string &  desc 
) const


Member Data Documentation

XML::Element code::W2Program::config [protected]

OptionMap code::W2Program::myOptions [protected]


Generated on Fri May 4 13:40:13 2012 for WDSS-IIw2 by  doxygen 1.4.7