IMP  2.3.0
The Integrative Modeling Platform
flags.h File Reference

Various general useful macros for IMP. More...

#include <IMP/base/base_config.h>
#include <boost/cstdint.hpp>
#include "types.h"
#include <string>
+ Include dependency graph for flags.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  IMP::base::AddBoolFlag
 
struct  IMP::base::AddFloatFlag
 
struct  IMP::base::AddIntFlag
 
struct  IMP::base::AddStringFlag
 

Namespaces

 IMP
 Synonym for IMP::kernel.
 
 IMP::base
 Low level functionality (logging, error handling, profiling, command line flags etc) that is used by all of IMP.
 

Functions

bool IMP::base::get_is_quick_test ()
 
void IMP::base::write_help (std::ostream &out=std::cerr)
 

Flags

These methods add support for shared command line flags to IMP. Programs that use this have access to flags declared in modules which allow users to do things like control log level and turn on and off profiling to see what is going on. These functions are Python accessible.

In C++, you can also use the AddFloatFlag, AddStringFlag, AddBoolFlag and AddIntFlag classes to add flags statically.

std::string IMP::base::get_executable_name ()
 Return the name of the current executable. More...
 
void IMP::base::setup_from_argv (int argc, char **argv, std::string description)
 Parse the command line flags and return the positional arguments. More...
 
Strings IMP::base::setup_from_argv_allowing_unknown (int argc, char **argv, std::string description)
 
Strings IMP::base::setup_from_argv (int argc, char **argv, std::string description, std::string positional_description, int num_positional)
 
void IMP::base::setup_from_argv (const Strings &argv, std::string description)
 
Strings IMP::base::setup_from_argv (const Strings &argv, std::string description, std::string positional_description, int num_positional)
 
void IMP::base::add_string_flag (std::string name, std::string default_value, std::string description)
 
std::string IMP::base::get_string_flag (std::string name)
 
void IMP::base::add_int_flag (std::string name, size_t default_value, std::string description)
 
size_t IMP::base::get_int_flag (std::string name)
 
void IMP::base::add_bool_flag (std::string name, std::string description)
 
bool IMP::base::get_bool_flag (std::string name)
 
void IMP::base::add_float_flag (std::string name, double default_value, std::string description)
 
double IMP::base::get_float_flag (std::string name)
 

Detailed Description

Various general useful macros for IMP.

Copyright 2007-2014 IMP Inventors. All rights reserved.

Definition in file flags.h.