Detailed Description
Public methods for scores.
Functions | |
| GCG_EXPORT SCIP_RETCODE | GCGincludeScore (GCG *gcg, const char *name, const char *shortname, const char *description, GCG_SCOREDATA *scoredata, GCG_DECL_SCOREFREE((*scorefree)), GCG_DECL_SCORECALC((*scorecalc))) |
| creates a score and includes it in GCG More... | |
| GCG_EXPORT GCG_SCORE * | GCGfindScore (GCG *gcg, const char *name) |
| searches for the score with the given name and returns it or NULL if score is not found More... | |
| GCG_EXPORT GCG_SCORE * | GCGfindScoreByShortname (GCG *gcg, const char *shortname) |
| searches for the score with the given shortname and returns it or NULL if score is not found More... | |
| GCG_EXPORT GCG_SCORE ** | GCGgetScores (GCG *gcg) |
| GCG_EXPORT int | GCGgetNScores (GCG *gcg) |
| GCG_EXPORT GCG_SCOREDATA * | GCGscoreGetData (GCG_SCORE *score) |
| GCG_EXPORT void | GCGscoreSetData (GCG_SCORE *score, GCG_SCOREDATA *scoredata) |
| GCG_EXPORT const char * | GCGscoreGetName (GCG_SCORE *score) |
| GCG_EXPORT const char * | GCGscoreGetShortname (GCG_SCORE *score) |
| GCG_EXPORT const char * | GCGscoreGetDesc (GCG_SCORE *score) |
Function Documentation
◆ GCGincludeScore()
| GCG_EXPORT SCIP_RETCODE GCGincludeScore | ( | GCG * | gcg, |
| const char * | name, | ||
| const char * | shortname, | ||
| const char * | description, | ||
| GCG_SCOREDATA * | scoredata, | ||
| GCG_DECL_SCOREFREE((*scorefree)) | , | ||
| GCG_DECL_SCORECALC((*scorecalc)) | |||
| ) |
creates a score and includes it in GCG
- Returns
- scip return code
- Parameters
-
gcg GCG data structure name name of score shortname shortname of score description description of score scoredata score data
Definition at line 50 of file score.c.
References GCGconshdlrDecompIncludeScore(), GCGfindScore(), GCGfindScoreByShortname(), NULL, SCIP_CALL, SCIP_INVALIDDATA, SCIP_OKAY, and SCIPerrorMessage.
Referenced by GCGincludeScoreBender(), GCGincludeScoreBorder(), GCGincludeScoreClassic(), GCGincludeScoreFawh(), GCGincludeScoreForswh(), GCGincludeScoreMaxwhite(), GCGincludeScoreSpfawh(), GCGincludeScoreSpfwh(), and GCGincludeScoreStrongDecomp().
◆ GCGfindScore()
| GCG_EXPORT GCG_SCORE * GCGfindScore | ( | GCG * | gcg, |
| const char * | name | ||
| ) |
searches for the score with the given name and returns it or NULL if score is not found
- Returns
- score pointer or NULL if score with given name is not found
- Parameters
-
gcg GCG data structure name name of score
Definition at line 76 of file score.c.
References GCGconshdlrDecompFindScore(), and NULL.
Referenced by GCGincludeScore().
◆ GCGfindScoreByShortname()
| GCG_EXPORT GCG_SCORE * GCGfindScoreByShortname | ( | GCG * | gcg, |
| const char * | shortname | ||
| ) |
searches for the score with the given shortname and returns it or NULL if score is not found
- Returns
- score pointer or NULL if score with given shortname is not found
- Parameters
-
gcg GCG data structure shortname shortname of score
Definition at line 91 of file score.c.
References GCGconshdlrDecompFindScoreByShortname(), and NULL.
Referenced by GCGincludeScore().
◆ GCGgetScores()
| GCG_EXPORT GCG_SCORE ** GCGgetScores | ( | GCG * | gcg | ) |
returns the array of currently available scores
- Parameters
-
gcg GCG data structure
Definition at line 103 of file score.c.
References GCGconshdlrDecompGetScores(), and NULL.
Referenced by SCIP_DECL_DIALOGEXEC().
◆ GCGgetNScores()
| GCG_EXPORT int GCGgetNScores | ( | GCG * | gcg | ) |
returns the number of currently available scores
- Parameters
-
gcg GCG data structure
Definition at line 113 of file score.c.
References GCGconshdlrDecompGetNScores(), and NULL.
Referenced by SCIP_DECL_DIALOGEXEC().
◆ GCGscoreGetData()
| GCG_EXPORT GCG_SCOREDATA * GCGscoreGetData | ( | GCG_SCORE * | score | ) |
gets user data of score
- Parameters
-
score score
Definition at line 123 of file score.c.
References NULL, and GCG_Score::scoredata.
Referenced by calculateDualvalsOptimalOrigLP(), GCG_DECL_SCORECALC(), GCG_DECL_SCOREFREE(), getDualvalOptimalLP(), getDualvalRandom(), and shuffleDualvalsRandom().
◆ GCGscoreSetData()
| GCG_EXPORT void GCGscoreSetData | ( | GCG_SCORE * | score, |
| GCG_SCOREDATA * | scoredata | ||
| ) |
sets user data of score; user has to free old data in advance!
- Parameters
-
score score scoredata new score user data
Definition at line 133 of file score.c.
References NULL, and GCG_Score::scoredata.
◆ GCGscoreGetName()
| GCG_EXPORT const char * GCGscoreGetName | ( | GCG_SCORE * | score | ) |
gets name of score
- Parameters
-
score score
Definition at line 145 of file score.c.
References GCG_Score::name, and NULL.
Referenced by gcg::PARTIALDECOMP::displayInfo(), GCG_DECL_SCOREFREE(), gcg::GCGdialogChangeScore(), and SCIP_DECL_DIALOGEXEC().
◆ GCGscoreGetShortname()
| GCG_EXPORT const char * GCGscoreGetShortname | ( | GCG_SCORE * | score | ) |
gets shortname of score
- Parameters
-
score score
Definition at line 155 of file score.c.
References NULL, and GCG_Score::shortname.
Referenced by gcg::GCGdialogChangeScore(), gcg::GCGdialogShowLegend(), gcg::GCGdialogShowMenu(), gcg::GCGdialogSortBy(), and SCIP_DECL_DIALOGEXEC().
◆ GCGscoreGetDesc()
| GCG_EXPORT const char * GCGscoreGetDesc | ( | GCG_SCORE * | score | ) |
gets description of score
- Parameters
-
score score
Definition at line 165 of file score.c.
References GCG_Score::description, and NULL.
Referenced by gcg::GCGdialogShowLegend(), SCIP_DECL_DIALOGEXEC(), and writeTexTitlepage().