Rosetta
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
membrane_abinitio2.cc
Go to the documentation of this file.
1 // -*- mode:c++;tab-width:2;indent-tabs-mode:t;show-trailing-whitespace:t;rm-trailing-spaces:t -*-
2 // vi: set ts=2 noet:
3 //
4 // (c) Copyright Rosetta Commons Member Institutions.
5 // (c) This file is part of the Rosetta software suite and is made available under license.
6 // (c) The Rosetta software is developed by the contributing members of the Rosetta Commons.
7 // (c) For more information, see http://www.rosettacommons.org. Questions about this can be
8 // (c) addressed to University of Washington UW TechTransfer, email: license@u.washington.edu.
9 
10 /// @file
11 /// @brief
12 
13 // libRosetta headers
14 
15 #include <core/types.hh>
16 #include <devel/init.hh>
17 
18 #include <basic/options/option.hh>
19 #include <basic/options/keys/membrane.OptionKeys.gen.hh>
20 
21 #include <protocols/viewer/viewers.hh>
22 #include <protocols/abinitio/AbrelaxApplication.hh>
23 
24 #include <utility/vector1.hh>
26 
27 void*
28 my_main( void *)
29 {
30  protocols::abinitio::AbrelaxApplication abrelax;
31  abrelax.run();
32  return 0 ;
33 }
34 
35 int
36 main( int argc, char * argv [] )
37 {
38  try {
39  using namespace basic::options;
40  using namespace basic::options::OptionKeys;
41 
42  devel::init( argc, argv );
44  protocols::abinitio::AbrelaxApplication abrelax;
45 
46  bool const view( option[ OptionKeys::membrane::view ] );
47 
48  if ( view ) {
49  std::cout << "Start viewer mode " << std::endl;
50  protocols::viewer::viewer_main( my_main );
51  } else {
52  abrelax.run();
53  }
54  } catch ( utility::excn::EXCN_Base const & e ) {
55  std::cout << "caught exception " << e.msg() << std::endl;
56  return -1;
57  }
58  return 0;
59 }
60 
virtual std::string const msg() const
Definition: EXCN_Base.hh:70
void register_options()
void * my_main(void *)
void init(int argc, char *argv[])
Command line init() version.
Definition: init.cc:23
common derived classes for thrown exceptions
int main(int argc, char *argv[])
rule< Scanner, options_closure::context_t > options
Definition: Tag.cc:377
utility::options::OptionCollection option
OptionCollection global.
Definition: option.cc:45
ocstream cout(std::cout)
Wrapper around std::cout.
Definition: ocstream.hh:287
vector1: std::vector with 1-based indexing
Program options global and initialization function.