00001
00002
00003
00004
00005
00006
00007
00008
00009
00010 #ifndef IpCbcBoundsReader_HPP
00011 #define IpCbcBoundsReader_HPP
00012
00013 #include <string>
00014 #include "IpoptInterface.hpp"
00015
00018 class IpCbcBoundsReader
00019 {
00020 public:
00021
00022 IpCbcBoundsReader():
00023 fileName_(),
00024 lowerBounds_(NULL),
00025 upperBounds_(NULL),
00026 nLower_(0),
00027 nUpper_(0)
00028 {}
00029
00030
00031 IpCbcBoundsReader(const std::string &fileName):
00032 fileName_(fileName),
00033 lowerBounds_(NULL),
00034 upperBounds_(NULL),
00035 indexLowers_(NULL),
00036 indexUppers_(NULL),
00037 nLower_(0),
00038 nUpper_(0)
00039 {}
00040
00041
00042 void setFileName(const std::string &fileName)
00043 {
00044 fileName_ = fileName;
00045 }
00046
00047
00048 ~IpCbcBoundsReader();
00049
00050
00051 void gutsOfDestructor();
00052
00053
00054
00055 void read(const std::string &);
00056
00057
00058 void read();
00059
00060
00061 void readAndApply(IpoptInterface& solver);
00062 private:
00063
00065 std::string fileName_;
00067 double * lowerBounds_;
00069 double * upperBounds_;
00071 int * indexLowers_;
00073 int * indexUppers_;
00075 int nLower_;
00077 int nUpper_;
00078 };
00079
00080 #endif