13 #ifndef CbcOrClpParam_H 14 #define CbcOrClpParam_H 327 void append(std::string keyWord);
330 void addHelp(std::string keyWord);
332 inline std::string
name()
const 460 int matches(std::string input)
const;
570 #define CBCMAXPARAMETERS 250 578 const std::vector< CbcOrClpParam > ¶meters);
void gutsOfConstructor()
gutsOfConstructor
std::string CoinReadNextField()
Simple read stuff.
void setCbcOrClpPrinting(bool yesNo)
int intParameter(CbcModel &model) const
Gets a int parameter.
int intValue_
Integer parameter - current value.
std::string CoinReadGetCommand(int argc, const char *argv[])
double doubleValue_
Double parameter - current value.
std::string CoinReadGetString(int argc, const char *argv[])
double upperDoubleValue() const
Returns the upper bound for a double-valued parameter.
CbcOrClpParameterType type() const
type
const char * setCurrentOptionWithMessage(int value)
Sets current parameter option and returns printable string.
std::string stringValue() const
void printLongHelp() const
Print Long help.
Very simple class for setting parameters.
int checkDoubleParameter(double value) const
Checks a double parameter (nonzero code if error)
void printOptions() const
Prints parameter options.
int fakeKeyWord() const
Gets value of fake keyword.
void addHelp(std::string keyWord)
Adds one help line.
void setIntValue(int value)
Sets int value.
CbcOrClpParam & operator=(const CbcOrClpParam &rhs)
Assignment operator. This copies the data.
void setCurrentOption(int value, bool printIt=false)
Sets current parameter option.
const char * setDoubleParameterWithMessage(CbcModel &model, double value, int &returnCode)
Sets double parameter and returns printable string and error code.
int lengthMatchName() const
Returns length of name for ptinting.
void printString() const
Print action and string.
std::string name() const
Returns name.
const char * setDoubleValueWithMessage(double value)
Sets double value with message.
int whereUsed_
7 if used everywhere, 1 - used by clp 2 - used by cbc 4 - used by ampl
const char * setIntParameterWithMessage(CbcModel &model, int value, int &returnCode)
Sets int parameter and returns printable string and error code.
int displayThis() const
whether to display
void setFakeKeyWord(int value, int fakeValue)
Sets value of fake keyword.
void setDoubleValue(double value)
Sets double value.
std::string shortHelp() const
Returns short help.
int whichParam(const CbcOrClpParameterType &name, const std::vector< CbcOrClpParam > ¶meters)
This solves LPs using the simplex method.
int currentKeyWord_
Current keyWord (if a keyword parameter)
int whereUsed() const
7 if used everywhere, 1 - used by clp 2 - used by cbc 4 - used by ampl
void CoinReadPrintit(const char *input)
std::vector< std::string > definedKeyWords_
set of valid strings
int lowerIntValue() const
Returns the lower bound for an int-valued parameter.
double lowerDoubleValue_
If double == okay.
int fakeValue_
Return this as main value if an integer.
std::string matchName() const
Returns name which could match.
double CoinReadGetDoubleField(int argc, const char *argv[], int *valid)
unsigned int lengthMatch_
std::string shortHelp_
Short help.
std::string longHelp_
Long help.
void establishParams(std::vector< CbcOrClpParam > ¶ms)
double doubleParameter(CbcModel &model) const
Gets a double parameter.
int upperIntValue() const
Returns the upper bound for an int-valued parameter.
void append(std::string keyWord)
Insert string (only valid for keywords)
std::string currentOption() const
Returns current parameter option.
std::string longHelp() const
Returns long help.
int CoinReadGetIntField(int argc, const char *argv[], int *valid)
int currentOptionAsInteger() const
Returns current parameter option position.
double doubleValue() const
void setLonghelp(const std::string help)
Set Long help.
int fakeKeyWord_
If >=0 then integers allowed as a fake keyword So minusnnnn would got to -nnnn in currentKeyword_ and...
CbcOrClpParameterType
Parameter codes.
CbcOrClpParam()
Constructors.
void restoreSolution(ClpSimplex *lpSolver, std::string fileName, int mode)
int lowerIntValue_
If int == okay.
~CbcOrClpParam()
Destructor.
int setDoubleParameter(CbcModel &model, double value)
Sets a double parameter (nonzero code if error)
void setStringValue(std::string value)
Sets string value.
CbcOrClpParameterType action_
Action.
int matches(std::string input) const
Returns 1 if matches minimum, 2 if matches less, 0 if not matched.
#define OsiSolverInterface
void saveSolution(const ClpSimplex *lpSolver, std::string fileName)
const std::vector< std::string > & definedKeywords() const
Returns set of valid strings.
int parameterOption(std::string check) const
Returns parameter option which matches (-1 if none)
double lowerDoubleValue() const
Returns the lower bound for a double-valued parameter.
int setIntParameter(CbcModel &model, int value)
Sets a int parameter (nonzero code if error)
std::string stringValue_
String parameter - current value.
const char * setIntValueWithMessage(int value)
Sets int value with message.
CbcOrClpParameterType type_