/[ascend]/trunk/ascxx/solver.h
ViewVC logotype

Annotation of /trunk/ascxx/solver.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2327 - (hide annotations) (download) (as text)
Wed Dec 22 07:17:24 2010 UTC (13 years, 9 months ago) by jpye
File MIME type: text/x-chdr
File size: 997 byte(s)
Merging in refactor of the C++ code, which is moved out of 'pygtk' and into 'ascxx'.
Adding support for IPOPT 3.9.1, the current latest version.
Support in dtar for parallel builds (possibly needs some testing still).
1 johnpye 151 #ifndef ASCXX_SOLVER_H
2     #define ASCXX_SOLVER_H
3    
4 johnpye 132 #include <string>
5     #include <vector>
6    
7 johnpye 480 #include "config.h"
8 johnpye 132 extern "C"{
9 jpye 2323 #include <ascend/general/platform.h>
10 jpye 2018 #include <ascend/compiler/instance_enum.h>
11     #include <ascend/system/slv_client.h>
12 johnpye 132 }
13    
14     /**
15     This is a rather problematic wrapper for slv_client.h. It's hard because registerd solvers
16     are referenced primarily by index, not by pointer etc, so given the index, we always have
17 johnpye 208 to look up the solver in some way or other.
18    
19     Because the index is changeable from session to session, depending on the order of
20     registration, we'll use the *name* as the primary key and look up the index as needed.
21 johnpye 132 */
22     class Solver{
23     private:
24 johnpye 150 std::string name;
25 johnpye 132 public:
26 johnpye 785 Solver();
27 johnpye 132 Solver(const Solver &);
28 johnpye 150 Solver(const std::string &name);
29 johnpye 132
30 johnpye 150 const int getIndex() const;
31     const std::string& getName() const;
32 johnpye 132 };
33    
34 johnpye 208 /**
35     Some global functions
36     */
37     void registerStandardSolvers();
38 jpye 1487 //void registerSolver(SlvRegistration regfuncptr);
39 johnpye 208 const std::vector<Solver> getSolvers();
40    
41 johnpye 151 #endif

john.pye@anu.edu.au
ViewVC Help
Powered by ViewVC 1.1.22