8.4.1. MDOException

class MDOException

Represent an error occurred while running MindOpt application

Methods

MDOException

Construct an error with an error code

MDOException

Construct an error with error message and a code

getErrorCode

Retrieve the error code

getMessage

Retrieve the error message

MDOException(int errcode = 0)

Construct an error with an error code

Parameters

int errcode=0 – error code

MDOException(std::string errmsg, int errcode = 0)

Construct an error with error message and a code

Parameters
  • std::string errmsg – error message

  • int errcode=0 – error code

int getErrorCode()

Retrieve the error code

Returns

The error code

const std::string getMessage()

Retrieve the error message

Returns

The error message