Otawa  0.10
otawa::LogOption Class Reference

Defines a command line option supporting log level thanks to strings 'proc', 'cfg' or 'bb'. More...

#include <otawa/app/Application.h>

Inheritance diagram for otawa::LogOption:
elm::option::AbstractValueOption elm::option::Option

Public Member Functions

 LogOption (option::Manager &man)
 Declare a standard log option identified by "--log". More...
 
 LogOption (option::Manager &man, int tag,...)
 Build a log option with the given configuration. More...
 
 operator Processor::log_level_t (void) const
 Get the set log level. More...
 
Processor::log_level_t operator* (void) const
 
virtual void process (String arg)
 Processor::log_level_t LogOption::operator*(void) const; Get the set log level. More...
 
virtual cstring description (void)
 
virtual usage_t usage (void)
 
virtual cstring argDescription (void)
 
 Option (void)
 
 Option (const Make &make)
 
void output (io::Output &out)
 
virtual char shortName (void)
 
virtual CString longName (void)
 

Protected Member Functions

virtual void configure (Manager &manager, int tag, VarArg &args)
 
void init (Manager &manager, int tag,...)
 
void init (Manager &manager, int tag, VarArg &args)
 

Protected Attributes

cstring desc
 

Private Attributes

Processor::log_level_t log_level
 

Detailed Description

Defines a command line option supporting log level thanks to strings 'proc', 'cfg' or 'bb'.

Constructor & Destructor Documentation

otawa::LogOption::LogOption ( option::Manager man)

Declare a standard log option identified by "--log".

If the option is not passed, revert to value Processor::LOG_NONE.

Parameters
manUsed option manager.
otawa::LogOption::LogOption ( option::Manager man,
int  tag,
  ... 
)

Build a log option with the given configuration.

If the option is not passed, revert to value Processor::LOG_NONE.

Parameters
manUsed option manager.
tagFirst tag.
...Must be a list of tags and their argument ended by option::end.

References elm::option::AbstractValueOption::init().

Member Function Documentation

otawa::LogOption::operator Processor::log_level_t ( void  ) const
inline

Get the set log level.

Returns
Set log level.
Processor::log_level_t otawa::LogOption::operator* ( void  ) const
inline
void otawa::LogOption::process ( String  arg)
virtual

Processor::log_level_t LogOption::operator*(void) const; Get the set log level.

Returns
Set log level. Process the passed log level.
Parameters
argPassed argument.
Exceptions
option::OptionExceptionIf the argument does not match.

Implements elm::option::AbstractValueOption.

References _, otawa::Monitor::LOG_BLOCK, otawa::Monitor::LOG_FILE, otawa::Monitor::LOG_FUN, otawa::Monitor::LOG_INST, log_level, otawa::Monitor::LOG_NONE, otawa::Monitor::LOG_PROC, elm::pair(), and elm::Pair< T1, T2 >::snd.

Member Data Documentation

Processor::log_level_t otawa::LogOption::log_level
private

Referenced by process().


The documentation for this class was generated from the following files: