ldbl_read_mps.c File Reference

#include "qs_config.h"
#include "ldbl_iqsutil.h"
#include "ldbl_rawlp.h"
#include "ldbl_read_mps.h"
#include "ldbl_read_lp.h"
#include "ldbl_format.h"

Include dependency graph for ldbl_read_mps.c:

Go to the source code of this file.

Defines

#define ldbl_END_LINE(p)   (((*(p)) == '$' || (*(p)) == '\n' || (*(p)) == '\0') ? 1 : 0)

Functions

static char ldbl_get_double (ldbl_ILLread_mps_state *state, int peek, long double *coef)
void ldbl_ILLmps_check_end_of_line (ldbl_ILLread_mps_state *state)
int ldbl_ILLmps_empty_field (ldbl_ILLread_mps_state *state)
int ldbl_ILLmps_empty_key (ldbl_ILLread_mps_state *state)
int ldbl_ILLmps_error (ldbl_ILLread_mps_state *state, const char *format,...)
int ldbl_ILLmps_int_sos_mode (ldbl_ILLread_mps_state *state)
int ldbl_ILLmps_next_bound (ldbl_ILLread_mps_state *state, long double *coef)
int ldbl_ILLmps_next_coef (ldbl_ILLread_mps_state *state, long double *coef)
int ldbl_ILLmps_next_field (ldbl_ILLread_mps_state *state)
static char ldbl_ILLmps_next_field_is_number (ldbl_ILLread_mps_state *state)
int ldbl_ILLmps_next_line (ldbl_ILLread_mps_state *state)
const char * ldbl_ILLmps_possibly_blank_name (const char *field, ldbl_ILLread_mps_state *state, ILLsymboltab *tab)
void ldbl_ILLmps_set_end_of_line (ldbl_ILLread_mps_state *state)
int ldbl_ILLmps_set_section (ldbl_ILLread_mps_state *state, const ILLmps_section sec)
int ldbl_ILLmps_state_init (ldbl_ILLread_mps_state *state, ldbl_qsline_reader *file, const char *ldbl_fname)
void ldbl_ILLmps_warn (ldbl_ILLread_mps_state *state, const char *format,...)
static void ldbl_mps_err (ldbl_ILLread_mps_state *state, int isError, const char *format, va_list args)
static int ldbl_mps_skip_comment (ldbl_ILLread_mps_state *state)

Variables

static int TRACE = 0


Define Documentation

#define ldbl_END_LINE (  )     (((*(p)) == '$' || (*(p)) == '\n' || (*(p)) == '\0') ? 1 : 0)

Definition at line 42 of file ldbl_read_mps.c.


Function Documentation

static char ldbl_get_double ( ldbl_ILLread_mps_state state,
int  peek,
long double *  coef 
) [static]

Definition at line 186 of file ldbl_read_mps.c.

References ILL_FAILfalse, ILL_RESULT, ldbl_ILLget_value(), and ldbl_mps_skip_comment().

Referenced by ldbl_ILLmps_next_bound(), ldbl_ILLmps_next_coef(), and ldbl_ILLmps_next_field_is_number().

Here is the call graph for this function:

void ldbl_ILLmps_check_end_of_line ( ldbl_ILLread_mps_state state  ) 

Definition at line 306 of file ldbl_read_mps.c.

References ldbl_END_LINE, ldbl_ILLmps_warn(), and ldbl_mps_skip_comment().

Referenced by ldbl_read_mps_line_in_section().

Here is the call graph for this function:

int ldbl_ILLmps_empty_field ( ldbl_ILLread_mps_state state  ) 

Definition at line 427 of file ldbl_read_mps.c.

References ldbl_ILLread_mps_state_struct::field.

Referenced by ldbl_add_bounds(), ldbl_add_col(), ldbl_add_row(), ldbl_ILLlib_readbasis(), ldbl_mps_read_col_line(), ldbl_read_mps_line_in_section(), ldbl_read_mps_name(), ldbl_read_mps_objnamesense(), and ldbl_read_mps_refrow().

int ldbl_ILLmps_empty_key ( ldbl_ILLread_mps_state state  ) 

Definition at line 421 of file ldbl_read_mps.c.

References ldbl_ILLread_mps_state_struct::key.

Referenced by ldbl_add_bounds(), ldbl_add_col(), ldbl_add_row(), ldbl_ILLlib_readbasis(), ldbl_ILLread_mps(), ldbl_mps_read_col_line(), ldbl_read_mps_line_in_section(), ldbl_read_mps_objnamesense(), ldbl_read_mps_refrow(), and ldbl_read_mps_section().

int ldbl_ILLmps_error ( ldbl_ILLread_mps_state state,
const char *  format,
  ... 
)

Definition at line 491 of file ldbl_read_mps.c.

References ldbl_mps_err().

Referenced by ldbl_add_bounds(), ldbl_add_ranges(), ldbl_add_rhs(), ldbl_add_row(), ldbl_check_section_order(), ldbl_ILLlib_readbasis(), ldbl_ILLmps_int_sos_mode(), ldbl_ILLmps_set_section(), ldbl_ILLread_mps(), ldbl_mps_read_col_line(), ldbl_mps_read_marker_line(), ldbl_read_mps_line_in_section(), ldbl_read_mps_objnamesense(), ldbl_read_mps_objsense(), ldbl_read_mps_refrow(), and ldbl_read_mps_section().

Here is the call graph for this function:

int ldbl_ILLmps_int_sos_mode ( ldbl_ILLread_mps_state state  ) 

Definition at line 341 of file ldbl_read_mps.c.

References ldbl_ILLread_mps_state_struct::field, ILL_RESULT, ldbl_ILLread_mps_state_struct::intvar, ldbl_ILLmps_error(), and ldbl_ILLread_mps_state_struct::sosvar.

Referenced by ldbl_mps_read_marker_line().

Here is the call graph for this function:

int ldbl_ILLmps_next_bound ( ldbl_ILLread_mps_state state,
long double *  coef 
)

Definition at line 224 of file ldbl_read_mps.c.

References ILL_RESULT, ILL_RETURN, ldbl_END_LINE, ldbl_get_double(), ldbl_ILL_MAXDOUBLE, ldbl_ILL_MINDOUBLE, and ldbl_mps_skip_comment().

Referenced by ldbl_add_bounds().

Here is the call graph for this function:

int ldbl_ILLmps_next_coef ( ldbl_ILLread_mps_state state,
long double *  coef 
)

Definition at line 211 of file ldbl_read_mps.c.

References ILL_RESULT, ldbl_get_double(), and ldbl_mps_skip_comment().

Referenced by ldbl_add_ranges(), ldbl_add_rhs(), and ldbl_mps_read_col_line().

Here is the call graph for this function:

int ldbl_ILLmps_next_field ( ldbl_ILLread_mps_state state  ) 

Definition at line 170 of file ldbl_read_mps.c.

References ldbl_ILLread_mps_state_struct::field, and ldbl_mps_skip_comment().

Referenced by ldbl_add_bounds(), ldbl_add_ranges(), ldbl_add_rhs(), ldbl_add_row(), ldbl_ILLlib_readbasis(), ldbl_mps_read_col_line(), and ldbl_mps_read_marker_line().

Here is the call graph for this function:

static char ldbl_ILLmps_next_field_is_number ( ldbl_ILLread_mps_state state  )  [static]

Definition at line 291 of file ldbl_read_mps.c.

References ldbl_get_double(), and ldbl_mps_skip_comment().

Referenced by ldbl_ILLmps_possibly_blank_name().

Here is the call graph for this function:

int ldbl_ILLmps_next_line ( ldbl_ILLread_mps_state state  ) 

Definition at line 80 of file ldbl_read_mps.c.

References ldbl_ILLread_mps_state_struct::field, ldbl_ILLread_mps_state_struct::field_num, ldbl_ILLread_mps_state_struct::file, ILL_FAILfalse, ILL_namebufsize, ldbl_ILLread_mps_state_struct::key, ldbl_ILL_ISBLANK, ldbl_ILLline_reader_get, ldbl_ILLread_mps_state_struct::line, ldbl_ILLread_mps_state_struct::line_num, and ldbl_ILLread_mps_state_struct::p.

Referenced by ldbl_ILLlib_readbasis(), ldbl_ILLread_mps(), ldbl_read_mps_objnamesense(), and ldbl_read_mps_refrow().

const char* ldbl_ILLmps_possibly_blank_name ( const char *  field,
ldbl_ILLread_mps_state state,
ILLsymboltab tab 
)

Definition at line 395 of file ldbl_read_mps.c.

References ILLsymboltab_lookup(), and ldbl_ILLmps_next_field_is_number().

Referenced by ldbl_add_bounds(), ldbl_add_ranges(), and ldbl_add_rhs().

Here is the call graph for this function:

void ldbl_ILLmps_set_end_of_line ( ldbl_ILLread_mps_state state  ) 

Definition at line 318 of file ldbl_read_mps.c.

References ldbl_ILLread_mps_state_struct::p.

Referenced by ldbl_add_bounds(), ldbl_add_ranges(), and ldbl_add_rhs().

int ldbl_ILLmps_set_section ( ldbl_ILLread_mps_state state,
const ILLmps_section  sec 
)

Definition at line 324 of file ldbl_read_mps.c.

References ldbl_ILLread_mps_state_struct::active, ILL_FAILfalse, ILL_MPS_NONE, ILL_RESULT, ldbl_ILLmps_error(), ldbl_ILLmps_section_name, and ldbl_ILLread_mps_state_struct::section.

Referenced by ldbl_read_mps_section().

Here is the call graph for this function:

int ldbl_ILLmps_state_init ( ldbl_ILLread_mps_state state,
ldbl_qsline_reader file,
const char *  ldbl_fname 
)

Definition at line 49 of file ldbl_read_mps.c.

References ldbl_ILLread_mps_state_struct::active, ldbl_ILLread_mps_state_struct::field, ldbl_ILLread_mps_state_struct::file, ldbl_ILLread_mps_state_struct::file_name, ILL_FAILtrue, ILL_MPS_N_SECTIONS, ILL_MPS_NONE, ILL_RESULT, ldbl_ILLread_mps_state_struct::intvar, ldbl_ILLread_mps_state_struct::key, ldbl_ILLread_mps_state_struct::line, ldbl_ILLread_mps_state_struct::line_num, ldbl_ILLread_mps_state_struct::obj, ldbl_ILLread_mps_state_struct::p, ldbl_ILLread_mps_state_struct::section, and ldbl_ILLread_mps_state_struct::sosvar.

Referenced by ldbl_ILLlib_readbasis(), and ldbl_ILLread_mps().

void ldbl_ILLmps_warn ( ldbl_ILLread_mps_state state,
const char *  format,
  ... 
)

Definition at line 504 of file ldbl_read_mps.c.

References ldbl_mps_err().

Referenced by ldbl_add_ranges(), ldbl_add_rhs(), ldbl_ILLlib_readbasis(), ldbl_ILLmps_check_end_of_line(), ldbl_ILLread_mps(), ldbl_mps_set_bound(), and ldbl_read_mps_name().

Here is the call graph for this function:

static void ldbl_mps_err ( ldbl_ILLread_mps_state state,
int  isError,
const char *  format,
va_list  args 
) [static]

Definition at line 433 of file ldbl_read_mps.c.

References ldbl_qsline_reader::error_collector, ldbl_ILLread_mps_state_struct::file, ldbl_ILLread_mps_state_struct::file_name, ILL_FAILfalse, ILL_FAILfalse_no_rval, ldbl_ILLformat_error, ldbl_ILLformat_error_create(), ldbl_ILLformat_error_delete(), ldbl_ILLread_mps_state_struct::line, ldbl_ILLread_mps_state_struct::line_num, ldbl_ILLread_mps_state_struct::p, QS_MPS_FORMAT_ERROR, and QS_MPS_FORMAT_WARN.

Referenced by ldbl_ILLmps_error(), and ldbl_ILLmps_warn().

Here is the call graph for this function:

static int ldbl_mps_skip_comment ( ldbl_ILLread_mps_state state  )  [static]

Definition at line 156 of file ldbl_read_mps.c.

References ldbl_ILLread_mps_state_struct::field_num, ldbl_ILL_ISBLANK, and ldbl_ILLread_mps_state_struct::p.

Referenced by ldbl_get_double(), ldbl_ILLmps_check_end_of_line(), ldbl_ILLmps_next_bound(), ldbl_ILLmps_next_coef(), ldbl_ILLmps_next_field(), and ldbl_ILLmps_next_field_is_number().


Variable Documentation

int TRACE = 0 [static]

Definition at line 40 of file ldbl_read_mps.c.


Generated on Thu Mar 29 09:40:57 2012 for QSopt_ex by  doxygen 1.4.7