OSOption.cpp
Go to the documentation of this file.
1 /* $Id: OSOption.cpp 5284 2017-12-08 13:52:50Z stefan $ */
17 #include "OSOption.h"
18 #include "OSParameters.h"
19 #include "OSGeneral.h"
20 #include "OSErrorClass.h"
21 #include "OSOutput.h"
22 
23 #include "CoinFinite.hpp"
24 #include <iostream>
25 #include <sstream>
26 #include <limits>
27 #include <cstdio>
28 #include "OSMathUtil.h"
29 
30 using namespace std;
31 
33  locationType ("local"),
34  value ("")
35 {
36 #ifndef NDEBUG
37  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside InstanceLocationOption Constructor");
38 #endif
39 }// end InstanceLocationOption constructor
40 
42 {
43 #ifndef NDEBUG
44  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "InstanceLocationOption Destructor Called");
45 #endif
46 }//end InstanceLocationOption destructor
47 
48 
50  transportType ("osp"),
51  value ("")
52 {
53 #ifndef NDEBUG
54  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside ContactOption Constructor");
55 #endif
56 }// end ContactOption constructor
57 
59 {
60 #ifndef NDEBUG
61  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "ContactOption Destructor Called");
62 #endif
63 }//end ContactOption destructor
64 
65 
67  name (""),
68  value (""),
69  description ("")
70 {
71 #ifndef NDEBUG
72  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside OtherOption Constructor");
73 #endif
74 }// end OtherOption constructor
75 
77 {
78 #ifndef NDEBUG
79  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "OtherOption Destructor Called");
80 #endif
81 }//end OtherOption destructor
82 
83 
85  numberOfOtherOptions(0)
86 {
87 #ifndef NDEBUG
88  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside OtherOptions Constructor");
89 #endif
90  other = NULL;
91 }// end OtherOptions constructor
92 
94 {
95 #ifndef NDEBUG
96  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "OtherOptions Destructor Called");
97 #endif
98 
99  if (other != NULL)
100  {
101  int i;
102  for (i=0; i<numberOfOtherOptions; i++)
103  {
104  delete other[i];
105  other[i] = NULL;
106  }
107  delete[] other;
108  other = NULL;
109  }
110 }//end OtherOptions destructor
111 
112 
114  serviceURI (""),
115  serviceName (""),
116  instanceName (""),
117  jobID (""),
118  solverToInvoke (""),
119  license (""),
120  userName (""),
121  password ("")
122 {
123 #ifndef NDEBUG
124  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside GeneralOption Constructor");
125 #endif
126  instanceLocation = NULL;
127  contact = NULL;
128  otherOptions = NULL;
129 }// end GeneralOption constructor
130 
132 {
133 #ifndef NDEBUG
134  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "GeneralOption Destructor Called");
135 #endif
136  if (instanceLocation != NULL) delete instanceLocation;
137  instanceLocation = NULL;
138  if (contact != NULL) delete contact;
139  contact = NULL;
140  if (otherOptions != NULL) delete otherOptions;
141  otherOptions = NULL;
142 }//end GeneralOption destructor
143 
144 
146  unit ("byte"),
147  description(""),
148  value (0.0)
149 {
150 #ifndef NDEBUG
151  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside MinDiskSpace Constructor");
152 #endif
153 }// end MinDiskSpace constructor
154 
156 {
157 #ifndef NDEBUG
158  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "MinDiskSpace Destructor Called");
159 #endif
160 }// end MinDiskSpace destructor
161 
162 
164  unit ("byte"),
165  description(""),
166  value (0.0)
167 {
168 #ifndef NDEBUG
169  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside MinMemorySize Constructor");
170 #endif
171 }// end MinMemorySize constructor
172 
174 {
175 #ifndef NDEBUG
176  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "MinMemorySize Destructor Called");
177 #endif
178 }// end MinMemorySize destructor
179 
180 
182  unit ("hertz"),
183  description(""),
184  value (0.0)
185 {
186 #ifndef NDEBUG
187  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside MinCPUSpeed Constructor");
188 #endif
189 }// end MinCPUSpeed constructor
190 
192 {
193 #ifndef NDEBUG
194  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "MinCPUSpeed Destructor Called");
195 #endif
196 }// end MinCPUSpeed destructor
197 
199  description(""),
200  value (0)
201 {
202 #ifndef NDEBUG
203  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside MinCPUNumber Constructor");
204 #endif
205 }// end MinCPUNumber constructor
206 
208 {
209 #ifndef NDEBUG
210  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "MinCPUNumber Destructor Called");
211 #endif
212 }// end MinCPUNumber destructor
213 
214 
216 {
217 #ifndef NDEBUG
218  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside SystemOption Constructor");
219 #endif
220  minDiskSpace = NULL;
221  minMemorySize = NULL;
222  minCPUSpeed = NULL;
223  minCPUNumber = NULL;
224  otherOptions = NULL;
225 }// end SystemOption constructor
226 
228 {
229 #ifndef NDEBUG
230  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "SystemOption Destructor Called");
231 #endif
232  if (minDiskSpace != NULL) delete minDiskSpace;
233  minDiskSpace = NULL;
234  if (minMemorySize != NULL) delete minMemorySize;
235  minMemorySize = NULL;
236  if (minCPUSpeed != NULL) delete minCPUSpeed;
237  minCPUSpeed = NULL;
238  if (minCPUNumber != NULL) delete minCPUNumber;
239  minCPUNumber = NULL;
240  if (otherOptions != NULL) delete otherOptions;
241  otherOptions = NULL;
242 }//end SystemOption destructor
243 
244 
246  type ("solver")
247 {
248 #ifndef NDEBUG
249  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside ServiceOption Constructor");
250 #endif
251  otherOptions = NULL;
252 }// end ServiceOption constructor
253 
255 {
256 #ifndef NDEBUG
257  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "ServiceOption Destructor Called");
258 #endif
259  if (otherOptions != NULL) delete otherOptions;
260  otherOptions = NULL;
261 }//end ServiceOption destructor
262 
263 
265  numberOfJobIDs (0)
266 {
267 #ifndef NDEBUG
268  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside JobDependencies Constructor");
269 #endif
270  jobID = NULL;
271 }// end JobDependencies constructor
272 
274 {
275 #ifndef NDEBUG
276  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "JobDependencies Destructor Called");
277 #endif
278 
279  if (jobID != NULL)
280  {
281  delete[] jobID;
282  jobID = NULL;
283  }
284 }//end JobDependencies destructor
285 
286 
288  numberOfPaths (0)
289 {
290 #ifndef NDEBUG
291  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside DirectoriesAndFiles Constructor");
292 #endif
293  path = NULL;
294 }// end DirectoriesAndFiles constructor
295 
297 {
298 #ifndef NDEBUG
299  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "DirectoriesAndFiles Destructor Called");
300 #endif
301  if (path != NULL)
302  {
303  delete[] path;
304  path = NULL;
305  }
306 }//end DirectoriesAndFiles destructor
307 
308 
310  from (""),
311  to (""),
312  makeCopy (false)
313 {
314 #ifndef NDEBUG
315  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside PathPair Constructor");
316 #endif
317 }// end PathPair constructor
318 
320 {
321 #ifndef NDEBUG
322  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "PathPair Destructor Called");
323 #endif
324 }//end PathPair destructor
325 
326 
328  numberOfPathPairs(0)
329 {
330 #ifndef NDEBUG
331  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside PathPairs Constructor");
332 #endif
333  pathPair = NULL;
334 }// end PathPairs constructor
335 
337 {
338 #ifndef NDEBUG
339  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "PathPairs Destructor Called");
340 #endif
341  int i;
342  if (pathPair != NULL)
343  {
344  for (i=0; i < numberOfPathPairs; i++)
345  {
346  delete pathPair[i];
347  pathPair[i] = NULL;
348  }
349  delete[] pathPair;
350  pathPair = NULL;
351  }
352 }//end PathPairs destructor
353 
354 
355 
357  numberOfProcesses(0)
358 {
359 #ifndef NDEBUG
360  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside Processes Constructor");
361 #endif
362  process = NULL;
363 }// end Processes constructor
364 
366 {
367 #ifndef NDEBUG
368  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Processes Destructor Called");
369 #endif
370  if (process != NULL)
371  {
372  delete[] process;
373  process = NULL;
374  }
375 }//end Processes destructor
376 
377 
379  requestedStartTime("")
380 {
381 #ifndef NDEBUG
382  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside JobOption Constructor");
383 #endif
384  maxTime = NULL;
385  dependencies = NULL;
386  requiredDirectories = NULL;
387  requiredFiles = NULL;
388  directoriesToMake = NULL;
389  filesToMake = NULL;
390  inputDirectoriesToMove = NULL;
391  inputFilesToMove = NULL;
392  outputFilesToMove = NULL;
394  filesToDelete = NULL;
395  directoriesToDelete = NULL;
396  processesToKill = NULL;
397  otherOptions = NULL;
398 }// end JobOption constructor
399 
401 {
402 #ifndef NDEBUG
403  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "JobOption Destructor Called");
404 #endif
405  if (maxTime != NULL) delete maxTime;
406  maxTime = NULL;
407  if (dependencies != NULL) delete dependencies;
408  dependencies = NULL;
409  if (requiredDirectories != NULL) delete requiredDirectories;
410  requiredDirectories = NULL;
411  if (requiredFiles != NULL) delete requiredFiles;
412  requiredFiles = NULL;
413  if (directoriesToMake != NULL) delete directoriesToMake;
414  directoriesToMake = NULL;
415  if (filesToMake != NULL) delete filesToMake;
416  filesToMake = NULL;
418  inputDirectoriesToMove = NULL;
419  if (inputFilesToMove != NULL) delete inputFilesToMove;
420  inputFilesToMove = NULL;
423  if (outputFilesToMove != NULL) delete outputFilesToMove;
424  outputFilesToMove = NULL;
425  if (filesToDelete != NULL) delete filesToDelete;
426  filesToDelete = NULL;
427  if (directoriesToDelete != NULL) delete directoriesToDelete;
428  directoriesToDelete = NULL;
429  if (processesToKill != NULL) delete processesToKill;
430  processesToKill = NULL;
431  if (otherOptions != NULL) delete otherOptions;
432  otherOptions = NULL;
433 }//end JobOption destructor
434 
435 
437  idx (-1),
438  name (""),
439  value (OSNaN())
440 {
441 #ifndef NDEBUG
442  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside InitVarValue Constructor");
443 #endif
444 }// end InitVarValue constructor
445 
447 {
448 #ifndef NDEBUG
449  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "InitVarValue Destructor Called");
450 #endif
451 }//end InitVarValue destructor
452 
453 
455  numberOfVar (0)
456 {
457 #ifndef NDEBUG
458  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside InitVariableValues Constructor");
459 #endif
460  var = NULL;
461 }// end InitVariableValues constructor
462 
464 {
465 #ifndef NDEBUG
466  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "InitVariableValues Destructor Called");
467 #endif
468  int i;
469  if (var != NULL)
470  {
471  for (i=0; i < numberOfVar; i++)
472  {
473  delete var[i];
474  var[i] = NULL;
475  }
476  delete[] var;
477  var = NULL;
478  }
479 }//end InitVariableValues destructor
480 
481 
483  idx (-1),
484  name (""),
485  value ("")
486 {
487 #ifndef NDEBUG
488  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside InitVarValueString Constructor");
489 #endif
490 }// end InitVarValueString constructor
491 
493 {
494 #ifndef NDEBUG
495  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "InitVarValueString Destructor Called");
496 #endif
497 }//end InitVarValueString destructor
498 
499 
501  numberOfVar (0)
502 {
503 #ifndef NDEBUG
504  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside InitVariableValuesString Constructor");
505 #endif
506  var = NULL;
507 }// end InitVariableValuesString constructor
508 
510 {
511 #ifndef NDEBUG
512  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "InitVariableValuesString Destructor Called");
513 #endif
514  int i;
515  if (var != NULL)
516  {
517  for (i=0; i < numberOfVar; i++)
518  {
519  delete var[i];
520  var[i] = NULL;
521  }
522  delete[] var;
523  var = NULL;
524  }
525 }//end InitVariableValues destructor
526 
528  idx (-1),
529  value ("unknown")
530 {
531 #ifndef NDEBUG
532  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside InitBasStatus Constructor");
533 #endif
534 }// end InitBasStatus constructor
535 
537 {
538 #ifndef NDEBUG
539  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "InitBasStatus Destructor Called");
540 #endif
541 }//end InitBasStatus destructor
542 
543 
545  numberOfVar (0)
546 {
547 #ifndef NDEBUG
548  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside InitialBasisStatus Constructor");
549 #endif
550  var = NULL;
551 }// end InitialBasisStatus constructor
552 
554 {
555 #ifndef NDEBUG
556  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "InitialBasisStatus Destructor Called");
557 #endif
558  if (var != NULL)
559  {
560  int i;
561  for (i=0; i < numberOfVar; i++)
562  {
563  delete var[i];
564  var[i] = NULL;
565  }
566  delete[] var;
567  var = NULL;
568  }
569 }//end InitialBasisStatus destructor
570 
572  idx (-1),
573  name (""),
574  value (0.0)
575 {
576 #ifndef NDEBUG
577  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside BranchingWeight Constructor");
578 #endif
579 }// end BranchingWeight constructor
580 
582 {
583 #ifndef NDEBUG
584  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "BranchingWeight Destructor Called");
585 #endif
586 }//end BranchingWeight destructor
587 
588 
590  numberOfVar (0)
591 {
592 #ifndef NDEBUG
593  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside IntegerVariableBranchingWeights Constructor");
594 #endif
595  var = NULL;
596 }// end IntegerVariableBranchingWeights constructor
597 
599 {
600 #ifndef NDEBUG
601  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "IntegerVariableBranchingWeights Destructor Called");
602 #endif
603  if (var != NULL)
604  {
605  int i;
606  for (i=0; i < numberOfVar; i++)
607  {
608  delete var[i];
609  var[i] = NULL;
610  }
611  delete[] var;
612  var = NULL;
613  }
614 }//end IntegerVariableBranchingWeights destructor
615 
617  sosIdx (-1),
618  groupWeight (1.0),
619  numberOfVar (0)
620 {
621 #ifndef NDEBUG
622  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside SOSWeights Constructor");
623 #endif
624  var = NULL;
625 }// end SOSWeights constructor
626 
628 {
629 #ifndef NDEBUG
630  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "SOSWeights Destructor Called");
631 #endif
632  if (var != NULL)
633  {
634  int i;
635  for (i=0; i < numberOfVar; i++)
636  {
637  delete var[i];
638  var[i] = NULL;
639  }
640  delete[] var;
641  var = NULL;
642  }
643 }//end SOSWeights destructor
644 
646  numberOfSOS (0)
647 {
648 #ifndef NDEBUG
649  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside SOSVariableBranchingWeights Constructor");
650 #endif
651  sos = NULL;
652 }// end SOSVariableBranchingWeights constructor
653 
655 {
656 #ifndef NDEBUG
657  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "SOSVariableBranchingWeights Destructor Called");
658 #endif
659  if (sos != NULL)
660  {
661  int i;
662  for (i=0; i < numberOfSOS; i++)
663  {
664  delete sos[i];
665  sos[i] = NULL;
666  }
667  delete[] sos;
668  sos = NULL;
669  }
670 }//end SOSVariableBranchingWeights destructor
671 
673  idx (0),
674  name (""),
675  value (""),
676  lbValue (""),
677  ubValue ("")
678 {
679 #ifndef NDEBUG
680  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside OtherVarOption Constructor");
681 #endif
682 }// end OtherVarOption constructor
683 
685 {
686 #ifndef NDEBUG
687  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "OtherVarOption Destructor Called");
688 #endif
689 }//end OtherVarOption destructor
690 
691 
693  numberOfVar(0),
694  numberOfEnumerations(0),
695  name (""),
696  value (""),
697  solver(""),
698  category (""),
699  type (""),
700  description (""),
701 
702  varType (""),
703  enumType ("")
704 {
705 #ifndef NDEBUG
706  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside OtherVariableOption Constructor");
707 #endif
708  var = NULL;
709  enumeration = NULL;
710 }// end OtherVariableOption constructor
711 
713 {
714 #ifndef NDEBUG
715  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "OtherVariableOption Destructor Called");
716 #endif
717  if (var != NULL)
718  {
719  for (int i=0; i < numberOfVar; i++)
720  {
721  delete var[i];
722  var[i] = NULL;
723  }
724  delete[] var;
725  var = NULL;
726  }
727  if (enumeration != NULL)
728  {
729  for (int i=0; i < numberOfEnumerations; i++)
730  {
731  delete enumeration[i];
732  enumeration[i] = NULL;
733  }
734  delete[] enumeration;
735  enumeration = NULL;
736  }
737 }//end OtherVariableOption destructor
738 
739 
741  numberOfOtherVariableOptions(0)
742 {
743 #ifndef NDEBUG
744  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside VariableOption Constructor");
745 #endif
746  initialVariableValues = NULL;
748  initialBasisStatus = NULL;
751  other = NULL;
752 }// end VariableOption constructor
753 
755 {
756 #ifndef NDEBUG
757  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "VariableOption Destructor Called");
758 #endif
759  if (initialVariableValues != NULL) delete initialVariableValues;
760  initialVariableValues = NULL;
763  if (initialBasisStatus != NULL) delete initialBasisStatus;
764  initialBasisStatus = NULL;
769  if (other != NULL)
770  {
771  int i;
772  for (i=0; i < numberOfOtherVariableOptions; i++)
773  {
774  if (other[i] != NULL)
775  delete other[i];
776  other[i] = NULL;
777 
778  };
779  delete[] other;
780  other = NULL;
781  };
782 }//end VariableOption destructor
783 
784 
786  idx (-1),
787  name (""),
788  value (OSNaN())
789 {
790 #ifndef NDEBUG
791  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside InitObjValue Constructor");
792 #endif
793 }// end InitObjValue constructor
794 
796 {
797 #ifndef NDEBUG
798  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "InitObjValue Destructor Called");
799 #endif
800 }//end InitObjValue destructor
801 
802 
804  numberOfObj (0)
805 {
806 #ifndef NDEBUG
807  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside InitObjectiveValues Constructor");
808 #endif
809  obj = NULL;
810 }// end InitObjectiveValues constructor
811 
813 {
814 #ifndef NDEBUG
815  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "InitObjectiveValues Destructor Called");
816 #endif
817  if (obj != NULL)
818  {
819  int i;
820  for (i=0; i < numberOfObj; i++)
821  {
822  delete obj[i];
823  obj[i] = NULL;
824  }
825  delete[] obj;
826  obj = NULL;
827  };
828 }//end InitObjectiveValues destructor
829 
830 
832  idx (-1),
833  name (""),
834  lbValue (-OSDBL_MAX),
835  ubValue ( OSDBL_MAX)
836 {
837 #ifndef NDEBUG
838  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside InitObjBound Constructor");
839 #endif
840 }// end constructor template
841 
843 {
844 #ifndef NDEBUG
845  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "InitObjBound Destructor Called");
846 #endif
847 }//end InitObjBound destructor
848 
849 
851  numberOfObj (0)
852 {
853 #ifndef NDEBUG
854  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside InitObjectiveBounds Constructor");
855 #endif
856  obj = NULL;
857 }// end InitObjectiveBounds constructor
858 
860 {
861 #ifndef NDEBUG
862  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "InitObjectiveBounds Destructor Called");
863 #endif
864  if (obj != NULL)
865  {
866  int i;
867  for (i=0; i < numberOfObj; i++)
868  {
869  delete obj[i];
870  obj[i] = NULL;
871  }
872  delete[] obj;
873  obj = NULL;
874  };
875 }//end InitObjectiveBounds destructor
876 
877 
879  idx (-1),
880  name (""),
881  value (""),
882  lbValue (""),
883  ubValue ("")
884 {
885 #ifndef NDEBUG
886  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside OtherObjOption Constructor");
887 #endif
888 }// end OtherObjOption constructor
889 
891 {
892 #ifndef NDEBUG
893  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "OtherObjOption Destructor Called");
894 #endif
895 }//end OtherObjOption destructor
896 
897 
899  numberOfObj(0),
900  numberOfEnumerations(0),
901  name (""),
902  value (""),
903  solver(""),
904  category (""),
905  type (""),
906  description (""),
907  objType (""),
908  enumType ("")
909 {
910 #ifndef NDEBUG
911  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside OtherObjectiveOption Constructor");
912 #endif
913  obj = NULL;
914  enumeration = NULL;
915 }// end OtherObjectiveOption constructor
916 
918 {
919 #ifndef NDEBUG
920  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "OtherObjectiveOption Destructor Called");
921 #endif
922  if (obj != NULL)
923  {
924  for (int i=0; i < numberOfObj; i++)
925  {
926  delete obj[i];
927  obj[i] = NULL;
928  }
929  delete[] obj;
930  obj = NULL;
931  }
932  if (enumeration != NULL)
933  {
934  for (int i=0; i < numberOfEnumerations; i++)
935  {
936  delete enumeration[i];
937  enumeration[i] = NULL;
938  }
939  delete[] enumeration;
940  enumeration = NULL;
941  }
942 }//end OtherObjectiveOption destructor
943 
944 
946  numberOfOtherObjectiveOptions (0)
947 {
948 #ifndef NDEBUG
949  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside ObjectiveOption Constructor");
950 #endif
951  initialObjectiveValues = NULL;
952  initialObjectiveBounds = NULL;
953  initialBasisStatus = NULL;
954  other = NULL;
955 }// end ObjectiveOption constructor
956 
958 {
959 #ifndef NDEBUG
960  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "ObjectiveOption Destructor Called");
961 #endif
963  initialObjectiveValues = NULL;
965  initialObjectiveBounds = NULL;
966  if (initialBasisStatus != NULL) delete initialBasisStatus;
967  initialBasisStatus = NULL;
968  if (other != NULL)
969  {
970  int i;
971  for (i=0; i < numberOfOtherObjectiveOptions; i++)
972  {
973  delete other[i];
974  other[i] = NULL;
975  }
976  delete[] other;
977  other = NULL;
978  }
979 }//end ObjectiveOption destructor
980 
981 
983  idx (0),
984  name (""),
985  value (OSNaN())
986 {
987 #ifndef NDEBUG
988  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside InitConValue Constructor");
989 #endif
990 }// end InitConValue constructor
991 
993 {
994 #ifndef NDEBUG
995  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "InitConValue Destructor Called");
996 #endif
997 }//end InitConValue destructor
998 
999 
1001  numberOfCon (0)
1002 {
1003 #ifndef NDEBUG
1004  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside InitConstraintValues Constructor");
1005 #endif
1006  con = NULL;
1007 }// end InitConstraintValues constructor
1008 
1010 {
1011 #ifndef NDEBUG
1012  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "InitConstraintValues Destructor Called");
1013 #endif
1014  if (con != NULL)
1015  {
1016  int i;
1017  for (i=0; i < numberOfCon; i++)
1018  {
1019  delete con[i];
1020  con[i] = NULL;
1021  }
1022  delete[] con;
1023  con = NULL;
1024  };
1025 }//end InitConstraintValues destructor
1026 
1027 
1029  idx (0),
1030  name (""),
1031  lbDualValue (0.0),
1032  ubDualValue (0.0)
1033 {
1034 #ifndef NDEBUG
1035  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside InitDualVarValue Constructor");
1036 #endif
1037 }// end InitDualVarValue constructor
1038 
1040 {
1041 #ifndef NDEBUG
1042  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "InitDualVarValue Destructor Called");
1043 #endif
1044 }//end InitDualVarValue destructor
1045 
1046 
1048  numberOfCon (0)
1049 {
1050 #ifndef NDEBUG
1051  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside InitDualVariableValues Constructor");
1052 #endif
1053  con = NULL;
1054 }// end InitDualVariableValues constructor
1055 
1057 {
1058 #ifndef NDEBUG
1059  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "InitDualVariableValues Destructor Called");
1060 #endif
1061  if (con != NULL)
1062  {
1063  int i;
1064  for (i=0; i < numberOfCon; i++)
1065  {
1066  delete con[i];
1067  con[i] = NULL;
1068  }
1069  delete[] con;
1070  con = NULL;
1071  };
1072 }//end InitDualVariableValues destructor
1073 
1074 
1076  idx (0),
1077  name (""),
1078  value (""),
1079  lbValue (""),
1080  ubValue ("")
1081 {
1082 #ifndef NDEBUG
1083  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside OtherConOption Constructor");
1084 #endif
1085 }// end OtherConOption constructor
1086 
1088 {
1089 #ifndef NDEBUG
1090  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "OtherConOption Destructor Called");
1091 #endif
1092 }//end OtherConOption destructor
1093 
1094 
1096  numberOfCon(0),
1097  numberOfEnumerations(0),
1098  name (""),
1099  value (""),
1100  solver(""),
1101  category (""),
1102  type (""),
1103  description (""),
1104  conType (""),
1105  enumType ("")
1106 {
1107 #ifndef NDEBUG
1108  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside OtherConstraintOption Constructor");
1109 #endif
1110  con = NULL;
1111  enumeration = NULL;
1112 }// end OtherConstraintOption constructor
1113 
1115 {
1116 #ifndef NDEBUG
1117  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "OtherConstraintOption Destructor Called");
1118 #endif
1119  if (con != NULL)
1120  {
1121  for (int i=0; i < numberOfCon; i++)
1122  {
1123  if (con[i]!= NULL) delete con[i];
1124  con[i] = NULL;
1125  }
1126  delete[] con;
1127  con = NULL;
1128  }
1129  if (enumeration != NULL)
1130  {
1131  for (int i=0; i < numberOfEnumerations; i++)
1132  {
1133  delete enumeration[i];
1134  enumeration[i] = NULL;
1135  }
1136  delete[] enumeration;
1137  enumeration = NULL;
1138  }
1139 }//end OtherConstraintOption destructor
1140 
1141 
1143  numberOfOtherConstraintOptions (0)
1144 {
1145 #ifndef NDEBUG
1146  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside ConstraintOption Constructor");
1147 #endif
1148  initialConstraintValues = NULL;
1149  initialDualValues = NULL;
1150  initialBasisStatus = NULL;
1151  other = NULL;
1152 }// end ConstraintOption constructor
1153 
1155 {
1156 #ifndef NDEBUG
1157  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "ConstraintOption Destructor Called");
1158 #endif
1160  initialConstraintValues = NULL;
1161  if (initialDualValues != NULL) delete initialDualValues;
1162  initialDualValues = NULL;
1163  if (initialBasisStatus != NULL) delete initialBasisStatus;
1164  initialBasisStatus = NULL;
1165  if (other != NULL)
1166  {
1167  int i;
1168  for (i=0; i < numberOfOtherConstraintOptions; i++)
1169  {
1170  delete other[i];
1171  other[i] = NULL;
1172  }
1173  delete[] other;
1174  other = NULL;
1175  }
1176 }//end ConstraintOption destructor
1177 
1178 
1180  name (""),
1181  value (""),
1182  solver(""),
1183  category (""),
1184  type (""),
1185  description (""),
1186  numberOfItems(0),
1187  item(NULL)
1188 {
1189 #ifndef NDEBUG
1190  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside SolverOption Constructor");
1191 #endif
1192 }// end SolverOption constructor
1193 
1195 {
1196 #ifndef NDEBUG
1197  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "SolverOption Destructor Called");
1198 #endif
1199  if (item != NULL) delete[] item;
1200  item = NULL;
1201 }//end SolverOption destructor
1202 
1203 
1205  numberOfSolverOptions(0)
1206 {
1207 #ifndef NDEBUG
1208  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside SolverOptions Constructor");
1209 #endif
1210  solverOption = NULL;
1211 }// end SolverOptions constructor
1212 
1214 {
1215 #ifndef NDEBUG
1216  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "SolverOptions Destructor Called");
1217 #endif
1218  if (solverOption != NULL)
1219  {
1220  int i;
1221  for (i=0; i<numberOfSolverOptions; i++)
1222  {
1223  delete solverOption[i];
1224  solverOption[i] = NULL;
1225  }
1226  delete[] solverOption;
1227  solverOption = NULL;
1228  }
1229 }//end SolverOptions destructor
1230 
1231 
1233  numberOfVariables (-1),
1234  numberOfObjectives (-1),
1235  numberOfConstraints (-1)
1236 {
1237 #ifndef NDEBUG
1238  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside OptimizationOption Constructor");
1239 #endif
1240  variables = NULL;
1241  objectives = NULL;
1242  constraints = NULL;
1243  solverOptions = NULL;
1244 }// end OptimizationOption constructor
1245 
1247 {
1248 #ifndef NDEBUG
1249  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "OptimizationOption Destructor Called");
1250 #endif
1251  if (variables != NULL) delete variables;
1252  variables = NULL;
1253  if (objectives != NULL) delete objectives;
1254  objectives = NULL;
1255  if (constraints != NULL) delete constraints;
1256  constraints = NULL;
1257  if (solverOptions != NULL) delete solverOptions;
1258  solverOptions = NULL;
1259 }//end OptimizationOption destructor
1260 
1261 
1263 //(initializations)
1264 {
1265 #ifndef NDEBUG
1266  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Inside OSOption Constructor");
1267 #endif
1268 
1269  optionHeader = NULL;
1270  general = NULL;
1271  system = NULL;
1272  service = NULL;
1273  job = NULL;
1274  optimization = NULL;
1275  m_mdInitVarValuesDense = NULL;
1277  m_mdInitBasisStatusDense = NULL;
1279  m_mdInitObjValuesDense = NULL;
1282  m_mdInitConValuesDense = NULL;
1285 }// end OSOption constructor
1286 
1288 {
1289 #ifndef NDEBUG
1290  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "OSOption Destructor Called");
1291 #endif
1292  if (optionHeader != NULL) delete optionHeader;
1293  optionHeader = NULL;
1294  if (general != NULL) delete general;
1295  general = NULL;
1296  if (system != NULL) delete system;
1297  system = NULL;
1298  if (service != NULL) delete service;
1299  service = NULL;
1300  if (job != NULL) delete job;
1301  job = NULL;
1302  if (optimization != NULL) delete optimization;
1303  optimization = NULL;
1304 
1305  if (m_mdInitVarValuesDense != NULL)
1306  delete[] m_mdInitVarValuesDense;
1307  m_mdInitVarValuesDense = NULL;
1308 
1309  if (m_mdInitVarValuesStringDense != NULL)
1312 
1313  if (m_mdInitBasisStatusDense != NULL)
1314  delete[] m_mdInitBasisStatusDense;
1315  m_mdInitBasisStatusDense = NULL;
1316 
1320 
1321  if (m_mdInitObjValuesDense != NULL)
1322  delete[] m_mdInitObjValuesDense;
1323  m_mdInitObjValuesDense = NULL;
1324 
1325  if (m_mdInitObjLowerBoundsDense != NULL)
1326  delete[] m_mdInitObjLowerBoundsDense;
1328 
1329  if (m_mdInitObjUpperBoundsDense != NULL)
1330  delete[] m_mdInitObjUpperBoundsDense;
1332 
1333  if (m_mdInitConValuesDense != NULL)
1334  delete[] m_mdInitConValuesDense;
1335  m_mdInitConValuesDense = NULL;
1336 
1337  if (m_mdInitDualVarLowerBoundsDense != NULL)
1340 
1341  if (m_mdInitDualVarUpperBoundsDense != NULL)
1344 }//end OSOption destructor
1345 
1346 
1347 
1348 
1349 /****************************************************************
1350  * get() methods
1351  ****************************************************************/
1352 
1353 /***********************************
1354  * get() methods that return strings
1355  ***********************************/
1356 
1361 {
1362  if (this->optionHeader != NULL)
1363  return this->optionHeader->name;
1364 
1365  return "";
1366 }//getFileName
1367 
1372 {
1373  if (this->optionHeader != NULL)
1374  return this->optionHeader->source;
1375 
1376  return "";
1377 }//getFileSource
1378 
1383 {
1384  if (this->optionHeader != NULL)
1385  return this->optionHeader->description;
1386 
1387  return "";
1388 }//getFileDescription
1389 
1394 {
1395  if (this->optionHeader != NULL)
1396  return this->optionHeader->fileCreator;
1397 
1398  return "";
1399 }//getFileCreator
1400 
1405 {
1406  if (this->optionHeader != NULL)
1407  return this->optionHeader->licence;
1408 
1409  return "";
1410 }//getFileLicence
1411 
1412 
1417 {
1418  if (this->general != NULL)
1419  return this->general->serviceURI;
1420 
1421  return "";
1422 }//getServiceURI
1423 
1428 {
1429  if (this->general != NULL)
1430  return this->general->serviceName;
1431 
1432  return "";
1433 }//getServiceName
1434 
1439 {
1440  if (this->general != NULL)
1441  return this->general->instanceName;
1442 
1443  return "";
1444 }//getInstanceName
1445 
1450 {
1451  if (this->general != NULL)
1452  if (this->general->instanceLocation != NULL)
1453  return this->general->instanceLocation->value;
1454 
1455  return "";
1456 }//getInstanceLocation
1457 
1462 {
1463  if (this->general != NULL)
1464  if (this->general->instanceLocation != NULL)
1465  return this->general->instanceLocation->locationType;
1466 
1467  return "";
1468 }//getLocationType
1469 
1473 std::string OSOption::getJobID()
1474 {
1475  if (this->general != NULL)
1476  return this->general->jobID;
1477 
1478  return "";
1479 }//getJobID
1480 
1485 {
1486  if (this->general != NULL)
1487  return this->general->solverToInvoke;
1488 
1489  return "";
1490 }//getSolverToInvoke
1491 
1496 {
1497  if (this->general != NULL)
1498  return this->general->license;
1499 
1500  return "";
1501 }//getLicense
1502 
1507 {
1508  if (this->general != NULL)
1509  return this->general->userName;
1510 
1511  return "";
1512 }//getUserName
1513 
1518 {
1519  if (this->general != NULL)
1520  return this->general->password;
1521 
1522  return "";
1523 }//getPassword
1524 
1529 {
1530  if (this->general != NULL)
1531  if (this->general->contact != NULL)
1532  return this->general->contact->value;
1533 
1534  return "";
1535 }//getContact
1536 
1541 {
1542  if (this->general != NULL)
1543  if (this->general->contact != NULL)
1544  return this->general->contact->transportType;
1545 
1546  return "";
1547 }//getContactTransportType
1548 
1553 {
1554  if (this->system != NULL)
1555  if (this->system->minDiskSpace != NULL)
1556  return this->system->minDiskSpace->unit;
1557 
1558  return "";
1559 }//getMinDiskSpaceUnit
1560 
1565 {
1566  if (this->system != NULL)
1567  if (this->system->minDiskSpace != NULL)
1568  return this->system->minDiskSpace->description;
1569 
1570  return "";
1571 }//getMinDiskSpaceDescription
1572 
1577 {
1578  if (this->system != NULL)
1579  if (this->system->minMemorySize != NULL)
1580  return this->system->minMemorySize->unit;
1581 
1582  return "";
1583 }//getMinMemory
1584 
1589 {
1590  if (this->system != NULL)
1591  if (this->system->minMemorySize != NULL)
1592  return this->system->minMemorySize->description;
1593 
1594  return "";
1595 }//getMinMemoryDescription
1596 
1601 {
1602  if (this->system != NULL)
1603  if (this->system->minCPUSpeed != NULL)
1604  return this->system->minCPUSpeed->unit;
1605 
1606  return "";
1607 }//getMinCPUSpeed
1608 
1613 {
1614  if (this->system != NULL)
1615  if (this->system->minCPUSpeed != NULL)
1616  return this->system->minCPUSpeed->description;
1617 
1618  return "";
1619 }//getMinCPUSpeedDescription
1620 
1625 {
1626  if (this->system != NULL)
1627  if (this->system->minCPUNumber != NULL)
1628  return this->system->minCPUNumber->description;
1629 
1630  return "";
1631 }//getMinCPUNumberDescription
1632 
1637 {
1638  if (this->service != NULL)
1639  return this->service->type;
1640 
1641  return "";
1642 }//getServiceType
1643 
1648 {
1649  if (this->job != NULL)
1650  if (this->job->maxTime != NULL)
1651  return this->job->maxTime->unit;
1652 
1653  return "";
1654 }//getMaxTimeUnit
1655 
1660 {
1661  if (this->job != NULL)
1662  return this->job->requestedStartTime;
1663 
1664  return "";
1665 }//getRequestedStartTime
1666 
1673 std::string OSOption::getOptionStr(std::string optionName)
1674 {
1675  if (optionName == "serviceURI")
1676  return this->getServiceURI();
1677 
1678  if (optionName == "serviceName")
1679  return this->getServiceName();
1680 
1681  if (optionName == "instanceName")
1682  return this->getInstanceName();
1683 
1684  if (optionName == "instanceLocation")
1685  return this->getInstanceLocation();
1686 
1687  if (optionName == "instanceLocationType")
1688  return this->getInstanceLocationType();
1689 
1690  if (optionName == "jobID")
1691  return this->getJobID();
1692 
1693  if (optionName == "solverToInvoke")
1694  return this->getSolverToInvoke();
1695 
1696  if (optionName == "license")
1697  return this->getLicense();
1698 
1699  if (optionName == "userName")
1700  return this->getUserName();
1701 
1702  if (optionName == "password")
1703  return this->getPassword();
1704 
1705  if (optionName == "contact")
1706  return this->getContact();
1707 
1708  if (optionName == "contactTransportType")
1709  return this->getContactTransportType();
1710 
1711  if (optionName == "minDiskSpaceUnit")
1712  return this->getMinDiskSpaceUnit();
1713 
1714  if (optionName == "minMemoryUnit")
1715  return this->getMinMemoryUnit();
1716 
1717  if (optionName == "minCPUSpeedUnit")
1718  return this->getMinCPUSpeedUnit();
1719 
1720  if (optionName == "serviceType")
1721  return this->getServiceType();
1722 
1723  if (optionName == "maxTimeUnit")
1724  return this->getMaxTimeUnit();
1725 
1726  if (optionName == "requestedStartTime")
1727  return this->getRequestedStartTime();
1728 
1729  return "";
1730 }//getOptionStr
1731 
1732 /***********************************
1733  * get() methods that return doubles
1734  ***********************************/
1735 
1740 {
1741  if (this->system != NULL)
1742  if (this->system->minDiskSpace != NULL)
1743  return this->system->minDiskSpace->value;
1744 
1745  return 0;
1746 }//getMinDiskSpace
1747 
1752 {
1753  if (this->system != NULL)
1754  if (this->system->minMemorySize != NULL)
1755  return this->system->minMemorySize->value;
1756 
1757  return 0;
1758 }//getMinMemorySize
1759 
1764 {
1765  if (this->system != NULL)
1766  if (this->system->minCPUSpeed != NULL)
1767  return this->system->minCPUSpeed->value;
1768 
1769  return 0;
1770 }//getMinCPUSpeed
1771 
1776 {
1777  if (this->job != NULL)
1778  if (this->job->maxTime != NULL)
1779  return job->maxTime->value;
1780 
1781  return 0;
1782 }//getMaxTime
1783 
1790 double OSOption::getOptionDbl(std::string optionName)
1791 {
1792  if (optionName == "minDiskSpace")
1793  return this->getMinDiskSpace();
1794 
1795  if (optionName == "minMemory")
1796  return this->getMinMemorySize();
1797 
1798  if (optionName == "minCPUSpeed")
1799  return this->getMinCPUSpeed();
1800 
1801  if (optionName == "maxTime")
1802  return this->getMaxTime();
1803 
1804  return 0;
1805 }//getOptionDbl
1806 
1815 {
1816  if (this->system != NULL)
1817  return this->system->minCPUNumber->value;
1818 
1819  return 0;
1820 }//getMinCPUNumber
1821 
1826 {
1827  if (this->general != NULL)
1828  if (this->general->otherOptions != NULL)
1829  return this->general->otherOptions->numberOfOtherOptions;
1830 
1831  return 0;
1832 }//getNumberOfOtherGeneralOptions
1833 
1838 {
1839  if (this->system != NULL)
1840  if (this->system->otherOptions != NULL)
1841  return this->system->otherOptions->numberOfOtherOptions;
1842 
1843  return 0;
1844 }//getNumberOfOtherSystemOptions
1845 
1850 {
1851  if (this->service != NULL)
1852  if (this->service->otherOptions != NULL)
1853  return this->service->otherOptions->numberOfOtherOptions;
1854 
1855  return 0;
1856 }//getNumberOfOtherServiceOptions
1857 
1862 {
1863  if (this->job != NULL)
1864  if (this->job->otherOptions != NULL)
1865  return this->job->otherOptions->numberOfOtherOptions;
1866 
1867  return 0;
1868 }//getNumberOfOtherJobOptions
1869 
1874 {
1875  if (this->job != NULL)
1876  if (this->job->dependencies != NULL)
1877  return this->job->dependencies->numberOfJobIDs;
1878 
1879  return 0;
1880 }//getNumberOfJobDependencies
1881 
1886 {
1887  if (this->job != NULL)
1888  if (this->job->requiredDirectories != NULL)
1889  return this->job->requiredDirectories->numberOfPaths;
1890 
1891  return 0;
1892 }//getNumberOfRequiredDirectories
1893 
1898 {
1899  if (this->job != NULL)
1900  if (this->job->requiredFiles != NULL)
1901  return this->job->requiredFiles->numberOfPaths;
1902 
1903  return 0;
1904 }//getNumberOfRequiredFiles
1905 
1910 {
1911  if (this->job != NULL)
1912  if (this->job->directoriesToMake != NULL)
1913  return this->job->directoriesToMake->numberOfPaths;
1914 
1915  return 0;
1916 }//getNumberOfDirectoriesToMake
1917 
1922 {
1923  if (this->job != NULL)
1924  if (this->job->filesToMake != NULL)
1925  return this->job->filesToMake->numberOfPaths;
1926 
1927  return 0;
1928 }//getNumberOfFilesToMake
1929 
1934 {
1935  if (this->job != NULL)
1936  if (this->job->inputDirectoriesToMove != NULL)
1938 
1939  return 0;
1940 }//getNumberOfInputDirectoriesToMove
1941 
1946 {
1947  if (this->job != NULL)
1948  if (this->job->inputFilesToMove != NULL)
1949  return this->job->inputFilesToMove->numberOfPathPairs;
1950 
1951  return 0;
1952 }//getNumberOfInputFilesToMove
1953 
1958 {
1959  if (this->job != NULL)
1960  if (this->job->outputDirectoriesToMove != NULL)
1962 
1963  return 0;
1964 }//getNumberOfOutputDirectoriesToMove
1965 
1970 {
1971  if (this->job != NULL)
1972  if (this->job->outputFilesToMove != NULL)
1973  return this->job->outputFilesToMove->numberOfPathPairs;
1974 
1975  return 0;
1976 }//getNumberOfOutputFilesToMove
1977 
1982 {
1983  if (this->job != NULL)
1984  if (this->job->filesToDelete != NULL)
1985  return this->job->filesToDelete->numberOfPaths;
1986 
1987  return 0;
1988 }//getNumberOfFilesToDelete
1989 
1994 {
1995  if (this->job != NULL)
1996  if (this->job->directoriesToDelete != NULL)
1997  return this->job->directoriesToDelete->numberOfPaths;
1998 
1999  return 0;
2000 }//getNumberOfDirectoriesToDelete
2001 
2006 {
2007  if (this->job != NULL)
2008  if (this->job->processesToKill != NULL)
2009  return this->job->processesToKill->numberOfProcesses;
2010 
2011  return 0;
2012 }//getNumberOfProcessesToKill
2013 
2018 {
2019  if (this->optimization != NULL)
2020  return this->optimization->numberOfVariables;
2021 
2022  return -1;
2023 }//getNumberOfVariables
2024 
2029 {
2030  if (this->optimization != NULL)
2031  return this->optimization->numberOfObjectives;
2032 
2033  return -1;
2034 }//getNumberOfObjectives
2035 
2040 {
2041  if (this->optimization != NULL)
2042  return this->optimization->numberOfConstraints;
2043 
2044  return -1;
2045 }//getNumberOfConstraints
2046 
2047 
2052 {
2053  if (this->optimization != NULL)
2054  {
2055  if (this->optimization->variables != NULL)
2056  {
2057  if (this->optimization->variables->initialVariableValues != NULL)
2058  {
2060  }
2061  }
2062  }
2063  return -1;
2064 }//getNumberOfInitVarValues
2065 
2070 {
2071  if (this->optimization != NULL)
2072  if (this->optimization->variables != NULL)
2075  return -1;
2076 }//getNumberOfInitVarValuesString
2077 
2078 
2083 {
2084  if (this->optimization != NULL)
2085  if (this->optimization->variables != NULL)
2088  return -1;
2089 }//getNumberOfIntegerBranchingWeights
2090 
2095 {
2096  if (this->optimization != NULL)
2097  if (this->optimization->variables != NULL)
2100  return -1;
2101 }//getNumberOfSOS
2102 
2107 {
2108  if (this->optimization != NULL)
2109  if (this->optimization->variables != NULL)
2111  {
2112  if (iSOS >= 0 && iSOS < this->optimization->variables->sosVariableBranchingWeights->numberOfSOS)
2113  if (this->optimization->variables->sosVariableBranchingWeights->sos[iSOS] != NULL)
2115  }
2116  return -1;
2117 }//getNumberOfSOSVarBranchingWeights
2118 
2123 {
2124  if (this->optimization != NULL)
2125  if (this->optimization->variables != NULL)
2127 
2128  return 0;
2129 }//getNumberOfOtherVariableOptions
2130 
2135 {
2136  if (this->optimization != NULL)
2137  if (this->optimization->objectives != NULL)
2138  if (this->optimization->objectives->initialObjectiveValues != NULL)
2140 
2141  return -1;
2142 }//getNumberOfInitObjValues
2143 
2148 {
2149  if (this->optimization != NULL)
2150  if (this->optimization->objectives != NULL)
2151  if (this->optimization->objectives->initialObjectiveBounds != NULL)
2153  return -1;
2154 }//getNumberOfInitObjBounds
2155 
2160 {
2161  if (this->optimization != NULL)
2162  if (this->optimization->objectives != NULL)
2164  return 0;
2165 }//getNumberOfOtherObjectiveOptions
2166 
2171 {
2172  if (this->optimization != NULL)
2173  if (this->optimization->constraints != NULL)
2174  if (this->optimization->constraints->initialConstraintValues != NULL)
2176  return -1;
2177 }//getNumberOfInitConValues
2178 
2183 {
2184  if (this->optimization != NULL)
2185  if (this->optimization->constraints != NULL)
2186  if (this->optimization->constraints->initialDualValues != NULL)
2188 
2189  return -1;
2190 }//getNumberOfInitDualVarValues
2191 
2196 {
2197  if (this->optimization != NULL)
2198  if (this->optimization->constraints != NULL)
2200 
2201  return -1;
2202 }//getNumberOfOtherConstraintOptions
2203 
2208 {
2209  if (this->optimization != NULL)
2210  if (this->optimization->solverOptions != NULL)
2212 
2213  return -1;
2214 }//getNumberOfSolverOptions
2215 
2222 int OSOption::getOptionInt(std::string optionName)
2223 {
2224  if (optionName == "minCPUNumber")
2225  return this->getMinCPUNumber();
2226 
2227  if (optionName == "numberOfOtherGeneralOptions")
2228  return this->getNumberOfOtherGeneralOptions();
2229 
2230  if (optionName == "numberOfOtherSystemOptions")
2231  return this->getNumberOfOtherSystemOptions();
2232 
2233  if (optionName == "numberOfOtherServiceOptions")
2234  return this->getNumberOfOtherServiceOptions();
2235 
2236  if (optionName == "numberOfOtherJobOptions")
2237  return this->getNumberOfOtherJobOptions();
2238 
2239  if (optionName == "numberOfJobDependencies")
2240  return this->getNumberOfJobDependencies();
2241 
2242  if (optionName == "numberOfRequiredDirectories")
2243  return this->getNumberOfRequiredDirectories();
2244 
2245  if (optionName == "numberOfRequiredFiles")
2246  return this->getNumberOfRequiredFiles();
2247 
2248  if (optionName == "numberOfDirectoriesToMake")
2249  return this->getNumberOfDirectoriesToMake();
2250 
2251  if (optionName == "numberOfFilesToMake")
2252  return this->getNumberOfFilesToMake();
2253 
2254  if (optionName == "numberOfInputDirectoriesToMove")
2255  return this->getNumberOfInputDirectoriesToMove();
2256 
2257  if (optionName == "numberOfInputFilesToMove")
2258  return this->getNumberOfInputFilesToMove();
2259 
2260  if (optionName == "numberOfOutputDirectoriesToMove")
2261  return this->getNumberOfOutputDirectoriesToMove();
2262 
2263  if (optionName == "numberOfOutputFilesToMove")
2264  return this->getNumberOfOutputFilesToMove();
2265 
2266  if (optionName == "numberOfFilesToDelete")
2267  return this->getNumberOfFilesToDelete();
2268 
2269  if (optionName == "numberOfDirectoriesToDelete")
2270  return this->getNumberOfDirectoriesToDelete();
2271 
2272  if (optionName == "numberOfProcessesToKill")
2273  return this->getNumberOfProcessesToKill();
2274 
2275  if (optionName == "numberOfVariables")
2276  return this->getNumberOfVariables();
2277 
2278  if (optionName == "numberOfObjectives")
2279  return this->getNumberOfObjectives();
2280 
2281  if (optionName == "numberOfConstraints")
2282  return this->getNumberOfConstraints();
2283 
2284  if (optionName == "numberOfInitVarValues")
2285  return this->getNumberOfInitVarValues();
2286 
2287  if (optionName == "numberOfInitVarValuesString")
2288  return this->getNumberOfInitVarValuesString();
2289 
2290  if (optionName == "numberOfIntegerVariableBranchingWeights")
2292 
2293  if (optionName == "numberOfSOS")
2294  return this->getNumberOfSOS();
2295 
2296  if (optionName == "numberOfOtherVariableOptions")
2297  return this->getNumberOfOtherVariableOptions();
2298 
2299  if (optionName == "numberOfInitObjValues")
2300  return this->getNumberOfInitObjValues();
2301 
2302  if (optionName == "numberOfInitObjBounds")
2303  return this->getNumberOfInitObjBounds();
2304 
2305  if (optionName == "numberOfOtherObjectiveOptions")
2306  return this->getNumberOfOtherObjectiveOptions();
2307 
2308  if (optionName == "numberOfInitConValues")
2309  return this->getNumberOfInitConValues();
2310 
2311  if (optionName == "numberOfInitDualVarValues")
2312  return this->getNumberOfInitDualVarValues();
2313 
2314  if (optionName == "numberOfOtherConstraintOptions")
2315  return this->getNumberOfOtherConstraintOptions();
2316 
2317  if (optionName == "numberOfSolverOptions")
2318  return this->getNumberOfSolverOptions();
2319 
2320  return -1;
2321 }//getOptionInt
2322 
2323 
2324 /****************************************************
2325  * get() methods that return arrays of various kinds
2326  ****************************************************/
2327 
2332 {
2333  if (this->general != NULL)
2334  {
2335  if (this->general->otherOptions != NULL)
2336  return this->general->otherOptions->other;
2337  }
2338  return NULL;
2339 }//getOtherGeneralOptions
2340 
2345 {
2346  if (this->system != NULL)
2347  {
2348  if (this->system->otherOptions != NULL)
2349  return this->system->otherOptions->other;
2350  }
2351  return NULL;
2352 }//getOtherSystemOptions
2353 
2358 {
2359  if (this->service != NULL)
2360  {
2361  if (this->service->otherOptions != NULL)
2362  return this->service->otherOptions->other;
2363  }
2364  return NULL;
2365 }//getOtherServiceOptions
2366 
2371 {
2372  if (this->job != NULL)
2373  {
2374  if (this->job->otherOptions != NULL)
2375  return this->job->otherOptions->other;
2376  }
2377  return NULL;
2378 }//getOtherJobOptions
2379 
2387 {
2388  if (category == "general")
2389  return this->getOtherGeneralOptions();
2390 
2391  if (category == "system")
2392  return this->getOtherSystemOptions();
2393 
2394  if (category == "service")
2395  return this->getOtherServiceOptions();
2396 
2397  if (category == "job")
2398  return this->getOtherJobOptions();
2399 
2400  return NULL;
2401 }//getOtherOptions
2402 
2407 {
2408  OtherOption** optionVector = NULL;
2409  int prev_options[4];
2410  int num_options[4];
2411  int num_opt;
2412  int i;
2413 
2414  for (i = 0; i < 4; i++)
2415  {
2416  prev_options[i] = 0;
2417  num_options[i] = 0;
2418  }
2419  if (this->general != NULL)
2420  {
2421  if (this->general->otherOptions != NULL)
2422  {
2423  num_opt = this->getNumberOfOtherGeneralOptions();
2424  num_options[0] = num_opt;
2425  }
2426  }
2427 
2428  if (this->system != NULL)
2429  {
2430  if (this->system->otherOptions != NULL)
2431  {
2432  num_opt = this->getNumberOfOtherSystemOptions();
2433  num_options[1] = num_opt;
2434  }
2435  }
2436  prev_options[1] = prev_options[0] + num_options[0];
2437 
2438  if (this->service != NULL)
2439  {
2440  if (this->service->otherOptions != NULL)
2441  {
2442  num_opt = this->getNumberOfOtherServiceOptions();
2443  num_options[2] = num_opt;
2444  }
2445  }
2446  prev_options[2] = prev_options[1] + num_options[1];
2447 
2448  if (this->job != NULL)
2449  {
2450  if (this->job->otherOptions != NULL)
2451  {
2452  num_opt = this->getNumberOfOtherJobOptions();
2453  num_options[3] = num_opt;
2454  }
2455  }
2456  prev_options[3] = prev_options[2] + num_options[2];
2457 
2458  num_opt = num_options[0] + num_options[1] + num_options[2] + num_options[3];
2459  optionVector = new OtherOption*[num_opt];
2460 
2461  if (num_options[0] > 0)
2462  {
2463  for (i = 0; i < num_options[0]; i++)
2464  {
2465  optionVector[prev_options[0] + i] = this->general->otherOptions->other[i];
2466  }
2467  }
2468 
2469  if (num_options[1] > 0)
2470  {
2471  for (i = 0; i < num_options[1]; i++)
2472  {
2473  optionVector[prev_options[1] + i] = this->system->otherOptions->other[i];
2474  }
2475  }
2476 
2477  if (num_options[2] > 0)
2478  {
2479  for (i = 0; i < num_options[2]; i++)
2480  {
2481  optionVector[prev_options[2] + i] = this->service->otherOptions->other[i];
2482  }
2483  }
2484 
2485  if (num_options[3] > 0)
2486  {
2487  for (i = 0; i < num_options[3]; i++)
2488  {
2489  optionVector[prev_options[3] + i] = this->job->otherOptions->other[i];
2490  }
2491  }
2492 
2493  return optionVector;
2494 }//getOtherJobOptions
2495 
2500 {
2501  std::string* dependenciesVector = NULL;
2502  if (this->job != NULL)
2503  {
2504  if (this->job->dependencies != NULL)
2505  dependenciesVector = this->job->dependencies->jobID;
2506  else
2507  throw ErrorClass("<dependencies> object must be defined before getting the jobIDs");
2508  }
2509  else
2510  throw ErrorClass("<job> object must be defined before getting the jobIDs");
2511 
2512  return dependenciesVector;
2513 }//getJobDependencies
2514 
2519 {
2520  std::string* pathVector = NULL;
2521  if (this->job != NULL)
2522  {
2523  if (this->job->requiredDirectories != NULL)
2524  pathVector = this->job->requiredDirectories->path;
2525  else
2526  throw ErrorClass("<requiredDirectories> object must be defined before getting the paths");
2527  }
2528  else
2529  throw ErrorClass("<job> object must be defined before getting the paths");
2530  return pathVector;
2531 }//getRequiredDirectories
2532 
2537 {
2538  std::string* pathVector = NULL;
2539  if (this->job != NULL)
2540  {
2541  if (this->job->requiredFiles != NULL)
2542  pathVector = this->job->requiredFiles->path;
2543  else
2544  throw ErrorClass("<requiredFiles> object must be defined before getting the paths");
2545  }
2546  else
2547  throw ErrorClass("<job> object must be defined before getting the paths");
2548  return pathVector;
2549 }//getRequiredFiles
2550 
2555 {
2556  std::string* pathVector = NULL;
2557  if (this->job != NULL)
2558  {
2559  if (this->job->directoriesToMake != NULL)
2560  pathVector = this->job->directoriesToMake->path;
2561  else
2562  throw ErrorClass("<directoriesToMake> object must be defined before getting the paths");
2563  }
2564  else
2565  throw ErrorClass("<job> object must be defined before getting the paths");
2566  return pathVector;
2567 }//getDirectoriesToMake
2568 
2573 {
2574  std::string* pathVector = NULL;
2575  if (this->job != NULL)
2576  {
2577  if (this->job->filesToMake != NULL)
2578  pathVector = this->job->filesToMake->path;
2579  else
2580  throw ErrorClass("<filesToMake> object must be defined before getting the paths");
2581  }
2582  else
2583  throw ErrorClass("<job> object must be defined before getting the paths");
2584  return pathVector;
2585 }//getFilesToMake
2586 
2591 {
2592  PathPair** pathPairVector = NULL;
2593  if (this->job != NULL)
2594  {
2595  if (this->job->inputDirectoriesToMove != NULL)
2596  pathPairVector = this->job->inputDirectoriesToMove->pathPair;
2597  else
2598  throw ErrorClass("<inputDirectoriesToMove> object must be defined before getting the paths");
2599  }
2600  else
2601  throw ErrorClass("<job> object must be defined before getting the paths");
2602  return pathPairVector;
2603 }//getInputDirectoriesToMove
2604 
2609 {
2610  PathPair** pathPairVector = NULL;
2611  if (this->job != NULL)
2612  {
2613  if (this->job->inputFilesToMove != NULL)
2614  pathPairVector = this->job->inputFilesToMove->pathPair;
2615  else
2616  throw ErrorClass("<inputFilesToMove> object must be defined before getting the paths");
2617  }
2618  else
2619  throw ErrorClass("<job> object must be defined before getting the paths");
2620  return pathPairVector;
2621 }//getInputFilesToMove
2622 
2627 {
2628  PathPair** pathPairVector = NULL;
2629  if (this->job != NULL)
2630  {
2631  if (this->job->outputFilesToMove != NULL)
2632  pathPairVector = this->job->outputFilesToMove->pathPair;
2633  else
2634  throw ErrorClass("<outputFilesToMove> object must be defined before getting the paths");
2635  }
2636  else
2637  throw ErrorClass("<job> object must be defined before getting the paths");
2638  return pathPairVector;
2639 }//getOutputFilesToMove
2640 
2645 {
2646  PathPair** pathPairVector = NULL;
2647  if (this->job != NULL)
2648  {
2649  if (this->job->outputDirectoriesToMove != NULL)
2650  pathPairVector = this->job->outputDirectoriesToMove->pathPair;
2651  else
2652  throw ErrorClass("<outputDirectoriesToMove> object must be defined before getting the paths");
2653  }
2654  else
2655  throw ErrorClass("<job> object must be defined before getting the paths");
2656  return pathPairVector;
2657 }//getOutputDirectoriesToMove
2658 
2663 {
2664  std::string* pathVector = NULL;
2665  if (this->job != NULL)
2666  {
2667  if (this->job->filesToDelete != NULL)
2668  pathVector = this->job->filesToDelete->path;
2669  else
2670  throw ErrorClass("<filesToDelete> object must be defined before getting the paths");
2671  }
2672  else
2673  throw ErrorClass("<job> object must be defined before getting the paths");
2674  return pathVector;
2675 }//getFilesToDelete
2676 
2681 {
2682  std::string* pathVector = NULL;
2683  if (this->job != NULL)
2684  {
2685  if (this->job->directoriesToDelete != NULL)
2686  pathVector = this->job->directoriesToDelete->path;
2687  else
2688  throw ErrorClass("<directoriesToDelete> object must be defined before getting the paths");
2689  }
2690  else
2691  throw ErrorClass("<job> object must be defined before getting the paths");
2692  return pathVector;
2693 }//getDirectoriesToDelete
2694 
2699 {
2700  std::string* processes = NULL;
2701  if (this->job != NULL)
2702  {
2703  if (this->job->processesToKill != NULL)
2704  processes = this->job->processesToKill->process;
2705  else
2706  throw ErrorClass("<processesToKill> object must be defined before getting the processes");
2707  }
2708  else
2709  throw ErrorClass("<job> object must be defined before getting the processes");
2710  return processes;
2711 }//getProcessesToKill
2712 
2713 
2714 
2720 {
2721  InitVarValue** initVarVector;
2722  if (this->optimization != NULL)
2723  {
2724  if (this->optimization->variables != NULL)
2725  {
2726  if (this->optimization->variables->initialVariableValues != NULL)
2727  initVarVector = this->optimization->variables->initialVariableValues->var;
2728  else
2729  throw ErrorClass("<initialVariableValues> object must be defined before getting the data");
2730  }
2731  else
2732  throw ErrorClass("<variables> object must be defined before getting the data");
2733  }
2734  else
2735  throw ErrorClass("<optimization> object must be defined before getting the data");
2736  return initVarVector;
2737 }//getInitVarValuesSparse
2738 
2745 {
2746  try
2747  {
2748  int numberOfVariables;
2749  numberOfVariables = this->getNumberOfVariables();
2750  if (numberOfVariables < 0)
2751  throw ErrorClass("\"numberOfVariables\" must be present to use dense methods");
2752 
2753  if (this->optimization != NULL)
2754  {
2755  if (this->optimization->variables != NULL)
2756  {
2757  if (this->optimization->variables->initialVariableValues != NULL)
2758  {
2759  int i,j,k;
2760  int num_var;
2761  num_var = this->getNumberOfInitVarValues();
2762 
2763  if (m_mdInitVarValuesDense != NULL)
2764  delete [] m_mdInitVarValuesDense;
2765  m_mdInitVarValuesDense = new double[numberOfVariables];
2766  for (k = 0; k < numberOfVariables; k++) m_mdInitVarValuesDense[k] = OSNaN();
2767 
2768  for (i = 0; i < num_var; i++)
2769  {
2771  if (j >= 0 && j < numberOfVariables)
2774  else
2775  throw ErrorClass("Variable index out of range");
2776  }
2777  return m_mdInitVarValuesDense;
2778  }
2779  }
2780  }
2781  }
2782  catch(const ErrorClass& eclass)
2783  {
2784  throw ErrorClass(eclass.errormsg);
2785  }
2786  return NULL;
2787 }//getInitVarValuesDense
2788 
2795 double* OSOption::getInitVarValuesDense(int numberOfVariables)
2796 {
2797  try
2798  {
2799  if (numberOfVariables < 0)
2800  throw ErrorClass("\"numberOfVariables\" must be present to use dense methods");
2801 
2802  if (this->optimization != NULL)
2803  {
2804  if (this->optimization->variables != NULL)
2805  {
2806  if (this->optimization->variables->initialVariableValues != NULL)
2807  {
2808  int i,j,k;
2809 
2810 
2811 
2812 
2813 
2814 
2815 
2816  int num_var;
2817  num_var = this->getNumberOfInitVarValues();
2818 
2819  if (m_mdInitVarValuesDense != NULL)
2820  delete [] m_mdInitVarValuesDense;
2821  m_mdInitVarValuesDense = new double[numberOfVariables];
2822  for (k = 0; k < numberOfVariables; k++) m_mdInitVarValuesDense[k] = OSNaN();
2823 
2824  for (i = 0; i < num_var; i++)
2825  {
2827  if (j >= 0 && j < numberOfVariables)
2830  else
2831  throw ErrorClass("Variable index out of range");
2832  }
2833  return m_mdInitVarValuesDense;
2834  }
2835  }
2836  }
2837  }
2838  catch(const ErrorClass& eclass)
2839  {
2840  throw ErrorClass(eclass.errormsg);
2841  }
2842  return NULL;
2843 }//getInitVarValuesDense
2844 
2850 {
2851  InitVarValueString** initVarVector;
2852  if (this->optimization != NULL)
2853  {
2854  if (this->optimization->variables != NULL)
2855  {
2857  initVarVector = this->optimization->variables->initialVariableValuesString->var;
2858  else
2859  throw ErrorClass("<initialVariableValuesString> object must be defined before getting the data");
2860  }
2861  else
2862  throw ErrorClass("<variables> object must be defined before getting the data");
2863  }
2864  else
2865  throw ErrorClass("<optimization> object must be defined before getting the data");
2866  return initVarVector;
2867 }//getInitVarValuesStringSparse
2868 
2875 {
2876  try
2877  {
2878  int numberOfVariables;
2879  numberOfVariables = this->getNumberOfVariables();
2880  if (numberOfVariables < 0)
2881  throw ErrorClass("\"numberOfVariables\" must be present to use dense methods");
2882 
2883  if (this->optimization != NULL)
2884  {
2885  if (this->optimization->variables != NULL)
2886  {
2888  {
2889  int i,j,k;
2890  int num_var;
2891  num_var = this->getNumberOfInitVarValuesString();
2892 
2893  if (m_mdInitVarValuesStringDense != NULL)
2894  delete [] m_mdInitVarValuesStringDense;
2895  m_mdInitVarValuesStringDense = new std::string[numberOfVariables];
2896  for (k = 0; k < numberOfVariables; k++) m_mdInitVarValuesStringDense[k] = "";
2897 
2898  for (i = 0; i < num_var; i++)
2899  {
2901  if (j >= 0 && j < numberOfVariables)
2904  else
2905  throw ErrorClass("Variable index out of range");
2906  }
2908  }
2909  }
2910  }
2911  }
2912  catch(const ErrorClass& eclass)
2913  {
2914  throw ErrorClass(eclass.errormsg);
2915  }
2916  return NULL;
2917 }//getInitVarValuesStringDense
2918 
2969 {
2970  try
2971  {
2972  if (numberOfVariables < 0)
2973  throw ErrorClass("\"numberOfVariables\" must be set to use dense methods");
2974 
2975  if (this->optimization == NULL)
2976  throw ErrorClass("<optimization> element was never set");
2977 
2978  if (this->optimization->variables == NULL)
2979  throw ErrorClass("<optimization> <variables> element was never set");
2980 
2981  if (this->optimization->variables->initialBasisStatus == NULL)
2982  throw ErrorClass("initial basis was never set");
2983 
2984  int i,j,k;
2985 
2986  if (m_mdInitBasisStatusDense != NULL)
2987  delete [] m_mdInitBasisStatusDense;
2988  m_mdInitBasisStatusDense = new int[numberOfVariables];
2989  for (k = 0; k < numberOfVariables; k++) m_mdInitBasisStatusDense[k] = ENUM_BASIS_STATUS_unknown;
2990 
2991  int num_var;
2992 
2993 
2994  if (this->optimization->variables->initialBasisStatus->basic != NULL)
2995  {
2997  for (i = 0; i < num_var; i++)
2998  {
3000  if (j >= 0 && j < numberOfVariables)
3002  else
3003  throw ErrorClass("Variable index out of range");
3004  }
3005  }
3006 
3007  if (this->optimization->variables->initialBasisStatus->atLower != NULL)
3008  {
3010  for (i = 0; i < num_var; i++)
3011  {
3013  if (j >= 0 && j < numberOfVariables)
3015  else
3016  throw ErrorClass("Variable index out of range");
3017  }
3018  }
3019 
3020  if (this->optimization->variables->initialBasisStatus->atUpper != NULL)
3021  {
3023 
3024 
3025 
3026  for (i = 0; i < num_var; i++)
3027  {
3029  if (j >= 0 && j < numberOfVariables)
3031  else
3032  throw ErrorClass("Variable index out of range");
3033  }
3034  }
3035 
3036  if (this->optimization->variables->initialBasisStatus->isFree != NULL)
3037  {
3039  for (i = 0; i < num_var; i++)
3040  {
3042  if (j >= 0 && j < numberOfVariables)
3044  else
3045  throw ErrorClass("Variable index out of range");
3046  }
3047  }
3048 
3049  if (this->optimization->variables->initialBasisStatus->superbasic != NULL)
3050  {
3052  for (i = 0; i < num_var; i++)
3053  {
3055  if (j >= 0 && j < numberOfVariables)
3057  else
3058  throw ErrorClass("Variable index out of range");
3059  }
3060  }
3061 
3062  return m_mdInitBasisStatusDense;
3063  }
3064 
3065  catch(const ErrorClass& eclass)
3066  {
3067  throw ErrorClass(eclass.errormsg);
3068  }
3069  return NULL;
3070 }//getVariableInitialBasisStatusDense
3071 
3072 
3074 {
3075  if (this->optimization == NULL)
3076  throw ErrorClass("<optimization> element was never set");
3077 
3078  switch (type)
3079  {
3081  {
3082  if (this->optimization->variables == NULL)
3083  throw ErrorClass("<optimization> <variables> element was never set");
3084 
3085  if (this->optimization->variables->initialBasisStatus == NULL)
3086  throw ErrorClass("initial basis was never set");
3087 
3088  return this->optimization->variables->initialBasisStatus->getNumberOfEl(status);
3089  }
3091  {
3092  if (this->optimization->objectives == NULL)
3093  throw ErrorClass("<optimization> <objectives> element was never set");
3094 
3095  if (this->optimization->objectives->initialBasisStatus == NULL)
3096  throw ErrorClass("initial basis was never set");
3097 
3098  return this->optimization->objectives->initialBasisStatus->getNumberOfEl(status);
3099  }
3101  {
3102  if (this->optimization->constraints == NULL)
3103  throw ErrorClass("<optimization> <constraints> element was never set");
3104 
3105  if (this->optimization->constraints->initialBasisStatus == NULL)
3106  throw ErrorClass("initial basis was never set");
3107 
3108  return this->optimization->constraints->initialBasisStatus->getNumberOfEl(status);
3109  }
3110  default:
3111  throw ErrorClass("target object not implemented in getNumberOfInitialBasisElements");
3112  }
3113 }//getNumberOfInitialBasisElements
3114 
3115 bool OSOption::getInitialBasisElements(int type, int status, int* elem)
3116 {
3117  if (this->optimization == NULL)
3118  throw ErrorClass("<optimization> element was never set");
3119 
3120  switch (type)
3121  {
3123  {
3124  if (this->optimization->variables == NULL)
3125  throw ErrorClass("<optimization> <variables> element was never set");
3126 
3127  if (this->optimization->variables->initialBasisStatus == NULL)
3128  throw ErrorClass("initial basis was never set");
3129 
3130  return this->optimization->variables->initialBasisStatus->getIntVector(status, elem);
3131  }
3133  {
3134  if (this->optimization->objectives == NULL)
3135  throw ErrorClass("<optimization> <objectives> element was never set");
3136 
3137  if (this->optimization->objectives->initialBasisStatus == NULL)
3138  throw ErrorClass("initial basis was never set");
3139 
3140  return this->optimization->objectives->initialBasisStatus->getIntVector(status, elem);
3141  }
3143  {
3144  if (this->optimization->constraints == NULL)
3145  throw ErrorClass("<optimization> <constraints> element was never set");
3146 
3147  if (this->optimization->constraints->initialBasisStatus == NULL)
3148  throw ErrorClass("initial basis was never set");
3149 
3150  return this->optimization->constraints->initialBasisStatus->getIntVector(status, elem);
3151  }
3152  default:
3153  throw ErrorClass("target object not implemented in getInitialBasisElements");
3154  }
3155 }//getInitialBasisElements
3156 
3157 
3158 
3159 
3165 {
3166  BranchingWeight** intVarVector;
3167  if (this->optimization != NULL)
3168  {
3169  if (this->optimization->variables != NULL)
3170  {
3173  else
3174  throw ErrorClass("<integerVariableBranchingWeights> object must be defined before getting the data");
3175  }
3176  else
3177  throw ErrorClass("<variables> object must be defined before getting the data");
3178  }
3179  else
3180  throw ErrorClass("<optimization> object must be defined before getting the data");
3181  return intVarVector;
3182 }//getIntegerVariableBranchingWeightsSparse
3183 
3184 
3191 {
3192  try
3193  {
3194  int numberOfVariables;
3195  numberOfVariables = this->getNumberOfVariables();
3196  if (numberOfVariables < 0)
3197  throw ErrorClass("\"numberOfVariables\" must be present to use dense methods");
3198 
3199  if (this->optimization != NULL)
3200  {
3201  if (this->optimization->variables != NULL)
3202  {
3204  {
3205  int i,j,k;
3206  int num_var;
3208 
3211  m_mdIntegerVariableBranchingWeightsDense = new double[numberOfVariables];
3212  for (k = 0; k < numberOfVariables; k++) m_mdIntegerVariableBranchingWeightsDense[k] = OSNaN();
3213 
3214  for (i = 0; i < num_var; i++)
3215  {
3217  if (j >= 0 && j < numberOfVariables)
3220  else
3221  throw ErrorClass("Variable index out of range");
3222  }
3224  }
3225  }
3226  }
3227  }
3228  catch(const ErrorClass& eclass)
3229  {
3230  throw ErrorClass(eclass.errormsg);
3231  }
3232  return NULL;
3233 }//getIntegerVariableBranchingWeightsDense
3234 
3243 {
3244  try
3245  {
3246  if (numberOfVariables < 0)
3247  throw ErrorClass("\"numberOfVariables\" must be present to use dense methods");
3248 
3249  if (this->optimization != NULL)
3250  {
3251  if (this->optimization->variables != NULL)
3252  {
3254  {
3255  int i,j,k;
3256  int num_var;
3258 
3261  m_mdIntegerVariableBranchingWeightsDense = new double[numberOfVariables];
3262  for (k = 0; k < numberOfVariables; k++) m_mdIntegerVariableBranchingWeightsDense[k] = OSNaN();
3263 
3264  for (i = 0; i < num_var; i++)
3265  {
3267  if (j >= 0 && j < numberOfVariables)
3270  else
3271  throw ErrorClass("Variable index out of range");
3272  }
3274  }
3275  }
3276  }
3277  }
3278  catch(const ErrorClass& eclass)
3279  {
3280  throw ErrorClass(eclass.errormsg);
3281  }
3282  return NULL;
3283 }//getIntegerVariableBranchingWeightsDense
3284 
3290 {
3291  SOSWeights** sosVarVector;
3292  if (this->optimization != NULL)
3293  {
3294  if (this->optimization->variables != NULL)
3295  {
3297  sosVarVector = this->optimization->variables->sosVariableBranchingWeights->sos;
3298  else
3299  throw ErrorClass("<sosVariableBranchingWeights> object must be defined before getting the data");
3300  }
3301  else
3302  throw ErrorClass("<variables> object must be defined before getting the data");
3303  }
3304  else
3305  throw ErrorClass("<optimization> object must be defined before getting the data");
3306  return sosVarVector;
3307 }//getSOSVariableBranchingWeightsSparse
3308 
3309 
3315 std::vector<OtherVariableOption*> OSOption::getOtherVariableOptions( std::string solver_name)
3316 {
3317  std::vector<OtherVariableOption*> optionsVector;
3318  if (this->optimization != NULL)
3319  {
3320  if (this->optimization->variables != NULL)
3321  {
3322  int i;
3323  int num_options;
3324  num_options = this->getNumberOfOtherVariableOptions();
3325  for(i = 0; i < num_options; i++)
3326  if (solver_name == this->optimization->variables->other[ i]->solver)
3327  optionsVector.push_back( this->optimization->variables->other[ i]);
3328  }
3329  else
3330  throw ErrorClass("<variables> object must be defined before getting the data");
3331  }
3332  else
3333  throw ErrorClass("<optimization> object must be defined before getting the data");
3334  return optionsVector;
3335 }//getOtherVariableOptions
3336 
3342 {
3343  OtherVariableOption** optionsVector;
3344  if (this->optimization != NULL)
3345  {
3346  if (this->optimization->variables != NULL)
3347  optionsVector = this->optimization->variables->other;
3348  else
3349  throw ErrorClass("<variables> object must be defined before getting the data");
3350  }
3351  else
3352  throw ErrorClass("<optimization> object must be defined before getting the data");
3353  return optionsVector;
3354 }//getAllOtherVariableOptions
3355 
3364 {
3365  if (this->optimization != NULL)
3366  {
3367  if (this->optimization->variables != NULL)
3368  {
3369  int num_options;
3370  num_options = this->getNumberOfOtherVariableOptions();
3371  if (optionNumber < 0 || optionNumber >= num_options)
3372  throw ErrorClass("optionNumber not in legal range");
3373  return this->optimization->variables->other[optionNumber];
3374  }
3375  else
3376  throw ErrorClass("<variables> object must be defined before getting the data");
3377  }
3378  else
3379  throw ErrorClass("<optimization> object must be defined before getting the data");
3380 }//getOtherVariableOption
3381 
3387 {
3388  InitObjValue** initObjVector;
3389  if (this->optimization != NULL)
3390  {
3391  if (this->optimization->objectives != NULL)
3392  {
3393  if (this->optimization->objectives->initialObjectiveValues != NULL)
3394  initObjVector = this->optimization->objectives->initialObjectiveValues->obj;
3395  else
3396  throw ErrorClass("<initialObjectiveValues> object must be defined before getting the data");
3397  }
3398  else
3399  throw ErrorClass("<objectives> object must be defined before getting the data");
3400  }
3401  else
3402  throw ErrorClass("<optimization> object must be defined before getting the data");
3403  return initObjVector;
3404 }//getInitObjValuesSparse
3405 
3412 {
3413  try
3414  {
3415  int numberOfObjectives;
3416  numberOfObjectives = this->getNumberOfObjectives();
3417  if (numberOfObjectives < 0)
3418  throw ErrorClass("\"numberOfObjectives\" must be present to use dense methods");
3419 
3420  if (this->optimization != NULL)
3421  {
3422  if (this->optimization->objectives != NULL)
3423  {
3424  if (this->optimization->objectives->initialObjectiveValues != NULL)
3425  {
3426  int i,j,k;
3427  int num_obj;
3428  num_obj = this->getNumberOfInitObjValues();
3429 
3430  if (m_mdInitObjValuesDense != NULL)
3431  delete [] m_mdInitObjValuesDense;
3432  m_mdInitObjValuesDense = new double[numberOfObjectives];
3433  for (k = 0; k < numberOfObjectives; k++) m_mdInitObjValuesDense[k] = OSNaN();
3434 
3435  for (i = 0; i < num_obj; i++)
3436  {
3438  if (j < 0 && -j <= numberOfObjectives)
3441  else
3442  {
3443  throw ErrorClass("Objective index out of range");
3444  }
3445  }
3446  return m_mdInitObjValuesDense;
3447  }
3448  }
3449  }
3450  }
3451  catch(const ErrorClass& eclass)
3452  {
3453  throw ErrorClass(eclass.errormsg);
3454  }
3455  return NULL;
3456 }//getInitObjValuesDense
3457 
3464 double* OSOption::getInitObjValuesDense(int numberOfObjectives)
3465 {
3466  try
3467  {
3468  if (numberOfObjectives < 0)
3469  throw ErrorClass("\"numberOfObjectives\" must be present to use dense methods");
3470 
3471  if (this->optimization != NULL)
3472  {
3473  if (this->optimization->objectives != NULL)
3474  {
3475  if (this->optimization->objectives->initialObjectiveValues != NULL)
3476  {
3477  int i,j,k;
3478  int num_obj;
3479  num_obj = this->getNumberOfInitObjValues();
3480 
3481  if (m_mdInitObjValuesDense != NULL)
3482  delete [] m_mdInitObjValuesDense;
3483  m_mdInitObjValuesDense = new double[numberOfObjectives];
3484  for (k = 0; k < numberOfObjectives; k++) m_mdInitObjValuesDense[k] = OSNaN();
3485 
3486  for (i = 0; i < num_obj; i++)
3487  {
3489  if (j < 0 && -j <= numberOfObjectives)
3492  else
3493  {
3494  throw ErrorClass("Objective index out of range");
3495  }
3496  }
3497  return m_mdInitObjValuesDense;
3498  }
3499  }
3500  }
3501  }
3502  catch(const ErrorClass& eclass)
3503  {
3504  throw ErrorClass(eclass.errormsg);
3505  }
3506  return NULL;
3507 }//getInitObjValuesDense
3508 
3514 {
3515  InitObjBound** initObjBounds;
3516  if (this->optimization != NULL)
3517  {
3518  if (this->optimization->objectives != NULL)
3519  {
3520  if (this->optimization->objectives->initialObjectiveBounds != NULL)
3521  initObjBounds = this->optimization->objectives->initialObjectiveBounds->obj;
3522  else
3523  throw ErrorClass("<initialObjectiveBounds> object must be defined before getting the data");
3524  }
3525  else
3526  throw ErrorClass("<objectives> object must be defined before getting the data");
3527  }
3528  else
3529  throw ErrorClass("<optimization> object must be defined before getting the data");
3530  return initObjBounds;
3531 }//getInitObjBoundsSparse
3532 
3539 {
3540  try
3541  {
3542  int numberOfObjectives;
3543  numberOfObjectives = this->getNumberOfObjectives();
3544  if (numberOfObjectives < 0)
3545  throw ErrorClass("\"numberOfObjectives\" must be present to use dense methods");
3546 
3547  if (this->optimization != NULL)
3548  {
3549  if (this->optimization->objectives != NULL)
3550  {
3551  if (this->optimization->objectives->initialObjectiveBounds != NULL)
3552  {
3553  int i,j,k;
3554  int num_obj;
3555  num_obj = this->getNumberOfInitObjBounds();
3556 
3557  if (m_mdInitObjLowerBoundsDense != NULL)
3558  delete [] m_mdInitObjLowerBoundsDense;
3559  m_mdInitObjLowerBoundsDense = new double[numberOfObjectives];
3560  for (k = 0; k < numberOfObjectives; k++) m_mdInitObjLowerBoundsDense[k] = OSNaN();
3561 
3562  for (i = 0; i < num_obj; i++)
3563  {
3565  if (j < 0 && -j <= numberOfObjectives)
3568  else
3569  {
3570  throw ErrorClass("Objective index out of range");
3571  }
3572  }
3574  }
3575  }
3576  }
3577  }
3578  catch(const ErrorClass& eclass)
3579  {
3580  throw ErrorClass(eclass.errormsg);
3581  }
3582  return NULL;
3583 }//getInitObjLowerBoundsDense
3584 
3591 double* OSOption::getInitObjLowerBoundsDense(int numberOfObjectives)
3592 {
3593  try
3594  {
3595  if (numberOfObjectives < 0)
3596  throw ErrorClass("\"numberOfObjectives\" must be present to use dense methods");
3597 
3598  if (this->optimization != NULL)
3599  {
3600  if (this->optimization->objectives != NULL)
3601  {
3602  if (this->optimization->objectives->initialObjectiveBounds != NULL)
3603  {
3604  int i,j,k;
3605  int num_obj;
3606  num_obj = this->getNumberOfInitObjBounds();
3607 
3608  if (m_mdInitObjLowerBoundsDense != NULL)
3609  delete [] m_mdInitObjLowerBoundsDense;
3610  m_mdInitObjLowerBoundsDense = new double[numberOfObjectives];
3611  for (k = 0; k < numberOfObjectives; k++) m_mdInitObjLowerBoundsDense[k] = OSNaN();
3612 
3613  for (i = 0; i < num_obj; i++)
3614  {
3616  if (j < 0 && -j <= numberOfObjectives)
3619  else
3620  {
3621  throw ErrorClass("Objective index out of range");
3622  }
3623  }
3625  }
3626  }
3627  }
3628  }
3629  catch(const ErrorClass& eclass)
3630  {
3631  throw ErrorClass(eclass.errormsg);
3632  }
3633  return NULL;
3634 }//getInitObjLowerBoundsDense
3635 
3642 {
3643  try
3644  {
3645  int numberOfObjectives;
3646  numberOfObjectives = this->getNumberOfObjectives();
3647  if (numberOfObjectives < 0)
3648  throw ErrorClass("\"numberOfObjectives\" must be present to use dense methods");
3649 
3650  if (this->optimization != NULL)
3651  {
3652  if (this->optimization->objectives != NULL)
3653  {
3654  if (this->optimization->objectives->initialObjectiveBounds != NULL)
3655  {
3656  int i,j,k;
3657  int num_obj;
3658  num_obj = this->getNumberOfInitObjBounds();
3659 
3660  if (m_mdInitObjUpperBoundsDense != NULL)
3661  delete [] m_mdInitObjUpperBoundsDense;
3662  m_mdInitObjUpperBoundsDense = new double[numberOfObjectives];
3663  for (k = 0; k < numberOfObjectives; k++) m_mdInitObjUpperBoundsDense[k] = OSNaN();
3664 
3665  for (i = 0; i < num_obj; i++)
3666  {
3668  if (j < 0 && -j <= numberOfObjectives)
3671  else
3672  {
3673  throw ErrorClass("Objective index out of range");
3674  }
3675  }
3677  }
3678  }
3679  }
3680  }
3681  catch(const ErrorClass& eclass)
3682  {
3683  throw ErrorClass(eclass.errormsg);
3684  }
3685  return NULL;
3686 }//getInitObjUpperBoundsDense
3687 
3694 double* OSOption::getInitObjUpperBoundsDense(int numberOfObjectives)
3695 {
3696  try
3697  {
3698  if (numberOfObjectives < 0)
3699  throw ErrorClass("\"numberOfObjectives\" must be present to use dense methods");
3700 
3701  if (this->optimization != NULL)
3702  {
3703  if (this->optimization->objectives != NULL)
3704  {
3705  if (this->optimization->objectives->initialObjectiveBounds != NULL)
3706  {
3707  int i,j,k;
3708  int num_obj;
3709  num_obj = this->getNumberOfInitObjBounds();
3710 
3711  if (m_mdInitObjUpperBoundsDense != NULL)
3712  delete [] m_mdInitObjUpperBoundsDense;
3713  m_mdInitObjUpperBoundsDense = new double[numberOfObjectives];
3714  for (k = 0; k < numberOfObjectives; k++) m_mdInitObjUpperBoundsDense[k] = OSNaN();
3715 
3716  for (i = 0; i < num_obj; i++)
3717  {
3719  if (j < 0 && -j <= numberOfObjectives)
3722  else
3723  {
3724  throw ErrorClass("Objective index out of range");
3725  }
3726  }
3728  }
3729  }
3730  }
3731  }
3732  catch(const ErrorClass& eclass)
3733  {
3734  throw ErrorClass(eclass.errormsg);
3735  }
3736  return NULL;
3737 }//getInitObjUpperBoundsDense
3738 
3745 std::string *OSOption::getInitVarValuesStringDense(int numberOfVariables)
3746 {
3747  try
3748  {
3749  if (numberOfVariables < 0)
3750  throw ErrorClass("\"numberOfVariables\" must be present to use dense methods");
3751 
3752  if (this->optimization != NULL)
3753  {
3754  if (this->optimization->variables != NULL)
3755  {
3757  {
3758  int i,j,k;
3759  int num_var;
3760  num_var = this->getNumberOfInitVarValuesString();
3761 
3762  if (m_mdInitVarValuesStringDense != NULL)
3763  delete [] m_mdInitVarValuesStringDense;
3764  m_mdInitVarValuesStringDense = new std::string[numberOfVariables];
3765  for (k = 0; k < numberOfVariables; k++) m_mdInitVarValuesStringDense[k] = "";
3766 
3767  for (i = 0; i < num_var; i++)
3768  {
3770  if (j >= 0 && j < numberOfVariables)
3773  else
3774  throw ErrorClass("Variable index out of range");
3775  }
3777  }
3778  }
3779  }
3780  }
3781  catch(const ErrorClass& eclass)
3782  {
3783  throw ErrorClass(eclass.errormsg);
3784  }
3785  return NULL;
3786 }//getInitVarValuesStringDense
3787 
3788 
3797 {
3798  try
3799  {
3800  if (numberOfObjectives < 0)
3801  throw ErrorClass("\"numberOfObjectives\" must be set to use dense methods");
3802 
3803  if (this->optimization == NULL)
3804  throw ErrorClass("<optimization> element was never set");
3805 
3806  if (this->optimization->objectives == NULL)
3807  throw ErrorClass("<optimization> <objectives> element was never set");
3808 
3809  if (this->optimization->objectives->initialBasisStatus == NULL)
3810  throw ErrorClass("initial basis was never set");
3811 
3812  int i,j,k;
3813 
3814  if (m_mdInitBasisStatusDense != NULL)
3815  delete [] m_mdInitBasisStatusDense;
3816  m_mdInitBasisStatusDense = new int[numberOfObjectives];
3817  for (k = 0; k < numberOfObjectives; k++) m_mdInitBasisStatusDense[k] = ENUM_BASIS_STATUS_unknown;
3818 
3819  int num_obj;
3820 
3821  if (this->optimization->objectives->initialBasisStatus->basic != NULL)
3822  {
3824  for (i = 0; i < num_obj; i++)
3825  {
3827  if (j >= 0 || j < -numberOfObjectives)
3828  throw ErrorClass("Objective index out of range");
3829  else
3831  }
3832  }
3833 
3834  if (this->optimization->objectives->initialBasisStatus->atLower != NULL)
3835  {
3837  for (i = 0; i < num_obj; i++)
3838  {
3840  if (j >= 0 || j < -numberOfObjectives)
3841  throw ErrorClass("Objective index out of range");
3842  else
3844  }
3845  }
3846 
3847  if (this->optimization->objectives->initialBasisStatus->atUpper != NULL)
3848  {
3850  for (i = 0; i < num_obj; i++)
3851  {
3853  if (j >= 0 || j < -numberOfObjectives)
3854  throw ErrorClass("Objective index out of range");
3855  else
3857  }
3858  }
3859 
3860  if (this->optimization->objectives->initialBasisStatus->isFree != NULL)
3861  {
3863  for (i = 0; i < num_obj; i++)
3864  {
3866  if (j >= 0 || j < -numberOfObjectives)
3867  throw ErrorClass("Objective index out of range");
3868  else
3870  }
3871  }
3872 
3874  {
3876  for (i = 0; i < num_obj; i++)
3877  {
3879  if (j >= 0 || j < -numberOfObjectives)
3880  throw ErrorClass("Objective index out of range");
3881  else
3883  }
3884  }
3885 
3886  return m_mdInitBasisStatusDense;
3887  }
3888 
3889  catch(const ErrorClass& eclass)
3890  {
3891  throw ErrorClass(eclass.errormsg);
3892 
3893  }
3894  return NULL;
3895 }//getVariableInitialBasisStatusDense
3896 
3897 
3898 
3899 
3905 std::vector<OtherObjectiveOption*> OSOption::getOtherObjectiveOptions( std::string solver_name)
3906 {
3907  std::vector<OtherObjectiveOption*> optionsVector;
3908  if (this->optimization != NULL)
3909  {
3910  if (this->optimization->variables != NULL)
3911  {
3912  int i;
3913  int num_options;
3914  num_options = this->getNumberOfOtherObjectiveOptions();
3915  for(i = 0; i < num_options; i++)
3916  if (solver_name == this->optimization->objectives->other[ i]->solver)
3917  optionsVector.push_back( this->optimization->objectives->other[ i]);
3918  }
3919  else
3920  throw ErrorClass("<objectives> object must be defined before getting the data");
3921  }
3922  else
3923  throw ErrorClass("<optimization> object must be defined before getting the data");
3924  return optionsVector;
3925 }//getOtherObjectiveOptions
3926 
3935 {
3936  if (this->optimization != NULL)
3937  {
3938  if (this->optimization->objectives != NULL)
3939  {
3940  int num_options;
3941  num_options = this->getNumberOfOtherObjectiveOptions();
3942  if (optionNumber < 0 || optionNumber >= num_options)
3943  throw ErrorClass("optionNumber not in legal range");
3944  return this->optimization->objectives->other[optionNumber];
3945  }
3946  else
3947  throw ErrorClass("<objectives> object must be defined before getting the data");
3948  }
3949  else
3950  throw ErrorClass("<optimization> object must be defined before getting the data");
3951 }//getOtherObjectiveOption
3952 
3958 {
3959  OtherObjectiveOption** optionsVector;
3960  if (this->optimization != NULL)
3961  {
3962  if (this->optimization->objectives != NULL)
3963  optionsVector = this->optimization->objectives->other;
3964  else
3965  throw ErrorClass("<objectives> object must be defined before getting the data");
3966  }
3967  else
3968  throw ErrorClass("<optimization> object must be defined before getting the data");
3969  return optionsVector;
3970 }//getAllOtherObjectiveOptions
3971 
3972 
3978 {
3979  InitConValue** initConVector;
3980  if (this->optimization != NULL)
3981  {
3982  if (this->optimization->constraints != NULL)
3983  {
3984  if (this->optimization->constraints->initialConstraintValues != NULL)
3985  initConVector = this->optimization->constraints->initialConstraintValues->con;
3986  else
3987  throw ErrorClass("<initialConstraintValues> object must be defined before getting the data");
3988  }
3989  else
3990  throw ErrorClass("<constraints> object must be defined before getting the data");
3991  }
3992  else
3993  throw ErrorClass("<optimization> object must be defined before getting the data");
3994  return initConVector;
3995 }//getInitConValuesSparse
3996 
4003 {
4004  try
4005  {
4006  int numberOfConstraints;
4007  numberOfConstraints = this->getNumberOfConstraints();
4008  if (numberOfConstraints < 0)
4009  throw ErrorClass("\"numberOfConstraints\" must be present to use dense methods");
4010 
4011  if (this->optimization != NULL)
4012  {
4013  if (this->optimization->constraints != NULL)
4014  {
4015  if (this->optimization->constraints->initialConstraintValues != NULL)
4016  {
4017  int i,j,k;
4018  int num_con;
4019  num_con = this->getNumberOfInitConValues();
4020 
4021  if (m_mdInitConValuesDense != NULL)
4022  delete [] m_mdInitConValuesDense;
4023  m_mdInitConValuesDense = new double[numberOfConstraints];
4024  for (k = 0; k < numberOfConstraints; k++) m_mdInitConValuesDense[k] = OSNaN();
4025 
4026  for (i = 0; i < num_con; i++)
4027  {
4029  if (j >= 0 && j < numberOfConstraints)
4032  else
4033  throw ErrorClass("Constraint index out of range");
4034  }
4035  return m_mdInitConValuesDense;
4036  }
4037  }
4038  }
4039  }
4040  catch(const ErrorClass& eclass)
4041  {
4042  throw ErrorClass(eclass.errormsg);
4043  }
4044  return NULL;
4045 }//getInitConValuesDense
4046 
4053 double* OSOption::getInitConValuesDense(int numberOfConstraints)
4054 {
4055  try
4056  {
4057  if (numberOfConstraints < 0)
4058  throw ErrorClass("\"numberOfConstraints\" must be present to use dense methods");
4059 
4060  if (this->optimization != NULL)
4061  {
4062  if (this->optimization->constraints != NULL)
4063  {
4064  if (this->optimization->constraints->initialConstraintValues != NULL)
4065  {
4066  int i,j,k;
4067  int num_con;
4068  num_con = this->getNumberOfInitConValues();
4069 
4070  if (m_mdInitConValuesDense != NULL)
4071  delete [] m_mdInitConValuesDense;
4072  m_mdInitConValuesDense = new double[numberOfConstraints];
4073  for (k = 0; k < numberOfConstraints; k++) m_mdInitConValuesDense[k] = OSNaN();
4074 
4075  for (i = 0; i < num_con; i++)
4076  {
4078  if (j >= 0 && j < numberOfConstraints)
4081  else
4082  throw ErrorClass("Constraint index out of range");
4083  }
4084  return m_mdInitConValuesDense;
4085  }
4086  }
4087  }
4088  }
4089  catch(const ErrorClass& eclass)
4090  {
4091  throw ErrorClass(eclass.errormsg);
4092  }
4093  return NULL;
4094 }//getInitConValuesDense
4095 
4101 {
4102  InitDualVarValue** initDualVector;
4103  if (this->optimization != NULL)
4104  {
4105  if (this->optimization->constraints != NULL)
4106  {
4107  if (this->optimization->constraints->initialDualValues != NULL)
4108  initDualVector = this->optimization->constraints->initialDualValues->con;
4109  else
4110  throw ErrorClass("<initialDualValues> object must be defined before getting the data");
4111  }
4112  else
4113  throw ErrorClass("<constraints> object must be defined before getting the data");
4114  }
4115  else
4116  throw ErrorClass("<optimization> object must be defined before getting the data");
4117  return initDualVector;
4118 }//getInitDualVarValuesSparse
4119 
4126 {
4127  try
4128  {
4129  int numberOfConstraints;
4130  numberOfConstraints = this->getNumberOfConstraints();
4131  if (numberOfConstraints < 0)
4132  throw ErrorClass("\"numberOfConstraints\" must be present to use dense methods");
4133 
4134  if (this->optimization != NULL)
4135  {
4136  if (this->optimization->constraints != NULL)
4137  {
4138  if (this->optimization->constraints->initialDualValues != NULL)
4139  {
4140 
4141  int i,j,k;
4142 
4143  int num_con;
4144  num_con = this->getNumberOfInitDualVarValues();
4145 
4146  if (m_mdInitDualVarLowerBoundsDense != NULL)
4148  m_mdInitDualVarLowerBoundsDense = new double[numberOfConstraints];
4149  for (k = 0; k < numberOfConstraints; k++) m_mdInitDualVarLowerBoundsDense[k] = 0.0;
4150 
4151  for (i = 0; i < num_con; i++)
4152  {
4154  if (j >= 0 && j < numberOfConstraints)
4157  else
4158  throw ErrorClass("Constraint index out of range");
4159  }
4161  }
4162  }
4163  }
4164  }
4165  catch(const ErrorClass& eclass)
4166  {
4167  throw ErrorClass(eclass.errormsg);
4168  }
4169  return NULL;
4170 }//getInitDualVarLowerBoundsDense
4171 
4178 double* OSOption::getInitDualVarLowerBoundsDense(int numberOfConstraints)
4179 {
4180  try
4181  {
4182  if (numberOfConstraints < 0)
4183  throw ErrorClass("\"numberOfConstraints\" must be present to use dense methods");
4184 
4185  if (this->optimization != NULL)
4186  {
4187  if (this->optimization->constraints != NULL)
4188  {
4189  if (this->optimization->constraints->initialDualValues != NULL)
4190  {
4191  int i,j,k;
4192  int num_con;
4193  num_con = this->getNumberOfInitDualVarValues();
4194 
4195  if (m_mdInitDualVarLowerBoundsDense != NULL)
4197  m_mdInitDualVarLowerBoundsDense = new double[numberOfConstraints];
4198  for (k = 0; k < numberOfConstraints; k++) m_mdInitDualVarLowerBoundsDense[k] = 0.0;
4199 
4200  for (i = 0; i < num_con; i++)
4201  {
4203  if (j >= 0 && j < numberOfConstraints)
4206  else
4207  throw ErrorClass("Constraint index out of range");
4208  }
4210  }
4211  }
4212  }
4213  }
4214  catch(const ErrorClass& eclass)
4215  {
4216  throw ErrorClass(eclass.errormsg);
4217  }
4218  return NULL;
4219 }//getInitDualVarLowerBoundsDense
4220 
4227 {
4228  try
4229  {
4230  int numberOfConstraints;
4231  numberOfConstraints = this->getNumberOfConstraints();
4232  if (numberOfConstraints < 0)
4233  throw ErrorClass("\"numberOfConstraints\" must be present to use dense methods");
4234 
4235  if (this->optimization != NULL)
4236  {
4237  if (this->optimization->constraints != NULL)
4238  {
4239  if (this->optimization->constraints->initialDualValues != NULL)
4240  {
4241  int i,j,k;
4242  int num_con;
4243  num_con = this->getNumberOfInitDualVarValues();
4244  numberOfConstraints = this->getNumberOfConstraints();
4245 
4246  if (m_mdInitDualVarUpperBoundsDense != NULL)
4248  m_mdInitDualVarUpperBoundsDense = new double[numberOfConstraints];
4249  for (k = 0; k < numberOfConstraints; k++) m_mdInitDualVarUpperBoundsDense[k] = 0.0;
4250 
4251  for (i = 0; i < num_con; i++)
4252  {
4254  if (j >= 0 && j < numberOfConstraints)
4257  else
4258  throw ErrorClass("Constraint index out of range");
4259  }
4261  }
4262  }
4263  }
4264  }
4265  catch(const ErrorClass& eclass)
4266  {
4267  throw ErrorClass(eclass.errormsg);
4268  }
4269  return NULL;
4270 }//getInitDualVarUpperBoundsDense
4271 
4278 double* OSOption::getInitDualVarUpperBoundsDense(int numberOfConstraints)
4279 {
4280  try
4281  {
4282  if (numberOfConstraints < 0)
4283  throw ErrorClass("\"numberOfConstraints\" must be present to use dense methods");
4284 
4285  if (this->optimization != NULL)
4286  {
4287  if (this->optimization->constraints != NULL)
4288  {
4289  if (this->optimization->constraints->initialDualValues != NULL)
4290  {
4291  int i,j,k;
4292  int num_con;
4293  num_con = this->getNumberOfInitDualVarValues();
4294  numberOfConstraints = this->getNumberOfConstraints();
4295 
4296  if (m_mdInitDualVarUpperBoundsDense != NULL)
4298  m_mdInitDualVarUpperBoundsDense = new double[numberOfConstraints];
4299  for (k = 0; k < numberOfConstraints; k++) m_mdInitDualVarUpperBoundsDense[k] = 0.0;
4300 
4301  for (i = 0; i < num_con; i++)
4302  {
4304  if (j >= 0 && j < numberOfConstraints)
4307  else
4308  throw ErrorClass("Constraint index out of range");
4309  }
4311  }
4312  }
4313  }
4314  }
4315  catch(const ErrorClass& eclass)
4316  {
4317  throw ErrorClass(eclass.errormsg);
4318  }
4319  return NULL;
4320 }//getInitDualVarUpperBoundsDense
4321 
4322 
4330 {
4331  try
4332  {
4333  if (numberOfConstraints < 0)
4334  throw ErrorClass("\"numberOfConstraints\" must be set to use dense methods");
4335 
4336  if (this->optimization == NULL)
4337  throw ErrorClass("<optimization> element was never set");
4338 
4339  if (this->optimization->constraints == NULL)
4340  throw ErrorClass("<optimization> <constraints> element was never set");
4341 
4342  if (this->optimization->constraints->initialBasisStatus == NULL)
4343  throw ErrorClass("initial basis was never set");
4344 
4345  int i,j,k;
4346 
4347  if (m_mdInitBasisStatusDense != NULL)
4348  delete [] m_mdInitBasisStatusDense;
4349  m_mdInitBasisStatusDense = new int[numberOfConstraints];
4350  for (k = 0; k < numberOfConstraints; k++) m_mdInitBasisStatusDense[k] = ENUM_BASIS_STATUS_unknown;
4351 
4352  int num_slack;
4353 
4354  if (this->optimization->constraints->initialBasisStatus->basic != NULL)
4355  {
4357  for (i = 0; i < num_slack; i++)
4358  {
4360  if (j >= 0 && j < numberOfConstraints)
4362  else
4363  throw ErrorClass("Constraint index out of range");
4364  }
4365  }
4366 
4367  if (this->optimization->constraints->initialBasisStatus->atLower != NULL)
4368  {
4370  for (i = 0; i < num_slack; i++)
4371  {
4373  if (j >= 0 && j < numberOfConstraints)
4375  else
4376  throw ErrorClass("Constraint index out of range");
4377  }
4378  }
4379 
4380  if (this->optimization->constraints->initialBasisStatus->atUpper != NULL)
4381  {
4383  for (i = 0; i < num_slack; i++)
4384  {
4386  if (j >= 0 && j < numberOfConstraints)
4388  else
4389  throw ErrorClass("Constraint index out of range");
4390  }
4391  }
4392 
4393  if (this->optimization->constraints->initialBasisStatus->isFree != NULL)
4394  {
4396  for (i = 0; i < num_slack; i++)
4397  {
4399  if (j >= 0 && j < numberOfConstraints)
4401  else
4402  throw ErrorClass("Constraint index out of range");
4403  }
4404  }
4405 
4407  {
4409  for (i = 0; i < num_slack; i++)
4410  {
4412  if (j >= 0 && j < numberOfConstraints)
4414  else
4415  throw ErrorClass("Constraint index out of range");
4416  }
4417  }
4418 
4419  return m_mdInitBasisStatusDense;
4420  }
4421 
4422  catch(const ErrorClass& eclass)
4423  {
4424  throw ErrorClass(eclass.errormsg);
4425  }
4426  return NULL;
4427 }//getSlackVariableInitialBasisStatusDense
4428 
4429 
4435 std::vector<OtherConstraintOption*> OSOption::getOtherConstraintOptions( std::string solver_name)
4436 {
4437  std::vector<OtherConstraintOption*> optionsVector;
4438  if (this->optimization != NULL)
4439  {
4440  if (this->optimization->constraints != NULL)
4441  {
4442  int i;
4443  int num_options;
4444  num_options = this->getNumberOfOtherConstraintOptions();
4445  for(i = 0; i < num_options; i++)
4446  if (solver_name == this->optimization->constraints->other[ i]->solver)
4447  optionsVector.push_back( this->optimization->constraints->other[ i]);
4448  }
4449  else
4450  throw ErrorClass("<constraints> object must be defined before getting the data");
4451  }
4452  else
4453  throw ErrorClass("<optimization> object must be defined before getting the data");
4454  return optionsVector;
4455 }//getOtherConstraintOptions
4456 
4462 {
4463  OtherConstraintOption** optionsVector;
4464  if (this->optimization != NULL)
4465  {
4466  if (this->optimization->constraints != NULL)
4467  optionsVector = this->optimization->constraints->other;
4468  else
4469  throw ErrorClass("<constraints> object must be defined before getting the data");
4470  }
4471  else
4472  throw ErrorClass("<optimization> object must be defined before getting the data");
4473  return optionsVector;
4474 }//getAllOtherConstraintOptions
4475 
4484 {
4485  if (this->optimization != NULL)
4486  {
4487  if (this->optimization->constraints != NULL)
4488  {
4489  int num_options;
4490  num_options = this->getNumberOfOtherConstraintOptions();
4491  if (optionNumber < 0 || optionNumber >= num_options)
4492  throw ErrorClass("optionNumber not in legal range");
4493  return this->optimization->constraints->other[optionNumber];
4494  }
4495  else
4496  throw ErrorClass("<constraints> object must be defined before getting the data");
4497  }
4498  else
4499  throw ErrorClass("<optimization> object must be defined before getting the data");
4500 }//getOtherConstraintOption
4501 
4502 
4508 std::vector<SolverOption*> OSOption::getSolverOptions( std::string solver_name)
4509 {
4510  std::vector<SolverOption*> optionsVector;
4511  if (this->optimization != NULL)
4512  {
4513  if (this->optimization->solverOptions != NULL)
4514  {
4515  int i;
4516  int num_options;
4517  num_options = this->getNumberOfSolverOptions();
4518  for(i = 0; i < num_options; i++)
4519  if (solver_name == this->optimization->solverOptions->solverOption[ i]->solver)
4520  optionsVector.push_back( this->optimization->solverOptions->solverOption[ i]);
4521  }
4522  else
4523  throw ErrorClass("<solverOptions> object must be defined before getting the data");
4524  }
4525  else
4526  throw ErrorClass("<optimization> object must be defined before getting the data");
4527  return optionsVector;
4528 }//getSolverOptions
4529 
4530 
4539 std::vector<SolverOption*> OSOption::getSolverOptions( std::string solver_name, bool getFreeOptions)
4540 {
4541  std::vector<SolverOption*> optionsVector;
4542  if (this->optimization != NULL)
4543  {
4544  if (this->optimization->solverOptions != NULL)
4545  {
4546  int i;
4547  int num_options;
4548  num_options = this->getNumberOfSolverOptions();
4549  for (i = 0; i < num_options; i++)
4550  {
4551  if (this->optimization->solverOptions->solverOption[i]->solver == solver_name ||
4552  (this->optimization->solverOptions->solverOption[i]->solver == "" && getFreeOptions))
4553  optionsVector.push_back( this->optimization->solverOptions->solverOption[i]);
4554  }
4555  }
4556  else
4557  throw ErrorClass("<solverOptions> object must be defined before getting the data");
4558  }
4559  else
4560  throw ErrorClass("<optimization> object must be defined before getting the data");
4561  return optionsVector;
4562 }//getSolverOptions
4568 {
4569  SolverOption** optionsVector;
4570  if (this->optimization != NULL)
4571  {
4572  if (this->optimization->solverOptions != NULL)
4573  optionsVector = this->optimization->solverOptions->solverOption;
4574  else
4575  throw ErrorClass("<solverOptions> object must be defined before getting the data");
4576  }
4577  else
4578  throw ErrorClass("<optimization> object must be defined before getting the data");
4579  return optionsVector;
4580 }//getAllOtherConstraintOptions
4581 
4582 
4583 
4590 /* ----------------------------------------------------------
4591  * Start with a number of set() and add() methods for arrays
4592  * used in various subelements.
4593  * These have been put here in order of appearance
4594  * ----------------------------------------------------------*/
4595 
4599 bool OtherOptions::setOther(int numberOfOptions, OtherOption** other)
4600 {
4601  try
4602  {
4603  if (this->other != NULL)
4604  throw ErrorClass( "otherOptions array previously used.");
4605 
4606  if (numberOfOptions < 0)
4607  throw ErrorClass( "length of otherOptions array cannot be negative.");
4608 
4609  this->numberOfOtherOptions = numberOfOptions;
4610  if (numberOfOptions == 0)
4611  return true;
4612 
4613  this->other = new OtherOption*[numberOfOptions];
4614 
4615  int i;
4616  for (i = 0; i < numberOfOptions; i++)
4617  {
4618  this->other[i] = new OtherOption();
4619  *this->other[i] = *other[i];
4620  }
4621  return true;
4622  }
4623  catch(const ErrorClass& eclass)
4624  {
4626  return false;
4627  }
4628 }//setOther
4629 
4633 bool OtherOptions::addOther(std::string name, std::string value, std::string description)
4634 {
4635  try
4636  {
4637  int nopt;
4638  int i;
4639  if (name.empty() )
4640  throw ErrorClass( "the name of an option cannot be empty." );
4641 
4642  if (this->other == NULL)
4643  nopt = 0;
4644  else
4645  nopt = this->numberOfOtherOptions;
4646 
4647  OtherOption** temp = new OtherOption*[nopt+1]; //Allocate the new pointers
4648  for (i = 0; i < nopt; i++)
4649  temp[i] = this->other[i]; //copy the pointers
4650 
4651  delete[] this->other; //delete old pointers
4652 
4653 // add in the new element
4654  temp[ nopt] = new OtherOption();
4655 
4656  temp[ nopt]->name = name;
4657  temp[ nopt]->value = value;
4658  temp[ nopt]->description = description;
4659 
4660  this->other = temp; //hook the new pointers into the data structure
4661  this->numberOfOtherOptions = ++nopt;
4662 
4663  return true;
4664  }
4665  catch(const ErrorClass& eclass)
4666  {
4668  return false;
4669  }
4670 }//addOther
4671 
4677 bool JobDependencies::setJobID(int numberOfJobIDs, std::string *jobID)
4678 {
4679  try
4680  {
4681  if (this->jobID != NULL)
4682  // throw ErrorClass( "jobID array previously used.");
4683  return false;
4684 
4685  if (numberOfJobIDs < 0)
4686  // throw ErrorClass( "length of jobID array cannot be negative.");
4687  return false;
4688 
4689  this->numberOfJobIDs = numberOfJobIDs;
4690  if (numberOfJobIDs == 0)
4691  return true;
4692 
4693  this->jobID = new std::string[numberOfJobIDs];
4694  int i;
4695  for (i = 0; i < numberOfJobIDs; i++)
4696  this->jobID[i] = jobID[i];
4697 
4698  return true;
4699  }
4700  catch(const ErrorClass& eclass)
4701  {
4703  return false;
4704  }
4705 }//setJobID
4706 
4712 bool JobDependencies::addJobID(std::string jobID)
4713 {
4714  try
4715  {
4716  int nopt;
4717  if (jobID.empty() )
4718  // throw ErrorClass( "the name of a jobID cannot be empty." );
4719  return false;
4720 
4721  if (this->jobID == NULL)
4722  nopt = 0;
4723  else
4724  nopt = this->numberOfJobIDs;
4725 
4726  std::string* temp = new std::string[nopt+1];
4727  int i;
4728  for (i = 0; i < nopt; i++)
4729  temp[i] = this->jobID[i]; // create the new jobID
4730 
4731  delete[] this->jobID;
4732 
4733  temp[nopt] = jobID;
4734 
4735  this->jobID = temp;
4736  this->numberOfJobIDs = ++nopt;
4737  return true;
4738  }
4739  catch(const ErrorClass& eclass)
4740  {
4742  return false;
4743  }
4744 }//addJobID
4745 
4752 bool DirectoriesAndFiles::setPath(int numberOfPaths, std::string *path)
4753 {
4754  try
4755  {
4756  if (this->path != NULL)
4757  // throw ErrorClass( "path array previously used.");
4758  return false;
4759 
4760  if (numberOfPaths < 0)
4761  // throw ErrorClass( "length of path array cannot be negative.");
4762  return false;
4763 
4764  this->numberOfPaths = numberOfPaths;
4765  if (numberOfPaths == 0)
4766  return true;
4767 
4768  this->path = new std::string[numberOfPaths];
4769  int i;
4770  for (i = 0; i < numberOfPaths; i++)
4771  this->path[i] = path[i];
4772 
4773  return true;
4774  }
4775  catch(const ErrorClass& eclass)
4776  {
4778  return false;
4779  }
4780 }//setPath
4781 
4787 bool DirectoriesAndFiles::addPath(std::string path)
4788 {
4789  try
4790  {
4791  int nopt;
4792  if (path.empty() )
4793  // throw ErrorClass( "the path cannot be empty." );
4794  return false;
4795 
4796  if (this->path == NULL)
4797  nopt = 0;
4798  else
4799  nopt = this->numberOfPaths;
4800 
4801  std::string* temp = new std::string[nopt+1];
4802  int i;
4803  for (i = 0; i < nopt; i++)
4804  temp[i] = this->path[i]; // create the new path
4805 
4806  delete[] this->path;
4807 
4808  temp[nopt] = path;
4809 
4810  this->path = temp;
4811  this->numberOfPaths = ++nopt;
4812  return true;
4813  }
4814  catch(const ErrorClass& eclass)
4815  {
4817  return false;
4818  }
4819 }//addPath
4820 
4827 bool PathPairs::setPathPair(int numberOfPathPairs, PathPair **pathPair)
4828 {
4829  try
4830  {
4831  if (this->pathPair != NULL)
4832  // throw ErrorClass( "pathPair array previously used.");
4833  return false;
4834 
4835  if (numberOfPathPairs < 0)
4836  // throw ErrorClass( "length of pathPair array cannot be negative.");
4837  return false;
4838 
4839  this->numberOfPathPairs = numberOfPathPairs;
4840  if (numberOfPathPairs == 0)
4841  return true;
4842 
4843  this->pathPair = new PathPair*[numberOfPathPairs];
4844 
4845  int i;
4846  for (i = 0; i < numberOfPathPairs; i++)
4847  {
4848  this->pathPair[i] = new PathPair();
4849  *this->pathPair[i] = *pathPair[i];
4850  }
4851  return true;
4852  }
4853  catch(const ErrorClass& eclass)
4854  {
4856  return false;
4857  }
4858 }//setPathPair
4859 
4860 
4861 bool PathPairs::setPathPair(std::string *from, std::string *to, bool *makeCopy, int numberOfPathPairs)
4862 {
4863 // if (this->pathPair != NULL)
4864 // return false;
4865 
4866  this->numberOfPathPairs = numberOfPathPairs;
4867  if (numberOfPathPairs == 0)
4868  return true;
4869 
4870  this->pathPair = new PathPair*[numberOfPathPairs];
4871 
4872  int i;
4873  for (i = 0; i < numberOfPathPairs; i++)
4874  {
4875  this->pathPair[i] = new PathPair();
4876  this->pathPair[i]->from = from[i];
4877  this->pathPair[i]->to = to[i];
4878  this->pathPair[i]->makeCopy = makeCopy[i];
4879  }
4880  return true;
4881 }//setPathPair
4882 
4890 bool PathPairs::addPathPair(std::string fromPath, std::string toPath, bool makeCopy)
4891 {
4892  try
4893  {
4894  int nopt;
4895  int i;
4896  if (fromPath.empty() )
4897  // throw ErrorClass( "the \"from\" path cannot be empty." );
4898  return false;
4899  if (toPath.empty() )
4900  // throw ErrorClass( "the \"to\" path cannot be empty." );
4901  return false;
4902 
4903  if (this->pathPair == NULL)
4904  nopt = 0;
4905  else
4906  nopt = this->numberOfPathPairs;
4907 
4908  PathPair** temp = new PathPair*[nopt+1]; //Allocate the new pointers
4909  for (i = 0; i < nopt; i++)
4910  temp[i] = this->pathPair[i]; //copy the pointers
4911 
4912  delete[] this->pathPair; //delete old pointers
4913 
4914 // add in the new element
4915  temp[ nopt] = new PathPair();
4916 
4917  temp[ nopt]->from = fromPath;
4918  temp[ nopt]->to = toPath;
4919  temp[ nopt]->makeCopy = makeCopy;
4920 
4921  this->pathPair = temp; //hook the new pointers into the data structure
4922  this->numberOfPathPairs = ++nopt;
4923 
4924  return true;
4925  }
4926  catch(const ErrorClass& eclass)
4927  {
4929  return false;
4930  }
4931 }//addPathPair
4932 
4939 bool Processes::setProcess(int numberOfProcesses, std::string *process)
4940 {
4941  try
4942  {
4943  if (this->process != NULL)
4944  // throw ErrorClass( "process array previously used.");
4945  return false;
4946 
4947  if (numberOfProcesses < 0)
4948  // throw ErrorClass( "length of process array cannot be negative.");
4949  return false;
4950 
4951  this->numberOfProcesses= numberOfProcesses;
4952  if (numberOfProcesses == 0)
4953  return true;
4954 
4955  this->process = new std::string[numberOfProcesses];
4956  int i;
4957  for (i = 0; i < numberOfProcesses; i++)
4958  this->process[i] = process[i];
4959 
4960  return true;
4961  }
4962  catch(const ErrorClass& eclass)
4963  {
4965  return false;
4966  }
4967 }//setProcess
4968 
4974 bool Processes::addProcess(std::string process)
4975 {
4976  try
4977  {
4978  int nopt;
4979  if (process.empty() )
4980  throw ErrorClass( "the name of a process cannot be empty." );
4981 
4982  if (this->process == NULL)
4983  nopt = 0;
4984  else
4985  nopt = this->numberOfProcesses;
4986 
4987  std::string* temp = new std::string[nopt+1];
4988  int i;
4989  for (i = 0; i < nopt; i++)
4990  temp[i] = this->process[i]; // create the new jobID
4991 
4992  delete[] this->process;
4993 
4994  temp[nopt] = process;
4995 
4996  this->process = temp;
4997  this->numberOfProcesses = ++nopt;
4998  return true;
4999  }
5000  catch(const ErrorClass& eclass)
5001  {
5003  return false;
5004  }
5005 }//addProcess
5006 
5013 bool InitVariableValues::setVar(int numberOfVar, InitVarValue **var)
5014 {
5015  try
5016  {
5017  if (this->var != NULL)
5018  throw ErrorClass( "InitVarValue array previously used.");
5019 
5020  if (numberOfVar < 0)
5021  throw ErrorClass( "length of var array cannot be negative.");
5022 
5023  this->numberOfVar = numberOfVar;
5024  if (numberOfVar == 0)
5025  return true;
5026 
5027  this->var = new InitVarValue*[numberOfVar];
5028 
5029  int i;
5030  for (i = 0; i < numberOfVar; i++)
5031  {
5032  this->var[i] = new InitVarValue();
5033  *this->var[i] = *var[i];
5034  }
5035  return true;
5036  }
5037  catch(const ErrorClass& eclass)
5038  {
5040  return false;
5041  }
5042 }//setVar
5043 
5052 {
5053  try
5054  {
5055  if (this->var != NULL)
5056  {
5057  if (disp == ENUM_COMBINE_ARRAYS_throw)
5058  throw ErrorClass( "InitVarValue array previously used.");
5059  if (disp == ENUM_COMBINE_ARRAYS_ignore)
5060  return true;
5061 
5062  if (disp == ENUM_COMBINE_ARRAYS_merge)
5063  return this->addVar(numberOfVar, var);
5064 
5065  //here we replace the old data
5066  for (int i = 0; i < this->numberOfVar; i++)
5067  delete this->var[i];
5068  delete [] this->var;
5069  this->var = NULL;
5070  }
5071 
5072  if (numberOfVar < 0)
5073  throw ErrorClass( "length of var array cannot be negative.");
5074 
5075  this->numberOfVar = numberOfVar;
5076  if (numberOfVar == 0)
5077  return true;
5078 
5079  this->var = new InitVarValue*[numberOfVar];
5080 
5081  int i;
5082  for (i = 0; i < numberOfVar; i++)
5083  {
5084  this->var[i] = new InitVarValue();
5085  *this->var[i] = *var[i];
5086  }
5087  return true;
5088  }
5089  catch(const ErrorClass& eclass)
5090  {
5092  return false;
5093  }
5094 }//setVar
5095 
5096 
5105 bool InitVariableValues::setVar(int numberOfVar, int *idx, double *value, std::string *name)
5106 {
5107  if (this->var != NULL)
5108  return false;
5109 
5110  if (numberOfVar < 0)
5111  return false;
5112 
5113  this->numberOfVar = numberOfVar;
5114  if (numberOfVar == 0)
5115  return true;
5116 
5117  this->var = new InitVarValue*[numberOfVar];
5118 
5119  int i;
5120  for (i = 0; i < numberOfVar; i++)
5121  {
5122  this->var[i] = new InitVarValue();
5123  this->var[i]->idx = idx[i];
5124  this->var[i]->name = name[i];
5125  this->var[i]->value = value[i];
5126  }
5127  return true;
5128 }//setVar
5129 
5136 bool InitVariableValues::addVar(int idx, double value)
5137 {
5138  try
5139  {
5140  int nopt;
5141  int i;
5142  if (idx < 0)
5143  throw ErrorClass( "the index of a variable cannot be negative." );
5144 
5145  if (this->var == NULL)
5146  nopt = 0;
5147  else
5148  nopt = this->numberOfVar;
5149 
5150  InitVarValue** temp = new InitVarValue*[nopt+1]; //Allocate the new pointers
5151  for (i = 0; i < nopt; i++)
5152  temp[i] = this->var[i]; //copy the pointers
5153 
5154  delete[] this->var; //delete old pointers
5155 
5156 // add in the new element
5157  temp[ nopt] = new InitVarValue();
5158 
5159  temp[ nopt]->idx = idx;
5160  temp[ nopt]->value = value;
5161 
5162  this->var = temp; //hook the new pointers into the data structure
5163  this->numberOfVar = ++nopt;
5164 
5165  return true;
5166  }
5167  catch(const ErrorClass& eclass)
5168  {
5170  return false;
5171  }
5172 }//addVar
5173 
5179 bool InitVariableValues::addVar(int numberOfVar, InitVarValue **var)
5180 {
5181  try
5182  {
5183  if (numberOfVar < 0)
5184  throw ErrorClass( "length of var array cannot be negative.");
5185 
5186  if (numberOfVar == 0)
5187  return true;
5188 
5189  int nprev = this->numberOfVar;
5190 
5191  InitVarValue** temp = new InitVarValue*[nprev+numberOfVar]; //Allocate the new pointers
5192  for (int i = 0; i < nprev; i++)
5193  temp[i] = this->var[i]; //copy the pointers
5194 
5195  delete[] this->var; //delete old pointers
5196 
5197 // add in the new elements
5198  for (int i=0; i < numberOfVar; i++)
5199  {
5200  temp[nprev+i] = new InitVarValue();
5201  *temp[nprev+i] = *var[i];
5202  }
5203 
5204  this->var = temp; //hook the new pointers into the data structure
5205  this->numberOfVar = nprev + numberOfVar;
5206 
5207  return true;
5208  }
5209  catch(const ErrorClass& eclass)
5210  {
5212  return false;
5213  }
5214 }//addVar
5215 
5223 {
5224  try
5225  {
5226  if (this->var != NULL)
5227  throw ErrorClass( "InitVarValueString array previously used.");
5228 
5229  if (numberOfVar < 0)
5230  throw ErrorClass( "length of var array cannot be negative.");
5231 
5232  this->numberOfVar = numberOfVar;
5233  if (numberOfVar == 0)
5234  return true;
5235 
5236  this->var = new InitVarValueString*[numberOfVar];
5237 
5238  int i;
5239  for (i = 0; i < numberOfVar; i++)
5240  {
5241  this->var[i] = new InitVarValueString();
5242  *this->var[i] = *var[i];
5243  }
5244  return true;
5245  }
5246  catch(const ErrorClass& eclass)
5247  {
5249  return false;
5250  }
5251 }//setVar
5252 
5260 {
5261  try
5262  {
5263  if (this->var != NULL)
5264  {
5265  if (disp == ENUM_COMBINE_ARRAYS_throw)
5266  throw ErrorClass( "InitVarValueString array previously used.");
5267  if (disp == ENUM_COMBINE_ARRAYS_ignore)
5268  return true;
5269  if (disp == ENUM_COMBINE_ARRAYS_merge)
5270  return this->addVar(numberOfVar, var);
5271 
5272  //here we replace the old data
5273  for (int i = 0; i < this->numberOfVar; i++)
5274  delete this->var[i];
5275  delete [] this->var;
5276  this->var = NULL;
5277  }
5278 
5279  if (numberOfVar < 0)
5280  throw ErrorClass( "length of var array cannot be negative.");
5281 
5282  this->numberOfVar = numberOfVar;
5283  if (numberOfVar == 0)
5284  return true;
5285 
5286  this->var = new InitVarValueString*[numberOfVar];
5287 
5288  int i;
5289  for (i = 0; i < numberOfVar; i++)
5290  {
5291  this->var[i] = new InitVarValueString();
5292  *this->var[i] = *var[i];
5293  }
5294  return true;
5295  }
5296  catch(const ErrorClass& eclass)
5297  {
5299  return false;
5300  }
5301 }//setVar
5302 
5311 bool InitVariableValuesString::setVar(int numberOfVar, int *idx, std::string *value, std::string *name)
5312 {
5313  if (this->var != NULL)
5314  return false;
5315 
5316 
5317  if (numberOfVar < 0)
5318  return false;
5319 
5320  this->numberOfVar = numberOfVar;
5321  if (numberOfVar == 0)
5322  return true;
5323 
5324  this->var = new InitVarValueString*[numberOfVar];
5325 
5326  int i;
5327  for (i = 0; i < numberOfVar; i++)
5328  {
5329  this->var[i] = new InitVarValueString();
5330  this->var[i]->idx = idx[i];
5331  this->var[i]->name = name[i];
5332  this->var[i]->value = value[i];
5333  }
5334  return true;
5335 }//setVar
5336 
5343 bool InitVariableValuesString::addVar(int idx, std::string value)
5344 {
5345  try
5346  {
5347  int nopt;
5348  int i;
5349  if (idx < 0)
5350  throw ErrorClass( "the index of a variable cannot be negative." );
5351 
5352  if (this->var == NULL)
5353  nopt = 0;
5354  else
5355  nopt = this->numberOfVar;
5356 
5357  InitVarValueString** temp = new InitVarValueString*[nopt+1]; //Allocate the new pointers
5358  for (i = 0; i < nopt; i++)
5359  temp[i] = this->var[i]; //copy the pointers
5360 
5361  delete[] this->var; //delete old pointers
5362 
5363 // add in the new element
5364  temp[ nopt] = new InitVarValueString();
5365 
5366  temp[ nopt]->idx = idx;
5367  temp[ nopt]->value = value;
5368 
5369  this->var = temp; //hook the new pointers into the data structure
5370  this->numberOfVar = ++nopt;
5371 
5372  return true;
5373  }
5374  catch(const ErrorClass& eclass)
5375  {
5377  return false;
5378  }
5379 }//addVar
5380 
5388 {
5389  try
5390  {
5391  if (numberOfVar < 0)
5392  throw ErrorClass( "length of var array cannot be negative.");
5393 
5394  if (numberOfVar == 0)
5395  return true;
5396 
5397  int nprev = this->numberOfVar;
5398 
5399  InitVarValueString** temp = new InitVarValueString*[nprev+numberOfVar]; //Allocate the new pointers
5400  for (int i = 0; i < nprev; i++)
5401  temp[i] = this->var[i]; //copy the pointers
5402 
5403  delete[] this->var; //delete old pointers
5404 
5405 // add in the new elements
5406  for (int i=0; i < numberOfVar; i++)
5407  {
5408  temp[nprev+i] = new InitVarValueString();
5409  *temp[nprev+i] = *var[i];
5410  }
5411 
5412  this->var = temp; //hook the new pointers into the data structure
5413  this->numberOfVar = nprev + numberOfVar;
5414 
5415  return true;
5416  }
5417  catch(const ErrorClass& eclass)
5418  {
5420  return false;
5421  }
5422 }//addVar
5423 
5430 bool InitialBasisStatus::setVar(int numberOfVar, InitBasStatus **var)
5431 {
5432  try
5433  {
5434  if (this->var != NULL)
5435  throw ErrorClass( "InitBasStatus array previously used.");
5436 
5437  if (numberOfVar < 0)
5438  throw ErrorClass( "length of var array cannot be negative.");
5439 
5440  this->numberOfVar = numberOfVar;
5441  if (numberOfVar == 0)
5442  return true;
5443 
5444  this->var = new InitBasStatus*[numberOfVar];
5445 
5446  int i;
5447  for (i = 0; i < numberOfVar; i++)
5448  {
5449  this->var[i] = new InitBasStatus();
5450  *this->var[i] = *var[i];
5451  }
5452  return true;
5453  }
5454  catch(const ErrorClass& eclass)
5455  {
5457  return false;
5458  }
5459 }//setVar
5460 
5467 bool InitialBasisStatus::addVar(int idx, std::string value)
5468 {
5469  try
5470  {
5471  int nopt;
5472  int i;
5473  if (idx < 0)
5474  throw ErrorClass( "the index of a variable cannot be negative." );
5475  if (value != "atLower" && value != "basic" && value != "unknown" &&
5476  value != "atUpper" && value != "superbasic" )
5477  throw ErrorClass( "Illegal basis status " + value );
5478 
5479  if (this->var == NULL)
5480  nopt = 0;
5481  else
5482  nopt = this->numberOfVar;
5483 
5484  InitBasStatus** temp = new InitBasStatus*[nopt+1]; //Allocate the new pointers
5485  for (i = 0; i < nopt; i++)
5486  temp[i] = this->var[i]; //copy the pointers
5487 
5488  delete[] this->var; //delete old pointers
5489 
5490 // add in the new element
5491  temp[ nopt] = new InitBasStatus();
5492 
5493  temp[ nopt]->idx = idx;
5494  temp[ nopt]->value = value;
5495 
5496  this->var = temp; //hook the new pointers into the data structure
5497  this->numberOfVar = ++nopt;
5498 
5499  return true;
5500  }
5501  catch(const ErrorClass& eclass)
5502  {
5504  return false;
5505  }
5506 }//addVar
5507 
5515 {
5516  try
5517  {
5518  if (this->var != NULL)
5519  return false;
5520 
5521  if (numberOfVar < 0)
5522  return false;
5523 
5524  this->numberOfVar = numberOfVar;
5525  if (numberOfVar == 0)
5526  return true;
5527 
5528  this->var = new BranchingWeight*[numberOfVar];
5529 
5530  int i;
5531  for (i = 0; i < numberOfVar; i++)
5532  {
5533  this->var[i] = new BranchingWeight();
5534  *this->var[i] = *var[i];
5535  }
5536  return true;
5537  }
5538  catch(const ErrorClass& eclass)
5539  {
5541  return false;
5542  }
5543 }//setVar
5544 
5552 {
5553  try
5554  {
5555  if (this->var != NULL)
5556  {
5557  if (disp == ENUM_COMBINE_ARRAYS_throw)
5558  throw ErrorClass( "BranchingWeight array previously used.");
5559  if (disp == ENUM_COMBINE_ARRAYS_ignore)
5560  return true;
5561  if (disp == ENUM_COMBINE_ARRAYS_merge)
5562  return this->addVar(numberOfVar, var);
5563 
5564  //here we replace the old data
5565  for (int i = 0; i < this->numberOfVar; i++)
5566  delete this->var[i];
5567  delete [] this->var;
5568  this->var = NULL;
5569  }
5570 
5571  if (numberOfVar < 0)
5572  throw ErrorClass( "length of var array cannot be negative.");
5573 
5574  this->numberOfVar = numberOfVar;
5575  if (numberOfVar == 0)
5576  return true;
5577 
5578  this->var = new BranchingWeight*[numberOfVar];
5579 
5580  int i;
5581  for (i = 0; i < numberOfVar; i++)
5582  {
5583  this->var[i] = new BranchingWeight();
5584  *this->var[i] = *var[i];
5585  }
5586  return true;
5587  }
5588  catch(const ErrorClass& eclass)
5589  {
5591  return false;
5592  }
5593 }//setVar
5594 
5603 bool IntegerVariableBranchingWeights::setVar(int numberOfVar, int *idx, double *value, std::string *name)
5604 {
5605  if (this->var != NULL)
5606  return false;
5607 
5608  if (numberOfVar < 0)
5609  return false;
5610 
5611  this->numberOfVar = numberOfVar;
5612  if (numberOfVar == 0)
5613  return true;
5614 
5615  this->var = new BranchingWeight*[numberOfVar];
5616 
5617  int i;
5618  for (i = 0; i < numberOfVar; i++)
5619  {
5620  this->var[i] = new BranchingWeight();
5621  this->var[i]->idx = idx[i];
5622  this->var[i]->name = name[i];
5623  this->var[i]->value = value[i];
5624  }
5625  return true;
5626 }//setVar
5627 
5628 
5629 
5630 
5637 bool IntegerVariableBranchingWeights::addVar(int idx, double value)
5638 {
5639  try
5640  {
5641  int nopt;
5642  int i;
5643  if (idx < 0)
5644  throw ErrorClass( "the index of a variable cannot be negative." );
5645 
5646  if (this->var == NULL)
5647  nopt = 0;
5648  else
5649  nopt = this->numberOfVar;
5650 
5651  BranchingWeight** temp = new BranchingWeight*[nopt+1]; //Allocate the new pointers
5652  for (i = 0; i < nopt; i++)
5653  temp[i] = this->var[i]; //copy the pointers
5654 
5655  delete[] this->var; //delete old pointers
5656 
5657 // add in the new element
5658  temp[ nopt] = new BranchingWeight();
5659 
5660  temp[ nopt]->idx = idx;
5661  temp[ nopt]->value = value;
5662 
5663  this->var = temp; //hook the new pointers into the data structure
5664  this->numberOfVar = ++nopt;
5665 
5666  return true;
5667  }
5668  catch(const ErrorClass& eclass)
5669  {
5671  return false;
5672  }
5673 }//addVar
5674 
5681 {
5682  try
5683  {
5684  if (numberOfVar < 0)
5685  throw ErrorClass( "length of var array cannot be negative.");
5686 
5687  if (numberOfVar == 0)
5688  return true;
5689 
5690  int nprev = this->numberOfVar;
5691 
5692  BranchingWeight** temp = new BranchingWeight*[nprev+numberOfVar]; //Allocate the new pointers
5693  for (int i = 0; i < nprev; i++)
5694  temp[i] = this->var[i]; //copy the pointers
5695 
5696  delete[] this->var; //delete old pointers
5697 
5698 // add in the new elements
5699  for (int i=0; i < numberOfVar; i++)
5700  {
5701  temp[nprev+i] = new BranchingWeight();
5702  *temp[nprev+i] = *var[i];
5703  }
5704 
5705  this->var = temp; //hook the new pointers into the data structure
5706  this->numberOfVar = nprev + numberOfVar;
5707 
5708  return true;
5709  }
5710  catch(const ErrorClass& eclass)
5711  {
5713  return false;
5714  }
5715 }//addVar
5716 
5723 bool SOSWeights::setVar(int numberOfVar, BranchingWeight **var)
5724 {
5725  try
5726  {
5727  if (this->var != NULL)
5728  throw ErrorClass( "BranchingWeight array previously used.");
5729 
5730  if (numberOfVar < 0)
5731  throw ErrorClass( "length of var array cannot be negative.");
5732 
5733  this->numberOfVar = numberOfVar;
5734  if (numberOfVar == 0)
5735  return true;
5736 
5737  this->var = new BranchingWeight*[numberOfVar];
5738 
5739  int i;
5740  for (i = 0; i < numberOfVar; i++)
5741  {
5742  this->var[i] = new BranchingWeight();
5743  *this->var[i] = *var[i];
5744  }
5745  return true;
5746  }
5747  catch(const ErrorClass& eclass)
5748  {
5750  return false;
5751  }
5752 }//setVar
5753 
5760 bool SOSWeights::addVar(int idx, double value)
5761 {
5762  try
5763  {
5764  int nopt;
5765  int i;
5766  if (idx < 0)
5767  throw ErrorClass( "the index of a variable cannot be negative." );
5768 
5769  if (this->var == NULL)
5770  nopt = 0;
5771  else
5772  nopt = this->numberOfVar;
5773 
5774  BranchingWeight** temp = new BranchingWeight*[nopt+1]; //Allocate the new pointers
5775  for (i = 0; i < nopt; i++)
5776  temp[i] = this->var[i]; //copy the pointers
5777 
5778  delete[] this->var; //delete old pointers
5779 
5780 // add in the new element
5781  temp[ nopt] = new BranchingWeight();
5782 
5783  temp[ nopt]->idx = idx;
5784  temp[ nopt]->value = value;
5785 
5786  this->var = temp; //hook the new pointers into the data structure
5787  this->numberOfVar = ++nopt;
5788 
5789  return true;
5790  }
5791  catch(const ErrorClass& eclass)
5792  {
5794  return false;
5795  }
5796 }//addVar
5797 
5805 {
5806  try
5807  {
5808  if (this->sos != NULL)
5809  throw ErrorClass( "SOS array previously used.");
5810 
5811  if (numberOfSOS < 0)
5812  throw ErrorClass( "length of sos array cannot be negative.");
5813 
5814  this->numberOfSOS = numberOfSOS;
5815  if (numberOfSOS == 0) return true;
5816 
5817  this->sos = new SOSWeights*[numberOfSOS];
5818 
5819  int i, j;
5820  for (i = 0; i < numberOfSOS; i++)
5821  {
5822  this->sos[i] = new SOSWeights();
5823  this->sos[i]->sosIdx = sos[i]->sosIdx;
5824  this->sos[i]->groupWeight = sos[i]->groupWeight;
5825 
5826  if (sos[i]->numberOfVar < 0)
5827  throw ErrorClass( "the number of variables in the SOS cannot be negative.");
5828 
5829  this->sos[i]->numberOfVar = sos[i]->numberOfVar;
5830 
5831  if (sos[i]->numberOfVar > 0)
5832  {
5833  this->sos[i]->var = new BranchingWeight*[sos[i]->numberOfVar];
5834  for (j = 0; j < sos[i]->numberOfVar; j++)
5835  {
5836  this->sos[i]->var[j] = new BranchingWeight();
5837  *this->sos[i]->var[j] = *sos[i]->var[j];
5838  }
5839  }
5840  }
5841  return true;
5842  }
5843  catch(const ErrorClass& eclass)
5844  {
5846  return false;
5847  }
5848 }//setSOS
5849 
5855 bool SOSVariableBranchingWeights::addSOS(int sosIdx, int nvar, double weight, int* idx, double* value, std::string* name)
5856 {
5857  try
5858  {
5859  int nopt;
5860  int i;
5861  if (sosIdx < 0)
5862  throw ErrorClass( "the index of the SOS cannot be negative." );
5863  if (nvar < 0)
5864  throw ErrorClass( "the number of variables in the SOS cannot be negative." );
5865 
5866  if (this->sos == NULL)
5867  nopt = 0;
5868  else
5869  nopt = this->numberOfSOS;
5870 
5871  SOSWeights** temp = new SOSWeights*[nopt+1]; //Allocate the new pointers
5872  for (i = 0; i < nopt; i++)
5873  temp[i] = this->sos[i]; //copy the pointers
5874 
5875  delete[] this->sos; //delete old pointers
5876 
5877 // add in the new element
5878  temp[ nopt] = new SOSWeights();
5879 
5880  temp[ nopt]->sosIdx = sosIdx;
5881  temp[ nopt]->groupWeight = weight;
5882  temp[ nopt]->numberOfVar = nvar;
5883  temp[ nopt]->var = new BranchingWeight*[nvar];
5884  for (i = 0; i < nvar; i++)
5885  {
5886  temp[nopt]->var[i] = new BranchingWeight();
5887  temp[nopt]->var[i]->idx = idx[i];
5888  temp[nopt]->var[i]->name = name[i];
5889  temp[nopt]->var[i]->value = value[i];
5890  }
5891 
5892  this->sos = temp; //hook the new pointers into the data structure
5893  this->numberOfSOS = ++nopt;
5894 
5895  return true;
5896  }
5897  catch(const ErrorClass& eclass)
5898  {
5900  return false;
5901  }
5902 }//addSOS
5903 
5910 bool OtherVariableOption::setVar(int numberOfVar, OtherVarOption **var)
5911 {
5912  try
5913  {
5914  if (this->var != NULL)
5915  throw ErrorClass( "OtherVarOption array previously used.");
5916 
5917  if (numberOfVar < 0)
5918  throw ErrorClass( "length of <var> array cannot be negative.");
5919 
5920  this->numberOfVar = numberOfVar;
5921  if (numberOfVar == 0) return true;
5922 
5923  this->var = new OtherVarOption*[numberOfVar];
5924 
5925  int i;
5926  for (i = 0; i < numberOfVar; i++)
5927  {
5928  this->var[i] = new OtherVarOption();
5929  *this->var[i] = *var[i];
5930  }
5931  return true;
5932  }
5933  catch(const ErrorClass& eclass)
5934  {
5936  return false;
5937  }
5938 }//setVar
5939 
5948 bool OtherVariableOption::addVar(int idx, std::string value, std::string lbValue, std::string ubValue)
5949 {
5950  try
5951  {
5952  int nopt;
5953  int i;
5954  if (idx < 0)
5955  throw ErrorClass( "the index of a variable cannot be negative." );
5956 
5957  if (this->var == NULL)
5958  nopt = 0;
5959  else
5960  nopt = this->numberOfVar;
5961 
5962  OtherVarOption** temp = new OtherVarOption*[nopt+1]; //Allocate the new pointers
5963  for (i = 0; i < nopt; i++)
5964  temp[i] = this->var[i]; //copy the pointers
5965 
5966  delete[] this->var; //delete old pointers
5967 
5968 // add in the new element
5969  temp[ nopt] = new OtherVarOption();
5970 
5971  temp[ nopt]->idx = idx;
5972  temp[ nopt]->value = value;
5973  temp[ nopt]->lbValue = lbValue;
5974  temp[ nopt]->ubValue = ubValue;
5975 
5976  this->var = temp; //hook the new pointers into the data structure
5977  this->numberOfVar = ++nopt;
5978 
5979  return true;
5980  }
5981  catch(const ErrorClass& eclass)
5982  {
5984  return false;
5985  }
5986 }//addVar
5987 
5994 bool VariableOption::setOther(int numberOfOptions, OtherVariableOption **other)
5995 {
5996  try
5997  {
5998  if (this->other != NULL)
5999  throw ErrorClass( "otherVariableOptions array previously used.");
6000 
6001  if (numberOfOptions < 0)
6002  throw ErrorClass( "length of <other> array cannot be negative.");
6003 
6004  this->numberOfOtherVariableOptions = numberOfOptions;
6005  if (numberOfOptions == 0) return true;
6006 
6007  this->other = new OtherVariableOption*[numberOfOptions];
6008 
6009  int i, j;
6010  for (i = 0; i < numberOfOptions; i++)
6011  {
6012  this->other[i] = new OtherVariableOption();
6013  this->other[i]->name = other[i]->name;
6014  this->other[i]->value = other[i]->value;
6015  this->other[i]->solver = other[i]->solver;
6016  this->other[i]->category = other[i]->category;
6017  this->other[i]->type = other[i]->type;
6018  this->other[i]->description = other[i]->description;
6019 
6020  if (other[i]->numberOfVar < 0)
6021  throw ErrorClass( "the number of variables in otherVariableOption cannot be negative.");
6022 
6023  this->other[i]->numberOfVar = other[i]->numberOfVar;
6024 
6025  if (other[i]->numberOfVar > 0)
6026  {
6027  this->other[i]->var = new OtherVarOption*[other[i]->numberOfVar];
6028  for (j = 0; j < other[i]->numberOfVar; j++)
6029  {
6030  this->other[i]->var[j] = new OtherVarOption();
6031  *this->other[i]->var[j] = *other[i]->var[j];
6032  }
6033  }
6034  this->other[i]->numberOfEnumerations = other[i]->numberOfEnumerations;
6035 
6036  if (this->other[i]->numberOfEnumerations > 0)
6037  {
6038  this->other[i]->enumeration = new OtherOptionOrResultEnumeration*[this->other[i]->numberOfEnumerations];
6039  for (j = 0; j < this->other[i]->numberOfEnumerations; j++)
6040  {
6041  this->other[i]->enumeration[j] = new OtherOptionOrResultEnumeration();
6042  this->other[i]->enumeration[j]->setOtherOptionOrResultEnumeration(
6043  other[i]->enumeration[j]->value,
6044  other[i]->enumeration[j]->description,
6045  other[i]->enumeration[j]->el,
6046  other[i]->enumeration[j]->numberOfEl);
6047  }
6048  }
6049  }
6050  return true;
6051  }
6052  catch(const ErrorClass& eclass)
6053  {
6055  return false;
6056  }
6057 }//setOther
6058 
6065 {
6066  try
6067  {
6068  int nopt, i, j;
6069  if (this->other == NULL)
6070  nopt = 0;
6071  else
6072  nopt = this->numberOfOtherVariableOptions;
6073 
6074  OtherVariableOption** temp = new OtherVariableOption*[nopt+1]; //Allocate the new pointers
6075  for (i = 0; i < nopt; i++)
6076  temp[i] = this->other[i]; //copy the pointers
6077 
6078  delete[] this->other; //delete old pointers
6079 
6080 // add in the new element
6081  temp[ nopt] = new OtherVariableOption();
6082  temp[ nopt]->name = other->name;
6083  temp[ nopt]->value = other->value;
6084  temp[ nopt]->solver = other->solver;
6085  temp[ nopt]->category = other->category;
6086  temp[ nopt]->type = other->type;
6087  temp[ nopt]->varType = other->varType;
6088  temp[ nopt]->enumType = other->enumType;
6089  temp[ nopt]->description = other->description;
6090 
6091  if (other->numberOfVar < 0)
6092  throw ErrorClass( "the number of variables in otherVariableOption cannot be negative.");
6093 
6094  temp[ nopt]->numberOfVar = other->numberOfVar;
6095 
6096  if (other->numberOfVar > 0)
6097  {
6098  temp[ nopt]->var = new OtherVarOption*[other->numberOfVar];
6099  for (j = 0; j < other->numberOfVar; j++)
6100  {
6101  temp[nopt]->var[j] = new OtherVarOption();
6102  *temp[nopt]->var[j] = *other->var[j];
6103  }
6104  }
6105 
6106  temp[ nopt]->numberOfEnumerations = other->numberOfEnumerations;
6107 
6108  if (other->numberOfEnumerations > 0)
6109  {
6111  for (j = 0; j < other->numberOfEnumerations; j++)
6112  {
6113  temp[ nopt]->enumeration[j] = new OtherOptionOrResultEnumeration();
6115  other->enumeration[j]->value,
6116  other->enumeration[j]->description,
6117  other->enumeration[j]->el,
6118  other->enumeration[j]->numberOfEl);
6119  }
6120  }
6121 
6122 
6123  this->other = temp; //hook the new pointers into the data structure
6124  this->numberOfOtherVariableOptions = ++nopt;
6125 
6126  return true;
6127  }
6128  catch(const ErrorClass& eclass)
6129  {
6131  return false;
6132  }
6133 }//addOther
6134 
6141 bool InitObjectiveValues::setObj(int numberOfObj, InitObjValue **obj)
6142 {
6143  try
6144  {
6145  if (this->obj != NULL)
6146  throw ErrorClass( "InitObjValue array previously used.");
6147 
6148  if (numberOfObj < 0)
6149  throw ErrorClass( "length of obj array cannot be negative.");
6150 
6151  this->numberOfObj = numberOfObj;
6152  if (numberOfObj == 0)
6153  return true;
6154 
6155  this->obj = new InitObjValue*[numberOfObj];
6156 
6157  int i;
6158  for (i = 0; i < numberOfObj; i++)
6159  {
6160  this->obj[i] = new InitObjValue();
6161  *this->obj[i] = *obj[i];
6162  }
6163  return true;
6164  }
6165  catch(const ErrorClass& eclass)
6166  {
6168  return false;
6169  }
6170 }//setObj
6171 
6180 {
6181  try
6182  {
6183  if (this->obj != NULL)
6184  {
6185  if (disp == ENUM_COMBINE_ARRAYS_throw)
6186  throw ErrorClass( "InitObjValue array previously used.");
6187  if (disp == ENUM_COMBINE_ARRAYS_ignore)
6188  return true;
6189  if (disp == ENUM_COMBINE_ARRAYS_merge)
6190  return this->addObj(numberOfObj, obj);
6191 
6192  //here we replace the old data
6193  for (int i = 0; i < this->numberOfObj; i++)
6194  delete this->obj[i];
6195  delete [] this->obj;
6196  this->obj = NULL;
6197  }
6198 
6199  if (numberOfObj < 0)
6200  throw ErrorClass( "length of obj array cannot be negative.");
6201 
6202  this->numberOfObj = numberOfObj;
6203  if (numberOfObj == 0)
6204  return true;
6205 
6206  this->obj = new InitObjValue*[numberOfObj];
6207 
6208  int i;
6209  for (i = 0; i < numberOfObj; i++)
6210  {
6211  this->obj[i] = new InitObjValue();
6212  *this->obj[i] = *obj[i];
6213  }
6214  return true;
6215  }
6216  catch(const ErrorClass& eclass)
6217  {
6219  return false;
6220  }
6221 }//setObj
6222 
6223 bool InitObjectiveValues::setObj(int numberOfObj, int *idx, double *value, std::string *name)
6224 {
6225  if (this->obj != NULL) return false;
6226 
6227  if (numberOfObj < 0) return false;
6228 
6229  this->numberOfObj = numberOfObj;
6230  if (numberOfObj == 0) return true;
6231 
6232  this->obj = new InitObjValue*[numberOfObj];
6233 
6234  int i;
6235  for (i = 0; i < numberOfObj; i++)
6236  {
6237  this->obj[i] = new InitObjValue();
6238  this->obj[i]->idx = idx[i];
6239  this->obj[i]->name = name[i];
6240  this->obj[i]->value = value[i];
6241  }
6242  return true;
6243 }//setObj
6244 
6245 
6252 bool InitObjectiveValues::addObj(int idx, double value)
6253 {
6254  try
6255  {
6256  int nopt;
6257  int i;
6258  if (idx >= 0)
6259  throw ErrorClass( "the index of an objective must be negative." );
6260 
6261  if (this->obj == NULL)
6262  nopt = 0;
6263  else
6264  nopt = this->numberOfObj;
6265 
6266  InitObjValue** temp = new InitObjValue*[nopt+1]; //Allocate the new pointers
6267  for (i = 0; i < nopt; i++)
6268  temp[i] = this->obj[i]; //copy the pointers
6269 
6270  delete[] this->obj; //delete old pointers
6271 
6272 // add in the new element
6273  temp[ nopt] = new InitObjValue();
6274 
6275  temp[ nopt]->idx = idx;
6276  temp[ nopt]->value = value;
6277 
6278  this->obj = temp; //hook the new pointers into the data structure
6279  this->numberOfObj = ++nopt;
6280 
6281  return true;
6282  }
6283  catch(const ErrorClass& eclass)
6284  {
6286  return false;
6287  }
6288 }//addObj
6289 
6295 bool InitObjectiveValues::addObj(int numberOfObj, InitObjValue **obj)
6296 {
6297  try
6298  {
6299  if (numberOfObj < 0)
6300  throw ErrorClass( "length of obj array cannot be negative.");
6301 
6302  if (numberOfObj == 0)
6303  return true;
6304 
6305  int nprev = this->numberOfObj;
6306 
6307  InitObjValue** temp = new InitObjValue*[nprev+numberOfObj]; //Allocate the new pointers
6308  for (int i = 0; i < nprev; i++)
6309  temp[i] = this->obj[i]; //copy the pointers
6310 
6311  delete[] this->obj; //delete old pointers
6312 
6313 // add in the new elements
6314  for (int i=0; i < numberOfObj; i++)
6315  {
6316  temp[nprev+i] = new InitObjValue();
6317  *temp[nprev+i] = *obj[i];
6318  }
6319 
6320  this->obj = temp; //hook the new pointers into the data structure
6321  this->numberOfObj = nprev + numberOfObj;
6322 
6323  return true;
6324  }
6325  catch(const ErrorClass& eclass)
6326  {
6328  return false;
6329  }
6330 }//addObj
6331 
6338 bool InitObjectiveBounds::setObj(int numberOfObj, InitObjBound **obj)
6339 {
6340  try
6341  {
6342  if (this->obj != NULL)
6343  throw ErrorClass( "InitObjBound array previously used.");
6344 
6345  if (numberOfObj < 0)
6346  throw ErrorClass( "length of obj array cannot be negative.");
6347 
6348  this->numberOfObj = numberOfObj;
6349  if (numberOfObj == 0)
6350  return true;
6351 
6352  this->obj = new InitObjBound*[numberOfObj];
6353 
6354  int i;
6355  for (i = 0; i < numberOfObj; i++)
6356  {
6357  this->obj[i] = new InitObjBound();
6358  *this->obj[i] = *obj[i];
6359  }
6360  return true;
6361  }
6362  catch(const ErrorClass& eclass)
6363  {
6365  return false;
6366  }
6367 }//setObj
6368 
6377 {
6378  try
6379  {
6380  if (this->obj != NULL)
6381  {
6382  if (disp == ENUM_COMBINE_ARRAYS_throw)
6383  throw ErrorClass( "InitObjBound array previously used.");
6384  if (disp == ENUM_COMBINE_ARRAYS_ignore)
6385  return true;
6386  if (disp == ENUM_COMBINE_ARRAYS_merge)
6387  return this->addObj(numberOfObj, obj);
6388 
6389  //here we replace the old data
6390  for (int i = 0; i < this->numberOfObj; i++)
6391  delete this->obj[i];
6392  delete [] this->obj;
6393  this->obj = NULL;
6394  }
6395 
6396  if (numberOfObj < 0)
6397  throw ErrorClass( "length of obj array cannot be negative.");
6398 
6399  this->numberOfObj = numberOfObj;
6400  if (numberOfObj == 0)
6401  return true;
6402 
6403  this->obj = new InitObjBound*[numberOfObj];
6404 
6405  int i;
6406  for (i = 0; i < numberOfObj; i++)
6407  {
6408  this->obj[i] = new InitObjBound();
6409  *this->obj[i] = *obj[i];
6410  }
6411  return true;
6412  }
6413  catch(const ErrorClass& eclass)
6414  {
6416  return false;
6417  }
6418 }//setObj
6419 
6420 bool InitObjectiveBounds::setObj(int numberOfObj, int *idx, double *lbValue, double *ubValue, std::string *name)
6421 {
6422  if (this->obj != NULL)
6423  return false;
6424 
6425  if (numberOfObj < 0)
6426  return false;
6427 
6428  this->numberOfObj = numberOfObj;
6429  if (numberOfObj == 0)
6430  return true;
6431 
6432  this->obj = new InitObjBound*[numberOfObj];
6433 
6434  int i;
6435  for (i = 0; i < numberOfObj; i++)
6436  {
6437  this->obj[i] = new InitObjBound();
6438  this->obj[i]->idx = idx[i];
6439  this->obj[i]->name = name[i];
6440  this->obj[i]->lbValue = lbValue[i];
6441  this->obj[i]->ubValue = ubValue[i];
6442  }
6443  return true;
6444 }//setObj
6445 
6446 
6454 bool InitObjectiveBounds::addObj(int idx, double lbValue, double ubValue)
6455 {
6456  try
6457  {
6458  int nopt;
6459  int i;
6460  if (idx >= 0)
6461  throw ErrorClass( "the index of an objective must be negative." );
6462 
6463  if (this->obj == NULL)
6464  nopt = 0;
6465  else
6466  nopt = this->numberOfObj;
6467 
6468  InitObjBound** temp = new InitObjBound*[nopt+1]; //Allocate the new pointers
6469  for (i = 0; i < nopt; i++)
6470  temp[i] = this->obj[i]; //copy the pointers
6471 
6472  delete[] this->obj; //delete old pointers
6473 
6474 // add in the new element
6475  temp[ nopt] = new InitObjBound();
6476 
6477  temp[ nopt]->idx = idx;
6478  temp[ nopt]->lbValue = lbValue;
6479  temp[ nopt]->ubValue = ubValue;
6480 
6481  this->obj = temp; //hook the new pointers into the data structure
6482  this->numberOfObj = ++nopt;
6483 
6484  return true;
6485  }
6486  catch(const ErrorClass& eclass)
6487  {
6489  return false;
6490  }
6491 }//addObj
6492 
6498 bool InitObjectiveBounds::addObj(int numberOfObj, InitObjBound **obj)
6499 {
6500  try
6501  {
6502  if (numberOfObj < 0)
6503  throw ErrorClass( "length of obj array cannot be negative.");
6504 
6505  if (numberOfObj == 0)
6506  return true;
6507 
6508  int nprev = this->numberOfObj;
6509 
6510  InitObjBound** temp = new InitObjBound*[nprev+numberOfObj]; //Allocate the new pointers
6511  for (int i = 0; i < nprev; i++)
6512  temp[i] = this->obj[i]; //copy the pointers
6513 
6514  delete[] this->obj; //delete old pointers
6515 
6516 // add in the new elements
6517  for (int i=0; i < numberOfObj; i++)
6518  {
6519  temp[nprev+i] = new InitObjBound();
6520  *temp[nprev+i] = *obj[i];
6521  }
6522 
6523  this->obj = temp; //hook the new pointers into the data structure
6524  this->numberOfObj = nprev + numberOfObj;
6525 
6526  return true;
6527  }
6528  catch(const ErrorClass& eclass)
6529  {
6531  return false;
6532  }
6533 }//addObj
6534 
6544 bool OtherObjectiveOption::setObj(int numberOfObj, OtherObjOption **obj)
6545 {
6546  try
6547  {
6548  if (this->obj != NULL)
6549  throw ErrorClass( "OtherObjOption array previously used.");
6550 
6551  if (numberOfObj < 0)
6552  throw ErrorClass( "length of <obj> array cannot be negative.");
6553 
6554  this->numberOfObj= numberOfObj;
6555  if (numberOfObj == 0)
6556  return true;
6557 
6558  this->obj = new OtherObjOption*[numberOfObj];
6559 
6560  int i;
6561  for (i = 0; i < numberOfObj; i++)
6562  {
6563  this->obj[i] = new OtherObjOption();
6564  *this->obj[i] = *obj[i];
6565  }
6566  return true;
6567  }
6568  catch(const ErrorClass& eclass)
6569  {
6571  return false;
6572  }
6573 }//setObj
6574 
6583 bool OtherObjectiveOption::addObj(int idx, std::string value, std::string lbValue, std::string ubValue)
6584 {
6585  try
6586  {
6587  int nopt;
6588  int i;
6589  if (idx >= 0)
6590  throw ErrorClass( "the index of an objective must be negative." );
6591 
6592  if (this->obj == NULL)
6593  nopt = 0;
6594  else
6595  nopt = this->numberOfObj;
6596 
6597  OtherObjOption** temp = new OtherObjOption*[nopt+1]; //Allocate the new pointers
6598  for (i = 0; i < nopt; i++)
6599  temp[i] = this->obj[i]; //copy the pointers
6600 
6601  delete[] this->obj; //delete old pointers
6602 
6603 // add in the new element
6604  temp[ nopt] = new OtherObjOption();
6605 
6606  temp[ nopt]->idx = idx;
6607  temp[ nopt]->value = value;
6608  temp[ nopt]->lbValue = lbValue;
6609  temp[ nopt]->ubValue = ubValue;
6610 
6611  this->obj = temp; //hook the new pointers into the data structure
6612  this->numberOfObj = ++nopt;
6613 
6614  return true;
6615  }
6616  catch(const ErrorClass& eclass)
6617  {
6619  return false;
6620  }
6621 }//addObj
6622 
6629 bool ObjectiveOption::setOther(int numberOfOptions, OtherObjectiveOption **other)
6630 {
6631  try
6632  {
6633  if (this->other != NULL)
6634  throw ErrorClass( "otherObjectiveOptions array previously used.");
6635 
6636  if (numberOfOptions < 0)
6637  throw ErrorClass( "length of <other> array cannot be negative.");
6638 
6639  this->numberOfOtherObjectiveOptions = numberOfOptions;
6640  if (numberOfOptions == 0) return true;
6641 
6642  this->other = new OtherObjectiveOption*[numberOfOptions];
6643 
6644  int i, j;
6645  for (i = 0; i < numberOfOptions; i++)
6646  {
6647  this->other[i] = new OtherObjectiveOption();
6648  this->other[i]->name = other[i]->name;
6649  this->other[i]->value = other[i]->value;
6650  this->other[i]->solver = other[i]->solver;
6651  this->other[i]->category = other[i]->category;
6652  this->other[i]->type = other[i]->type;
6653  this->other[i]->description = other[i]->description;
6654 
6655  if (other[i]->numberOfObj < 0)
6656  throw ErrorClass( "the number of objectives in otherObjectiveOption cannot be negative.");
6657 
6658  this->other[i]->numberOfObj = other[i]->numberOfObj;
6659 
6660  if (other[i]->numberOfObj > 0)
6661  {
6662  this->other[i]->obj = new OtherObjOption*[other[i]->numberOfObj];
6663  for (j = 0; j < other[i]->numberOfObj; j++)
6664  {
6665  this->other[i]->obj[j] = new OtherObjOption();
6666  *this->other[i]->obj[j] = *other[i]->obj[j];
6667  }
6668  }
6669  this->other[i]->numberOfEnumerations = other[i]->numberOfEnumerations;
6670 
6671  if (this->other[i]->numberOfEnumerations > 0)
6672  {
6673  this->other[i]->enumeration = new OtherOptionOrResultEnumeration*[this->other[i]->numberOfEnumerations];
6674  for (j = 0; j < this->other[i]->numberOfEnumerations; j++)
6675  {
6676  this->other[i]->enumeration[j] = new OtherOptionOrResultEnumeration();
6677  this->other[i]->enumeration[j]->setOtherOptionOrResultEnumeration(
6678  other[i]->enumeration[j]->value,
6679  other[i]->enumeration[j]->description,
6680  other[i]->enumeration[j]->el,
6681  other[i]->enumeration[j]->numberOfEl);
6682  }
6683  }
6684  }
6685  return true;
6686  }
6687  catch(const ErrorClass& eclass)
6688  {
6690  return false;
6691  }
6692 }//setOther
6693 
6700 {
6701  try
6702  {
6703  int nopt, i, j;
6704  if (this->other == NULL)
6705  nopt = 0;
6706  else
6707  nopt = this->numberOfOtherObjectiveOptions;
6708 
6709  OtherObjectiveOption** temp = new OtherObjectiveOption*[nopt+1]; //Allocate the new pointers
6710  for (i = 0; i < nopt; i++)
6711  temp[i] = this->other[i]; //copy the pointers
6712 
6713  delete[] this->other; //delete old pointers
6714 
6715 // add in the new element
6716  temp[ nopt] = new OtherObjectiveOption();
6717  temp[ nopt]->name = other->name;
6718  temp[ nopt]->value = other->value;
6719  temp[ nopt]->solver = other->solver;
6720  temp[ nopt]->category = other->category;
6721  temp[ nopt]->type = other->type;
6722  temp[ nopt]->objType = other->objType;
6723  temp[ nopt]->enumType = other->enumType;
6724  temp[ nopt]->description = other->description;
6725 
6726  if (other->numberOfObj < 0)
6727  throw ErrorClass( "the number of objectives in otherObjectiveOption cannot be negative.");
6728 
6729  temp[ nopt]->numberOfObj = other->numberOfObj;
6730 
6731  if (other->numberOfObj > 0)
6732  {
6733  temp[ nopt]->obj = new OtherObjOption*[other->numberOfObj];
6734  for (j = 0; j < other->numberOfObj; j++)
6735  {
6736  temp[nopt]->obj[j] = new OtherObjOption();
6737  *temp[nopt]->obj[j] = *other->obj[j];
6738  }
6739  }
6740 
6741  if (other->numberOfEnumerations < 0)
6742  throw ErrorClass( "the number of enumerations in otherObjectiveOption cannot be negative.");
6743 
6744  temp[ nopt]->numberOfEnumerations = other->numberOfEnumerations;
6745 
6746  if (other->numberOfEnumerations > 0)
6747  {
6749  for (j = 0; j < other->numberOfEnumerations; j++)
6750  {
6751  temp[ nopt]->enumeration[j] = new OtherOptionOrResultEnumeration();
6753  other->enumeration[j]->value,
6754  other->enumeration[j]->description,
6755  other->enumeration[j]->el,
6756  other->enumeration[j]->numberOfEl);
6757  }
6758  }
6759 
6760 
6761  this->other = temp; //hook the new pointers into the data structure
6762  this->numberOfOtherObjectiveOptions = ++nopt;
6763 
6764  return true;
6765  }
6766  catch(const ErrorClass& eclass)
6767  {
6769  return false;
6770  }
6771 }//addOther
6772 
6773 
6774 
6781 bool InitConstraintValues::setCon(int numberOfCon, InitConValue **con)
6782 {
6783  try
6784  {
6785  if (this->con != NULL)
6786  throw ErrorClass( "InitConValue array previously used.");
6787 
6788  if (numberOfCon < 0)
6789  throw ErrorClass( "length of con array cannot be negative.");
6790 
6791  this->numberOfCon = numberOfCon;
6792  if (numberOfCon == 0)
6793  return true;
6794 
6795  this->con = new InitConValue*[numberOfCon];
6796 
6797  int i;
6798  for (i = 0; i < numberOfCon; i++)
6799  {
6800  this->con[i] = new InitConValue();
6801  *this->con[i] = *con[i];
6802  }
6803  return true;
6804  }
6805  catch(const ErrorClass& eclass)
6806  {
6808  return false;
6809  }
6810 }//setCon
6811 
6820 {
6821  try
6822  {
6823  if (this->con != NULL)
6824  {
6825  if (disp == ENUM_COMBINE_ARRAYS_throw)
6826  throw ErrorClass( "InitConValue array previously used.");
6827  if (disp == ENUM_COMBINE_ARRAYS_ignore)
6828  return true;
6829  if (disp == ENUM_COMBINE_ARRAYS_merge)
6830  return this->addCon(numberOfCon, con);
6831 
6832  //here we replace the old data
6833  for (int i = 0; i < this->numberOfCon; i++)
6834  delete this->con[i];
6835  delete [] this->con;
6836  this->con = NULL;
6837  }
6838 
6839  if (numberOfCon < 0)
6840  throw ErrorClass( "length of con array cannot be negative.");
6841 
6842  this->numberOfCon = numberOfCon;
6843  if (numberOfCon == 0)
6844  return true;
6845 
6846  this->con = new InitConValue*[numberOfCon];
6847 
6848  int i;
6849  for (i = 0; i < numberOfCon; i++)
6850  {
6851  this->con[i] = new InitConValue();
6852  *this->con[i] = *con[i];
6853  }
6854 
6855  return true;
6856  }
6857  catch(const ErrorClass& eclass)
6858  {
6860  return false;
6861  }
6862 }//setCon
6863 
6864 bool InitConstraintValues::setCon(int numberOfCon, int *idx, double *value, std::string *name)
6865 {
6866  if (this->con != NULL)
6867  return false;
6868 
6869  if (numberOfCon < 0)
6870  return false;
6871 
6872  this->numberOfCon = numberOfCon;
6873  if (numberOfCon == 0)
6874  return true;
6875 
6876  this->con = new InitConValue*[numberOfCon];
6877 
6878  int i;
6879  for (i = 0; i < numberOfCon; i++)
6880  {
6881  this->con[i] = new InitConValue();
6882  this->con[i]->idx = idx[i];
6883  this->con[i]->name = name[i];
6884  this->con[i]->value = value[i];
6885  }
6886  return true;
6887 }//setCon
6888 
6889 
6890 
6897 bool InitConstraintValues::addCon(int idx, double value)
6898 {
6899  try
6900  {
6901  int nopt;
6902  int i;
6903  if (idx < 0)
6904  throw ErrorClass( "the index of a constraint cannot be negative." );
6905 
6906  if (this->con == NULL)
6907  nopt = 0;
6908  else
6909  nopt = this->numberOfCon;
6910 
6911  InitConValue** temp = new InitConValue*[nopt+1]; //Allocate the new pointers
6912  for (i = 0; i < nopt; i++)
6913  temp[i] = this->con[i]; //copy the pointers
6914 
6915  delete[] this->con; //delete old pointers
6916 
6917 // add in the new element
6918  temp[ nopt] = new InitConValue();
6919 
6920  temp[ nopt]->idx = idx;
6921  temp[ nopt]->value = value;
6922 
6923  this->con = temp; //hook the new pointers into the data structure
6924  this->numberOfCon = ++nopt;
6925 
6926  return true;
6927  }
6928  catch(const ErrorClass& eclass)
6929  {
6931  return false;
6932  }
6933 }//addCon
6934 
6940 bool InitConstraintValues::addCon(int numberOfCon, InitConValue **con)
6941 {
6942  try
6943  {
6944  if (numberOfCon < 0)
6945  throw ErrorClass( "length of con array cannot be negative.");
6946 
6947  if (numberOfCon == 0)
6948  return true;
6949 
6950  int nprev = this->numberOfCon;
6951 
6952  InitConValue** temp = new InitConValue*[nprev+numberOfCon]; //Allocate the new pointers
6953  for (int i = 0; i < nprev; i++)
6954  temp[i] = this->con[i]; //copy the pointers
6955 
6956  delete[] this->con; //delete old pointers
6957 
6958 // add in the new elements
6959  for (int i=0; i < numberOfCon; i++)
6960  {
6961  temp[nprev+i] = new InitConValue();
6962  *temp[nprev+i] = *con[i];
6963  }
6964 
6965  this->con = temp; //hook the new pointers into the data structure
6966  this->numberOfCon = nprev + numberOfCon;
6967 
6968  return true;
6969  }
6970  catch(const ErrorClass& eclass)
6971  {
6973  return false;
6974  }
6975 }//addCon
6976 
6977 
6985 {
6986  try
6987  {
6988  if (this->con != NULL)
6989  throw ErrorClass( "InitDualVarValue array previously used.");
6990 
6991  if (numberOfCon < 0)
6992  throw ErrorClass( "length of con array cannot be negative.");
6993 
6994  this->numberOfCon = numberOfCon;
6995  if (numberOfCon == 0)
6996  return true;
6997 
6998  this->con = new InitDualVarValue*[numberOfCon];
6999 
7000  int i;
7001  for (i = 0; i < numberOfCon; i++)
7002  {
7003  this->con[i] = new InitDualVarValue();
7004  *this->con[i] = *con[i];
7005  }
7006  return true;
7007  }
7008  catch(const ErrorClass& eclass)
7009  {
7011  return false;
7012  }
7013 }//setCon
7022 {
7023  try
7024  {
7025  if (this->con != NULL)
7026  {
7027  if (disp == ENUM_COMBINE_ARRAYS_throw)
7028  throw ErrorClass( "InitDualVarValue array previously used.");
7029  if (disp == ENUM_COMBINE_ARRAYS_ignore)
7030  return true;
7031  if (disp == ENUM_COMBINE_ARRAYS_merge)
7032  return this->addCon(numberOfCon, con);
7033 
7034  //here we replace the old data
7035  for (int i = 0; i < this->numberOfCon; i++)
7036  delete this->con[i];
7037  delete [] this->con;
7038  this->con = NULL;
7039  }
7040 
7041  if (numberOfCon < 0)
7042  throw ErrorClass( "length of con array cannot be negative.");
7043 
7044  this->numberOfCon = numberOfCon;
7045  if (numberOfCon == 0)
7046  return true;
7047 
7048  this->con = new InitDualVarValue*[numberOfCon];
7049 
7050  int i;
7051  for (i = 0; i < numberOfCon; i++)
7052  {
7053  this->con[i] = new InitDualVarValue();
7054  *this->con[i] = *con[i];
7055  }
7056  return true;
7057  }
7058  catch(const ErrorClass& eclass)
7059  {
7061  return false;
7062  }
7063 }//setCon
7064 
7065 bool InitDualVariableValues::setCon(int numberOfCon, int *idx, double *lbValue, double *ubValue, std::string *name)
7066 {
7067  if (this->con != NULL)
7068  return false;
7069 
7070  if (numberOfCon < 0)
7071  return false;
7072 
7073  this->numberOfCon = numberOfCon;
7074  if (numberOfCon == 0)
7075  return true;
7076 
7077  this->con = new InitDualVarValue*[numberOfCon];
7078 
7079  int i;
7080  for (i = 0; i < numberOfCon; i++)
7081  {
7082  this->con[i] = new InitDualVarValue();
7083  this->con[i]->idx = idx[i];
7084  this->con[i]->name = name[i];
7085  this->con[i]->lbDualValue = lbValue[i];
7086  this->con[i]->ubDualValue = ubValue[i];
7087  }
7088  return true;
7089 }//setCon
7090 
7091 
7099 bool InitDualVariableValues::addCon(int idx, double lbDualValue, double ubDualValue)
7100 {
7101  try
7102  {
7103  int nopt;
7104  int i;
7105  if (idx < 0)
7106  throw ErrorClass( "the index of a constraint cannot be negative." );
7107 
7108  if (this->con == NULL)
7109  nopt = 0;
7110  else
7111  nopt = this->numberOfCon;
7112 
7113  InitDualVarValue** temp = new InitDualVarValue*[nopt+1]; //Allocate the new pointers
7114  for (i = 0; i < nopt; i++)
7115  temp[i] = this->con[i]; //copy the pointers
7116 
7117  delete[] this->con; //delete old pointers
7118 
7119 // add in the new element
7120  temp[ nopt] = new InitDualVarValue();
7121 
7122  temp[ nopt]->idx = idx;
7123  temp[ nopt]->lbDualValue = lbDualValue;
7124  temp[ nopt]->ubDualValue = ubDualValue;
7125 
7126  this->con = temp; //hook the new pointers into the data structure
7127  this->numberOfCon = ++nopt;
7128 
7129  return true;
7130  }
7131  catch(const ErrorClass& eclass)
7132  {
7134  return false;
7135  }
7136 }//addCon
7137 
7144 {
7145  try
7146  {
7147  if (numberOfCon < 0)
7148  throw ErrorClass( "length of con array cannot be negative.");
7149 
7150  if (numberOfCon == 0)
7151  return true;
7152 
7153  int nprev = this->numberOfCon;
7154 
7155  InitDualVarValue** temp = new InitDualVarValue*[nprev+numberOfCon]; //Allocate the new pointers
7156  for (int i = 0; i < nprev; i++)
7157  temp[i] = this->con[i]; //copy the pointers
7158 
7159  delete[] this->con; //delete old pointers
7160 
7161 // add in the new elements
7162  for (int i=0; i < numberOfCon; i++)
7163  {
7164  temp[nprev+i] = new InitDualVarValue();
7165  *temp[nprev+i] = *con[i];
7166  }
7167 
7168  this->con = temp; //hook the new pointers into the data structure
7169  this->numberOfCon = nprev + numberOfCon;
7170 
7171  return true;
7172  }
7173  catch(const ErrorClass& eclass)
7174  {
7176  return false;
7177  }
7178 }//addCon
7179 
7186 bool OtherConstraintOption::setCon(int numberOfCon, OtherConOption **con)
7187 {
7188  try
7189  {
7190  if (this->con != NULL)
7191  throw ErrorClass( "OtherConOption array previously used.");
7192 
7193  if (numberOfCon < 0)
7194  throw ErrorClass( "length of <con> array cannot be negative.");
7195 
7196  this->numberOfCon = numberOfCon;
7197  if (numberOfCon == 0)
7198  return true;
7199 
7200  this->con = new OtherConOption*[numberOfCon];
7201 
7202  int i;
7203  for (i = 0; i < numberOfCon; i++)
7204  {
7205  this->con[i] = new OtherConOption();
7206  *this->con[i] = *con[i];
7207  }
7208  return true;
7209  }
7210  catch(const ErrorClass& eclass)
7211  {
7213  return false;
7214  }
7215 }//setCon
7216 
7225 bool OtherConstraintOption::addCon(int idx, std::string value, std::string lbValue, std::string ubValue)
7226 {
7227  try
7228  {
7229  int nopt;
7230  int i;
7231  if (idx < 0)
7232  throw ErrorClass( "the index of a variable cannot be negative." );
7233 
7234  if (this->con == NULL)
7235  nopt = 0;
7236  else
7237  nopt = this->numberOfCon;
7238 
7239  OtherConOption** temp = new OtherConOption*[nopt+1]; //Allocate the new pointers
7240  for (i = 0; i < nopt; i++)
7241  temp[i] = this->con[i]; //copy the pointers
7242 
7243  delete[] this->con; //delete old pointers
7244 
7245 // add in the new element
7246  temp[ nopt] = new OtherConOption();
7247 
7248  temp[ nopt]->idx = idx;
7249  temp[ nopt]->value = value;
7250  temp[ nopt]->lbValue = lbValue;
7251  temp[ nopt]->ubValue = ubValue;
7252 
7253  this->con = temp; //hook the new pointers into the data structure
7254  this->numberOfCon = ++nopt;
7255 
7256  return true;
7257  }
7258  catch(const ErrorClass& eclass)
7259  {
7261  return false;
7262  }
7263 }//addCon
7264 
7271 bool ConstraintOption::setOther(int numberOfOptions, OtherConstraintOption **other)
7272 {
7273  try
7274  {
7275  if (this->other != NULL)
7276  throw ErrorClass( "otherConstraintOptions array previously used.");
7277 
7278  if (numberOfOptions < 0)
7279  throw ErrorClass( "length of <other> array cannot be negative.");
7280 
7281  this->numberOfOtherConstraintOptions = numberOfOptions;
7282  if (numberOfOptions == 0)
7283  return true;
7284 
7285  this->other = new OtherConstraintOption*[numberOfOptions];
7286 
7287  int i, j;
7288  for (i = 0; i < numberOfOptions; i++)
7289  {
7290  this->other[i] = new OtherConstraintOption();
7291  this->other[i]->name = other[i]->name;
7292  this->other[i]->value = other[i]->value;
7293  this->other[i]->solver = other[i]->solver;
7294  this->other[i]->category = other[i]->category;
7295  this->other[i]->type = other[i]->type;
7296  this->other[i]->description = other[i]->description;
7297 
7298  if (other[i]->numberOfCon < 0)
7299  throw ErrorClass( "the number of constraints in otherConstraintOption cannot be negative.");
7300 
7301  this->other[i]->numberOfCon = other[i]->numberOfCon;
7302 
7303 
7304  if (other[i]->numberOfCon > 0)
7305  {
7306  this->other[i]->con = new OtherConOption*[other[i]->numberOfCon];
7307  for (j = 0; j < other[i]->numberOfCon; j++)
7308  {
7309  this->other[i]->con[j] = new OtherConOption();
7310 
7311  *this->other[i]->con[j] = *other[i]->con[j];
7312  }
7313  }
7314 
7315  this->other[i]->numberOfEnumerations = other[i]->numberOfEnumerations;
7316 
7317  if (this->other[i]->numberOfEnumerations > 0)
7318  {
7319  this->other[i]->enumeration = new OtherOptionOrResultEnumeration*[this->other[i]->numberOfEnumerations];
7320  for (j = 0; j < this->other[i]->numberOfEnumerations; j++)
7321  {
7322  this->other[i]->enumeration[j] = new OtherOptionOrResultEnumeration();
7323  this->other[i]->enumeration[j]->setOtherOptionOrResultEnumeration(
7324  other[i]->enumeration[j]->value,
7325  other[i]->enumeration[j]->description,
7326  other[i]->enumeration[j]->el,
7327  other[i]->enumeration[j]->numberOfEl);
7328  }
7329  }
7330 
7331  }
7332  return true;
7333  }
7334  catch(const ErrorClass& eclass)
7335  {
7337  return false;
7338  }
7339 }//setOther
7340 
7347 {
7348  try
7349  {
7350  int nopt, i, j;
7351  if (this->other == NULL)
7352  nopt = 0;
7353  else
7354  nopt = this->numberOfOtherConstraintOptions;
7355 
7356  OtherConstraintOption** temp = new OtherConstraintOption*[nopt+1]; //Allocate the new pointers
7357  for (i = 0; i < nopt; i++)
7358  temp[i] = this->other[i]; //copy the pointers
7359 
7360  delete[] this->other; //delete old pointers
7361 
7362 // add in the new element
7363  temp[ nopt] = new OtherConstraintOption();
7364  temp[ nopt]->name = other->name;
7365  temp[ nopt]->value = other->value;
7366  temp[ nopt]->solver = other->solver;
7367  temp[ nopt]->category = other->category;
7368  temp[ nopt]->type = other->type;
7369  temp[ nopt]->conType = other->conType;
7370  temp[ nopt]->enumType = other->enumType;
7371  temp[ nopt]->description = other->description;
7372 
7373  if (other->numberOfCon < 0)
7374  throw ErrorClass( "the number of constraints in otherConstraintOption cannot be negative.");
7375 
7376  temp[ nopt]->numberOfCon = other->numberOfCon;
7377  temp[ nopt]->numberOfEnumerations = other->numberOfEnumerations;
7378 
7379  if (other->numberOfCon > 0)
7380  {
7381  temp[ nopt]->con = new OtherConOption*[other->numberOfCon];
7382  for (j = 0; j < other->numberOfCon; j++)
7383  {
7384  temp[nopt]->con[j] = new OtherConOption();
7385  *temp[nopt]->con[j] = *other->con[j];
7386  }
7387  }
7388 
7389  if (other->numberOfEnumerations < 0)
7390  throw ErrorClass( "the number of enumerations in otherObjectiveOption cannot be negative.");
7391 
7392  if (other->numberOfEnumerations > 0)
7393  {
7395  for (j = 0; j < other->numberOfEnumerations; j++)
7396  {
7397  temp[ nopt]->enumeration[j] = new OtherOptionOrResultEnumeration();
7399  other->enumeration[j]->value,
7400  other->enumeration[j]->description,
7401  other->enumeration[j]->el,
7402  other->enumeration[j]->numberOfEl);
7403  }
7404  }
7405 
7406  this->other = temp; //hook the new pointers into the data structure
7407  this->numberOfOtherConstraintOptions = ++nopt;
7408 
7409  return true;
7410  }
7411  catch(const ErrorClass& eclass)
7412  {
7414  return false;
7415  }
7416 }//addOther
7417 
7424 bool SolverOptions::setSolverOptions(int numberOfOptions, SolverOption **solverOption)
7425 {
7426  try
7427  {
7428  if (this->solverOption != NULL)
7429  throw ErrorClass( "solverOptions array previously used.");
7430 
7431  if (numberOfOptions < 0)
7432  throw ErrorClass( "length of <solverOption> array cannot be negative.");
7433 
7434  this->numberOfSolverOptions = numberOfOptions;
7435  if (numberOfOptions == 0)
7436  return true;
7437 
7438  this->solverOption = new SolverOption*[numberOfOptions];
7439 
7440  int i;
7441  for (i = 0; i < numberOfOptions; i++)
7442  {
7443  this->solverOption[i] = new SolverOption();
7444 
7445  this->solverOption[i]->numberOfItems = solverOption[i]->numberOfItems;
7446  this->solverOption[i]->name = solverOption[i]->name;
7447  this->solverOption[i]->value = solverOption[i]->value;
7448  this->solverOption[i]->solver = solverOption[i]->solver;
7449  this->solverOption[i]->category = solverOption[i]->category;
7450  this->solverOption[i]->type = solverOption[i]->type;
7451  this->solverOption[i]->description = solverOption[i]->description;
7452 
7453  if (solverOption[i]->numberOfItems > 0)
7454  {
7455  this->solverOption[i]->item = new std::string[solverOption[i]->numberOfItems];
7456  for (int j=0; j<solverOption[i]->numberOfItems; j++)
7457  this->solverOption[i]->item[j] = solverOption[i]->item[j];
7458  }
7459  }
7460  return true;
7461  }
7462  catch(const ErrorClass& eclass)
7463  {
7465  return false;
7466  }
7467 }//setSolverOption
7468 
7469 
7480 bool SolverOptions::addSolverOption(std::string name, std::string value, std::string solver,
7481  std::string category, std::string type, std::string description)
7482 {
7483  try
7484  {
7485  int nopt;
7486  int i;
7487  if (name.empty() )
7488  throw ErrorClass( "the name of a solver option cannot be empty." );
7489 
7490  if (this->solverOption == NULL)
7491  nopt = 0;
7492  else
7493  nopt = this->numberOfSolverOptions;
7494 
7495  SolverOption** temp = new SolverOption*[nopt+1]; //Allocate the new pointers
7496  for (i = 0; i < nopt; i++)
7497  temp[i] = this->solverOption[i]; //copy the pointers
7498 
7499  delete[] this->solverOption; //delete old pointers
7500 
7501 // add in the new element
7502  temp[ nopt] = new SolverOption();
7503 
7504  temp[ nopt]->numberOfItems = 0;
7505  temp[ nopt]->name = name;
7506  temp[ nopt]->value = value;
7507  temp[ nopt]->solver = solver;
7508  temp[ nopt]->type = type;
7509  temp[ nopt]->category = category;
7510  temp[ nopt]->description = description;
7511 
7512  this->solverOption = temp; //hook the new pointers into the data structure
7513  this->numberOfSolverOptions = ++nopt;
7514 
7515  return true;
7516  }
7517  catch(const ErrorClass& eclass)
7518  {
7520  return false;
7521  }
7522 }//addSolverOption
7523 
7528 bool OSOption::setHeader(std::string name, std::string source,
7529  std::string description, std::string fileCreator, std::string licence)
7530 {
7531  if (this->optionHeader == NULL)
7532  this->optionHeader = new GeneralFileHeader();
7533  return this->optionHeader->setHeader(name, source, description, fileCreator, licence);
7534 }// end of OSOption::setHeader
7535 
7540 bool OSOption::setServiceURI( std::string serviceURI)
7541 {
7542  if (this->general == NULL)
7543  this->general = new GeneralOption();
7544  this->general->serviceURI = serviceURI;
7545  return true;
7546 }//setServiceURI
7547 
7548 bool OSOption::setServiceName( std::string serviceName)
7549 {
7550  if (this->general == NULL)
7551 
7552 
7553 
7554  this->general = new GeneralOption();
7555  this->general->serviceName = serviceName;
7556  return true;
7557 }//setServiceName
7558 
7559 bool OSOption::setInstanceName( std::string instanceName)
7560 {
7561  if (this->general == NULL)
7562  this->general = new GeneralOption();
7563  this->general->instanceName = instanceName;
7564  return true;
7565 }//setInstanceName
7566 
7567 bool OSOption::setInstanceLocation( std::string instanceLocation)
7568 {
7569  if (this->general == NULL)
7570  this->general = new GeneralOption();
7571  if (this->general->instanceLocation == NULL)
7573  this->general->instanceLocation->value = instanceLocation;
7574  return true;
7575 }//setInstanceLocation
7576 
7577 bool OSOption::setInstanceLocation( std::string instanceLocation, std::string locationType)
7578 {
7579  if (verifyLocationType(locationType) == 0)
7580  return false;
7581 
7582  if (this->general == NULL)
7583  this->general = new GeneralOption();
7584  if (this->general->instanceLocation == NULL)
7586  this->general->instanceLocation->value = instanceLocation;
7587  this->general->instanceLocation->locationType = locationType;
7588  return true;
7589 }//setInstanceLocation
7590 
7591 bool OSOption::setInstanceLocationType( std::string locationType)
7592 {
7593  try
7594  {
7595  if (this->general == NULL)
7596  this->general = new GeneralOption();
7597  if (this->general->instanceLocation == NULL)
7599 
7600  if (verifyLocationType(locationType) == 0)
7601  return false;
7602 
7603  this->general->instanceLocation->locationType = locationType;
7604  return true;
7605  }
7606  catch(const ErrorClass& eclass)
7607  {
7609  return false;
7610  }
7611 }//setLocationType
7612 
7613 bool OSOption::setJobID( std::string jobID)
7614 {
7615  if (this->general == NULL)
7616  this->general = new GeneralOption();
7617  this->general->jobID = jobID;
7618  return true;
7619 }//setJobID
7620 
7621 bool OSOption::setSolverToInvoke( std::string solverToInvoke)
7622 {
7623  if (this->general == NULL)
7624  this->general = new GeneralOption();
7625  this->general->solverToInvoke = solverToInvoke;
7626  return true;
7627 }//setSolverToInvoke
7628 
7629 bool OSOption::setLicense( std::string license)
7630 {
7631  if (this->general == NULL)
7632  this->general = new GeneralOption();
7633  this->general->license = license;
7634  return true;
7635 }//setLicense
7636 
7637 bool OSOption::setUserName( std::string userName)
7638 {
7639  if (this->general == NULL)
7640  this->general = new GeneralOption();
7641  this->general->userName = userName;
7642  return true;
7643 }//setUserName
7644 
7645 bool OSOption::setPassword( std::string password)
7646 {
7647  if (this->general == NULL)
7648  this->general = new GeneralOption();
7649  this->general->password = password;
7650  return true;
7651 }//setPassword
7652 
7653 bool OSOption::setContact( std::string contact)
7654 {
7655  if (this->general == NULL)
7656  this->general = new GeneralOption();
7657  if (this->general->contact == NULL)
7658  this->general->contact = new ContactOption();
7659  this->general->contact->value = contact;
7660  return true;
7661 }//setContact
7662 
7663 bool OSOption::setContact(std::string contact,std::string transportType)
7664 {
7665  if (verifyTransportType(transportType) == 0)
7666  return false;
7667 
7668  if (this->general == NULL)
7669  this->general = new GeneralOption();
7670  if (this->general->contact == NULL)
7671  this->general->contact = new ContactOption();
7672  this->general->contact->value = contact;
7673  this->general->contact->transportType = transportType;
7674  return true;
7675 }//setContact
7676 
7677 bool OSOption::setContactTransportType( std::string transportType)
7678 {
7679  try
7680  {
7681  if (this->general == NULL)
7682  this->general = new GeneralOption();
7683  if (this->general->contact == NULL)
7684  this->general->contact = new ContactOption();
7685 
7686  if (verifyTransportType(transportType) == 0)
7687  throw ErrorClass( "transport type not recognized.");
7688 
7689  this->general->contact->transportType = transportType;
7690  return true;
7691  }
7692  catch(const ErrorClass& eclass)
7693  {
7695  return false;
7696  }
7697 }//setContactTransportType
7698 
7699 bool OSOption::setOtherGeneralOptions(int numberOfOptions, OtherOption** other)
7700 {
7701  if (this->general == NULL)
7702  this->general = new GeneralOption();
7703  if (this->general->otherOptions == NULL)
7704  this->general->otherOptions = new OtherOptions();
7705  else
7706  {
7707  int i;
7708  for (i = 0; i < this->general->otherOptions->numberOfOtherOptions; i++)
7709  delete this->general->otherOptions->other[i];
7710  delete[] this->general->otherOptions->other;
7711  this->general->otherOptions->other = NULL;
7712  }
7713  return this->general->otherOptions->setOther(numberOfOptions, other);
7714 }//setOtherGeneralOptions
7715 
7716 bool OSOption::setAnOtherGeneralOption(std::string name, std::string value, std::string description)
7717 {
7718  if (this->general == NULL)
7719  this->general = new GeneralOption();
7720  if (this->general->otherOptions == NULL)
7721  this->general->otherOptions = new OtherOptions();
7722  return this->general->otherOptions->addOther(name, value, description);
7723 }//setAnOtherGeneralOption
7724 
7725 
7726 
7731 bool OSOption::setMinDiskSpace(std::string unit, std::string description, double value)
7732 {
7733  if (verifyStorageUnit(unit) == 0)
7734  return false;
7735 
7736  if (this->system == NULL)
7737  this->system = new SystemOption();
7738  if (this->system->minDiskSpace == NULL)
7739  this->system->minDiskSpace = new StorageCapacity();
7740  this->system->minDiskSpace->unit = unit;
7741  this->system->minDiskSpace->value = value;
7742  this->system->minDiskSpace->description = description;
7743  return true;
7744 }//setMinDiskSpace
7745 
7746 bool OSOption::setMinDiskSpace(double value)
7747 {
7748  if (this->system == NULL)
7749  this->system = new SystemOption();
7750  if (this->system->minDiskSpace == NULL)
7751  this->system->minDiskSpace = new StorageCapacity();
7752  this->system->minDiskSpace->value = value;
7753  return true;
7754 }//setMinDiskSpace
7755 
7756 bool OSOption::setMinDiskSpaceUnit(std::string unit)
7757 {
7758  try
7759  {
7760  if (this->system == NULL)
7761  this->system = new SystemOption();
7762  if (this->system->minDiskSpace == NULL)
7763  this->system->minDiskSpace = new StorageCapacity();
7764 
7765  if (verifyStorageUnit(unit) == 0)
7766  throw ErrorClass( "disk space unit not recognized.");
7767 
7768  this->system->minDiskSpace->unit = unit;
7769  return true;
7770  }
7771  catch(const ErrorClass& eclass)
7772  {
7774  return false;
7775  }
7776 }//setMinDiskSpaceUnit
7777 
7778 bool OSOption::setMinMemorySize(std::string unit, std::string description, double value)
7779 {
7780  if (verifyStorageUnit(unit) == 0)
7781  return false;
7782 
7783  if (this->system == NULL)
7784  this->system = new SystemOption();
7785  if (this->system->minMemorySize == NULL)
7786  this->system->minMemorySize = new StorageCapacity();
7787  this->system->minMemorySize->unit = unit;
7788  this->system->minMemorySize->value = value;
7789  this->system->minMemorySize->description = description;
7790  return true;
7791 }//setMinDiskSpace
7792 
7793 bool OSOption::setMinMemorySize(double value)
7794 {
7795  if (this->system == NULL)
7796  this->system = new SystemOption();
7797  if (this->system->minMemorySize == NULL)
7798  this->system->minMemorySize = new StorageCapacity();
7799  this->system->minMemorySize->value = value;
7800  return true;
7801 }//setMinMemorySize
7802 
7803 bool OSOption::setMinMemoryUnit(std::string unit)
7804 {
7805  try
7806  {
7807  if (this->system == NULL)
7808  this->system = new SystemOption();
7809  if (this->system->minMemorySize == NULL)
7810  this->system->minMemorySize = new StorageCapacity();
7811 
7812  if (verifyStorageUnit(unit) == 0)
7813  throw ErrorClass( "memory size unit not recognized.");
7814 
7815  this->system->minMemorySize->unit = unit;
7816  return true;
7817  }
7818  catch(const ErrorClass& eclass)
7819  {
7821  return false;
7822  }
7823 }//setMinMemoryUnit
7824 
7825 bool OSOption::setMinCPUSpeed(double value)
7826 {
7827  if (this->system == NULL)
7828  this->system = new SystemOption();
7829  if (this->system->minCPUSpeed == NULL)
7830  this->system->minCPUSpeed = new CPUSpeed();
7831  this->system->minCPUSpeed->value = value;
7832  return true;
7833 }//setMinCPUSpeed
7834 
7835 bool OSOption::setMinCPUSpeed(std::string unit, std::string description, double value)
7836 {
7837  if (verifyCPUSpeedUnit(unit) == 0)
7838  return false;
7839 
7840  if (this->system == NULL)
7841  this->system = new SystemOption();
7842  if (this->system->minCPUSpeed == NULL)
7843  this->system->minCPUSpeed = new CPUSpeed();
7844  this->system->minCPUSpeed->unit = unit;
7845  this->system->minCPUSpeed->value = value;
7846  this->system->minCPUSpeed->description = description;
7847  return true;
7848 }//setMinCPUSpeed
7849 
7850 bool OSOption::setMinCPUSpeedUnit(std::string unit)
7851 {
7852  try
7853  {
7854  if (this->system == NULL)
7855  this->system = new SystemOption();
7856  if (this->system->minCPUSpeed == NULL)
7857  this->system->minCPUSpeed = new CPUSpeed();
7858 
7859  if (verifyCPUSpeedUnit(unit) == 0)
7860  throw ErrorClass( "CPU speed unit not recognized.");
7861 
7862  this->system->minCPUSpeed->unit = unit;
7863  return true;
7864  }
7865  catch(const ErrorClass& eclass)
7866  {
7868  return false;
7869  }
7870 }//setMinCPUSpeedUnit
7871 
7873 {
7874  if (this->system == NULL)
7875  this->system = new SystemOption();
7876  if (this->system->minCPUNumber == NULL)
7877  this->system->minCPUNumber = new CPUNumber();
7878  this->system->minCPUNumber->value = number;
7879  return true;
7880 }//setMinCPUNumber
7881 
7882 bool OSOption::setMinCPUNumber(int number, std::string description)
7883 {
7884  if (this->system == NULL)
7885  this->system = new SystemOption();
7886  if (this->system->minCPUNumber == NULL)
7887  this->system->minCPUNumber = new CPUNumber();
7888  this->system->minCPUNumber->value = number;
7889  this->system->minCPUNumber->description = description;
7890  return true;
7891 }//setMinCPUNumber
7892 
7893 bool OSOption::setOtherSystemOptions(int numberOfOptions, OtherOption** other)
7894 {
7895  if (this->system == NULL)
7896  this->system = new SystemOption();
7897  if (this->system->otherOptions == NULL)
7898  this->system->otherOptions = new OtherOptions();
7899  else
7900  {
7901  int i;
7902  for (i = 0; i < this->system->otherOptions->numberOfOtherOptions; i++)
7903  delete this->system->otherOptions->other[i];
7904  delete[] this->system->otherOptions->other;
7905  this->system->otherOptions->other = NULL;
7906  this->system->otherOptions->numberOfOtherOptions = 0;
7907  }
7908  return this->system->otherOptions->setOther(numberOfOptions, other);
7909 }//setOtherSystemOptions
7910 
7911 bool OSOption::setAnOtherSystemOption(std::string name, std::string value, std::string description)
7912 {
7913  if (this->system == NULL)
7914  this->system = new SystemOption();
7915  if (this->system->otherOptions == NULL)
7916  this->system->otherOptions = new OtherOptions();
7917  return this->system->otherOptions->addOther(name, value, description);
7918 }//setAnOtherSystemOption
7919 
7920 
7925 bool OSOption::setServiceType( std::string serviceType)
7926 {
7927  try
7928  {
7929  if (this->service == NULL)
7930  this->service = new ServiceOption();
7931 
7932  if (verifyServiceType(serviceType) == 0)
7933  throw ErrorClass( "service type not recognized.");
7934 
7935  this->service->type = serviceType;
7936  return true;
7937  }
7938  catch(const ErrorClass& eclass)
7939  {
7941  return false;
7942  }
7943 }//setServiceType
7944 
7945 bool OSOption::setOtherServiceOptions(int numberOfOptions, OtherOption** other)
7946 {
7947  if (this->service == NULL)
7948  this->service = new ServiceOption();
7949  if (this->service->otherOptions == NULL)
7950  this->service->otherOptions = new OtherOptions();
7951  else
7952  {
7953  int i;
7954  for (i = 0; i < this->service->otherOptions->numberOfOtherOptions; i++)
7955  delete this->service->otherOptions->other[i];
7956  delete[] this->service->otherOptions->other;
7957  this->service->otherOptions->other = NULL;
7958  }
7959  return this->service->otherOptions->setOther(numberOfOptions, other);
7960 }//setOtherServiceOptions
7961 
7962 bool OSOption::setAnOtherServiceOption(std::string name, std::string value, std::string description)
7963 {
7964  if (this->service == NULL)
7965  this->service = new ServiceOption();
7966  if (this->service->otherOptions == NULL)
7967  this->service->otherOptions = new OtherOptions();
7968  return this->service->otherOptions->addOther(name, value, description);
7969 }//setAnOtherServiceOption
7970 
7975 bool OSOption::setMaxTime(double value)
7976 {
7977  if (this->job == NULL)
7978  this->job = new JobOption();
7979  if (this->job->maxTime == NULL)
7980  this->job->maxTime = new TimeSpan();
7981  this->job->maxTime->value = value;
7982  return true;
7983 }//setMaxTime
7984 
7985 bool OSOption::setMaxTime(double value, std::string unit)
7986 {
7987  if (verifyTimeUnit(unit) == 0)
7988  return false;
7989 
7990  if (this->job == NULL)
7991  this->job = new JobOption();
7992 
7993  if (this->job->maxTime == NULL)
7994  this->job->maxTime = new TimeSpan();
7995  this->job->maxTime->value = value;
7996  this->job->maxTime->unit = unit;
7997  return true;
7998 }//setMaxTime
7999 
8000 bool OSOption::setMaxTimeUnit(std::string unit)
8001 {
8002  try
8003  {
8004  if (this->job == NULL)
8005  this->job = new JobOption();
8006  if (this->job->maxTime == NULL)
8007  this->job->maxTime = new TimeSpan();
8008 
8009  if (verifyTimeUnit(unit) == 0)
8010  throw ErrorClass( "time unit not recognized.");
8011 
8012  this->job->maxTime->unit = unit;
8013  return true;
8014  }
8015  catch(const ErrorClass& eclass)
8016  {
8018  return false;
8019  }
8020 }//setMaxTimeUnit
8021 
8022 bool OSOption::setRequestedStartTime(std::string time)
8023 {
8024  if (this->job == NULL)
8025  this->job = new JobOption();
8026  this->job->requestedStartTime = time;
8027  return true;
8028 }//setRequestedStartTime
8029 
8030 
8031 bool OSOption::setJobDependencies(int numberOfDependencies, std::string* jobDependencies)
8032 {
8033  if (this->job == NULL)
8034  this->job = new JobOption();
8035  if (this->job->dependencies == NULL)
8036  this->job->dependencies = new JobDependencies();
8037  else
8038  delete[] this->job->dependencies->jobID;
8039  this->job->dependencies->jobID = NULL;
8040  return this->job->dependencies->setJobID(numberOfDependencies, jobDependencies);
8041 }//setJobDependencies
8042 
8043 bool OSOption::setAnotherJobDependency(std::string jobID)
8044 {
8045  if (this->job == NULL)
8046  this->job = new JobOption();
8047  if (this->job->dependencies == NULL)
8048  this->job->dependencies = new JobDependencies();
8049  return this->job->dependencies->addJobID(jobID);
8050 }//setAnotherJobDependency
8051 
8052 
8053 bool OSOption::setRequiredDirectories(int numberOfPaths, std::string* paths)
8054 {
8055  if (this->job == NULL)
8056  this->job = new JobOption();
8057  if (this->job->requiredDirectories == NULL)
8059  else
8060  delete[] this->job->requiredDirectories->path;
8061  this->job->requiredDirectories->path = NULL;
8062  return this->job->requiredDirectories->setPath(numberOfPaths, paths);
8063 }//setRequiredDirectories
8064 
8066 {
8067  if (this->job == NULL)
8068  this->job = new JobOption();
8069  if (this->job->requiredDirectories == NULL)
8071  return this->job->requiredDirectories->addPath(path);
8072 }//setAnotherRequiredDirectory
8073 
8074 
8075 bool OSOption::setRequiredFiles(int numberOfPaths, std::string* paths)
8076 {
8077  if (this->job == NULL)
8078  this->job = new JobOption();
8079  if (this->job->requiredFiles == NULL)
8080  this->job->requiredFiles = new DirectoriesAndFiles();
8081  else
8082  delete[] this->job->requiredFiles->path;
8083  this->job->requiredFiles->path = NULL;
8084  return this->job->requiredFiles->setPath(numberOfPaths, paths);
8085 }//setRequiredFiles
8086 
8087 bool OSOption::setAnotherRequiredFile(std::string path)
8088 {
8089  if (this->job == NULL)
8090  this->job = new JobOption();
8091  if (this->job->requiredFiles == NULL)
8092  this->job->requiredFiles = new DirectoriesAndFiles();
8093  return this->job->requiredFiles->addPath(path);
8094 }//setAnotherRequiredFile
8095 
8096 
8097 bool OSOption::setDirectoriesToMake(int numberOfPaths, std::string* paths)
8098 {
8099  if (this->job == NULL)
8100  this->job = new JobOption();
8101  if (this->job->directoriesToMake == NULL)
8102  this->job->directoriesToMake = new DirectoriesAndFiles();
8103  else
8104  delete[] this->job->directoriesToMake->path;
8105  this->job->directoriesToMake->path = NULL;
8106  return this->job->directoriesToMake->setPath(numberOfPaths, paths);
8107 }//setDirectoriesToMake
8108 
8110 {
8111  if (this->job == NULL)
8112  this->job = new JobOption();
8113  if (this->job->directoriesToMake == NULL)
8114  this->job->directoriesToMake = new DirectoriesAndFiles();
8115  return this->job->directoriesToMake->addPath(path);
8116 }//setAnotherDirectoryToMake
8117 
8118 
8119 bool OSOption::setFilesToMake(int numberOfPaths, std::string* paths)
8120 {
8121  if (this->job == NULL)
8122  this->job = new JobOption();
8123  if (this->job->filesToMake == NULL)
8124  this->job->filesToMake = new DirectoriesAndFiles();
8125  else
8126  delete[] this->job->filesToMake->path;
8127  this->job->filesToMake->path = NULL;
8128  return this->job->filesToMake->setPath(numberOfPaths, paths);
8129 }//setFilesToMake
8130 
8131 bool OSOption::setAnotherFileToMake(std::string path)
8132 {
8133  if (this->job == NULL)
8134  this->job = new JobOption();
8135  if (this->job->filesToMake == NULL)
8136  this->job->filesToMake = new DirectoriesAndFiles();
8137  return this->job->filesToMake->addPath(path);
8138 }//setAnotherFileToMake
8139 
8140 bool OSOption::setPathPairs(int object, std::string *from, std::string *to, bool *makeCopy, int numberOfPathPairs)
8141 {
8142  if (numberOfPathPairs < 0) return false;
8143  if (this->job == NULL)
8144  this->job = new JobOption();
8145  switch (object)
8146  {
8148  {
8149  if (this->job->inputDirectoriesToMove == NULL)
8150  this->job->inputDirectoriesToMove = new PathPairs();
8151  return this->job->inputDirectoriesToMove->setPathPair(from, to, makeCopy, numberOfPathPairs);
8152  }
8154  {
8155  if (this->job->inputFilesToMove == NULL)
8156  this->job->inputFilesToMove = new PathPairs();
8157  return this->job->inputFilesToMove->setPathPair(from, to, makeCopy, numberOfPathPairs);
8158  }
8160  {
8161  if (this->job->outputFilesToMove == NULL)
8162  this->job->outputFilesToMove = new PathPairs();
8163  return this->job->outputFilesToMove->setPathPair(from, to, makeCopy, numberOfPathPairs);
8164  }
8166  {
8167  if (this->job->outputDirectoriesToMove == NULL)
8168  this->job->outputDirectoriesToMove = new PathPairs();
8169  return this->job->outputDirectoriesToMove->setPathPair(from, to, makeCopy, numberOfPathPairs);
8170  }
8171  default:
8172  throw ErrorClass("target object not implemented in setPathPairs");
8173  }
8174 
8175 }//setPathPairs
8176 
8177 
8178 bool OSOption::setInputDirectoriesToMove(int numberOfPathPairs, PathPair** pathPair)
8179 {
8180  if (this->job == NULL)
8181  this->job = new JobOption();
8182  if (this->job->inputDirectoriesToMove == NULL)
8183  this->job->inputDirectoriesToMove = new PathPairs();
8184  else
8185  delete[] this->job->inputDirectoriesToMove->pathPair;
8186  this->job->inputDirectoriesToMove->pathPair = NULL;
8187  return this->job->inputDirectoriesToMove->setPathPair(numberOfPathPairs, pathPair);
8188 }//setInputDirectoriesToMove
8189 
8190 bool OSOption::setAnotherInputDirectoryToMove(std::string fromPath, std::string toPath, bool makeCopy)
8191 {
8192  if (this->job == NULL)
8193  this->job = new JobOption();
8194  if (this->job->inputDirectoriesToMove == NULL)
8195  this->job->inputDirectoriesToMove = new PathPairs();
8196  return this->job->inputDirectoriesToMove->addPathPair(fromPath, toPath, makeCopy);
8197 }//setAnotherInputDirectoryToMove
8198 
8199 
8200 bool OSOption::setInputFilesToMove(int numberOfPathPairs, PathPair** pathPair)
8201 {
8202  if (this->job == NULL)
8203  this->job = new JobOption();
8204  if (this->job->inputFilesToMove == NULL)
8205  this->job->inputFilesToMove = new PathPairs();
8206  else
8207  delete[] this->job->inputFilesToMove->pathPair;
8208  this->job->inputFilesToMove->pathPair = NULL;
8209  return this->job->inputFilesToMove->setPathPair(numberOfPathPairs, pathPair);
8210 }//setInputFilesToMove
8211 
8212 bool OSOption::setAnotherInputFileToMove(std::string fromPath, std::string toPath, bool makeCopy)
8213 {
8214  if (this->job == NULL)
8215  this->job = new JobOption();
8216  if (this->job->inputFilesToMove == NULL)
8217  this->job->inputFilesToMove = new PathPairs();
8218  return this->job->inputFilesToMove->addPathPair(fromPath, toPath, makeCopy);
8219 }//setAnotherInputFileToMove
8220 
8221 
8222 bool OSOption::setOutputFilesToMove(int numberOfPathPairs, PathPair** pathPair)
8223 {
8224  if (this->job == NULL)
8225  this->job = new JobOption();
8226  if (this->job->outputFilesToMove == NULL)
8227  this->job->outputFilesToMove = new PathPairs();
8228  else
8229  delete[] this->job->outputFilesToMove->pathPair;
8230  this->job->outputFilesToMove->pathPair = NULL;
8231  return this->job->outputFilesToMove->setPathPair(numberOfPathPairs, pathPair);
8232 }//setOutputFilesToMove
8233 
8234 bool OSOption::setAnotherOutputFileToMove(std::string fromPath, std::string toPath, bool makeCopy)
8235 {
8236  if (this->job == NULL)
8237  this->job = new JobOption();
8238  if (this->job->outputFilesToMove == NULL)
8239  this->job->outputFilesToMove = new PathPairs();
8240  return this->job->outputFilesToMove->addPathPair(fromPath, toPath, makeCopy);
8241 }//setAnotherOutputFileToMove
8242 
8243 
8244 bool OSOption::setOutputDirectoriesToMove(int numberOfPathPairs, PathPair** pathPair)
8245 {
8246  if (this->job == NULL)
8247  this->job = new JobOption();
8248  if (this->job->outputDirectoriesToMove == NULL)
8249  this->job->outputDirectoriesToMove = new PathPairs();
8250  else
8251  delete[] this->job->outputDirectoriesToMove->pathPair;
8252  this->job->outputDirectoriesToMove->pathPair = NULL;
8253  return this->job->outputDirectoriesToMove->setPathPair(numberOfPathPairs, pathPair);
8254 }//setOutputDirectoriesToMove
8255 
8256 bool OSOption::setAnotherOutputDirectoryToMove(std::string fromPath, std::string toPath, bool makeCopy)
8257 {
8258  if (this->job == NULL)
8259  this->job = new JobOption();
8260  if (this->job->outputDirectoriesToMove == NULL)
8261  this->job->outputDirectoriesToMove = new PathPairs();
8262  return this->job->outputDirectoriesToMove->addPathPair(fromPath, toPath, makeCopy);
8263 }//setAnotherOutputDirectoryToMove
8264 
8265 
8266 bool OSOption::setFilesToDelete(int numberOfPaths, std::string* paths)
8267 {
8268  if (this->job == NULL)
8269  this->job = new JobOption();
8270  if (this->job->filesToDelete == NULL)
8271  this->job->filesToDelete = new DirectoriesAndFiles();
8272  else
8273  delete[] this->job->filesToDelete->path;
8274  this->job->filesToDelete->path = NULL;
8275  return this->job->filesToDelete->setPath(numberOfPaths, paths);
8276 }//setFilesToDelete
8277 
8278 bool OSOption::setAnotherFileToDelete(std::string path)
8279 {
8280  if (this->job == NULL)
8281  this->job = new JobOption();
8282  if (this->job->filesToDelete == NULL)
8283  this->job->filesToDelete = new DirectoriesAndFiles();
8284  return this->job->filesToDelete->addPath(path);
8285 }//setAnotherFileToDelete
8286 
8287 
8288 bool OSOption::setDirectoriesToDelete(int numberOfPaths, std::string* paths)
8289 {
8290  if (this->job == NULL)
8291  this->job = new JobOption();
8292  if (this->job->directoriesToDelete == NULL)
8294  else
8295  delete[] this->job->directoriesToDelete->path;
8296  this->job->directoriesToDelete->path = NULL;
8297  return this->job->directoriesToDelete->setPath(numberOfPaths, paths);
8298 }//setDirectoriesToDelete
8299 
8301 {
8302  if (this->job == NULL)
8303  this->job = new JobOption();
8304  if (this->job->directoriesToDelete == NULL)
8306  return this->job->directoriesToDelete->addPath(path);
8307 }//setAnotherDirectoryToDelete
8308 
8309 
8310 bool OSOption::setProcessesToKill(int numberOfProcesses, std::string* processes)
8311 {
8312  if (this->job == NULL)
8313  this->job = new JobOption();
8314  if (this->job->processesToKill == NULL)
8315  this->job->processesToKill = new Processes();
8316  else
8317  delete[] this->job->processesToKill->process;
8318  this->job->processesToKill->process = NULL;
8319  return this->job->processesToKill->setProcess(numberOfProcesses, processes);
8320 }//setProcessesToKill
8321 
8322 bool OSOption::setAnotherProcessToKill(std::string process)
8323 {
8324  if (this->job == NULL)
8325  this->job = new JobOption();
8326  if (this->job->processesToKill == NULL)
8327  this->job->processesToKill = new Processes();
8328  return this->job->processesToKill->addProcess(process);
8329 }//setAnotherProcessToKill
8330 
8331 
8332 bool OSOption::setOtherJobOptions(int numberOfOptions, OtherOption** other)
8333 {
8334  if (this->job == NULL)
8335  this->job = new JobOption();
8336  if (this->job->otherOptions == NULL)
8337  this->job->otherOptions = new OtherOptions();
8338  else
8339  {
8340  int i;
8341  for (i = 0; i < this->job->otherOptions->numberOfOtherOptions; i++)
8342  delete this->job->otherOptions->other[i];
8343  delete[] this->job->otherOptions->other;
8344  this->job->otherOptions->other = NULL;
8345  }
8346  return this->job->otherOptions->setOther(numberOfOptions, other);
8347 }//setOtherJobOptions
8348 
8349 bool OSOption::setAnOtherJobOption(std::string name, std::string value, std::string description)
8350 {
8351  if (this->job == NULL)
8352  this->job = new JobOption();
8353  if (this->job->otherOptions == NULL)
8354  this->job->otherOptions = new OtherOptions();
8355  return this->job->otherOptions->addOther(name, value, description);
8356 }//setAnOtherJobOption
8357 
8358 
8359 
8360 bool OSOption::setNumberOfVariables(int numberOfVariables)
8361 {
8362  if (this->optimization == NULL)
8363  this->optimization = new OptimizationOption();
8364  this->optimization->numberOfVariables = numberOfVariables;
8365  return true;
8366 }//setNumberOfVariables
8367 
8368 bool OSOption::setNumberOfObjectives(int numberOfObjectives)
8369 {
8370  if (this->optimization == NULL)
8371  this->optimization = new OptimizationOption();
8372  this->optimization->numberOfObjectives = numberOfObjectives;
8373  return true;
8374 }//setNumberOfObjectives
8375 
8376 bool OSOption::setNumberOfConstraints(int numberOfConstraints)
8377 {
8378  if (this->optimization == NULL)
8379  this->optimization = new OptimizationOption();
8380  this->optimization->numberOfConstraints = numberOfConstraints;
8381  return true;
8382 }//setNumberOfConstraints
8383 
8384 
8385 bool OSOption::setInitVarValues(int numberOfVar, int* idx, double* value, std::string* name)
8386 {
8387  if (this->optimization == NULL)
8388  this->optimization = new OptimizationOption();
8389  if (this->optimization->variables == NULL)
8390  this->optimization->variables = new VariableOption();
8391  if (this->optimization->variables->initialVariableValues != NULL)
8392  return false;
8393 
8395 
8396  return this->optimization->variables->initialVariableValues->setVar(numberOfVar, idx, value, name);
8397 }//setInitVarValues
8398 
8400 {
8401  if (this->optimization == NULL)
8402  this->optimization = new OptimizationOption();
8403  if (this->optimization->variables == NULL)
8404  this->optimization->variables = new VariableOption();
8405  if (this->optimization->variables->initialVariableValues == NULL)
8407  else
8408  {
8409  int i;
8410  for (i = 0; i < this->optimization->variables->initialVariableValues->numberOfVar; i++)
8411  delete this->optimization->variables->initialVariableValues->var[i];
8412  delete[] this->optimization->variables->initialVariableValues->var;
8413  this->optimization->variables->initialVariableValues->var = NULL;
8414  }
8415  return this->optimization->variables->initialVariableValues->setVar(numberOfVar, var);
8416 }//setInitVarValuesSparse
8417 
8419 {
8420  if (this->optimization == NULL)
8421  this->optimization = new OptimizationOption();
8422  if (this->optimization->variables == NULL)
8423  this->optimization->variables = new VariableOption();
8424  if (this->optimization->variables->initialVariableValues == NULL)
8426  return this->optimization->variables->initialVariableValues->setVar(numberOfVar, var, disp);
8427 }//setInitVarValuesSparse
8428 
8429 bool OSOption::setInitVarValuesDense(int numberOfVar, double *value)
8430 {
8431  if (this->optimization == NULL)
8432  this->optimization = new OptimizationOption();
8433  if (this->optimization->variables == NULL)
8434  this->optimization->variables = new VariableOption();
8435  if (this->optimization->variables->initialVariableValues == NULL)
8437  else
8438  {
8439  delete[] this->optimization->variables->initialVariableValues->var;
8441  }
8442 
8443  int i;
8444  for (i = 0; i < numberOfVar; i++)
8445  {
8446 // if (!CoinIsnan(value[i]))
8447  if (!this->optimization->variables->initialVariableValues->addVar(i, value[i]))
8448  return false;
8449  }
8450  return true;
8451 }//setInitVarValuesDense
8452 
8453 bool OSOption::setAnotherInitVarValue(int idx, double value)
8454 {
8455  if (this->optimization == NULL)
8456  this->optimization = new OptimizationOption();
8457  if (this->optimization->variables == NULL)
8458  this->optimization->variables = new VariableOption();
8459  if (this->optimization->variables->initialVariableValues == NULL)
8461  return this->optimization->variables->initialVariableValues->addVar(idx, value);
8462 }//setAnotherInitVarValue
8463 
8464 bool OSOption::setInitVarValuesString(int numberOfVar, int* idx, std::string* value, std::string* name)
8465 {
8466  if (this->optimization == NULL)
8467  this->optimization = new OptimizationOption();
8468  if (this->optimization->variables == NULL)
8469  this->optimization->variables = new VariableOption();
8471  return false;
8472 
8474 
8475  return this->optimization->variables->initialVariableValuesString->setVar(numberOfVar, idx, value, name);
8476 }//setInitVarValuesString
8477 
8479 {
8480  if (this->optimization == NULL)
8481  this->optimization = new OptimizationOption();
8482  if (this->optimization->variables == NULL)
8483  this->optimization->variables = new VariableOption();
8486  else
8487 
8488 
8489  {
8490  int i;
8491  for (i = 0; i < this->optimization->variables->initialVariableValuesString->numberOfVar; i++)
8493  delete[] this->optimization->variables->initialVariableValuesString->var;
8494  this->optimization->variables->initialVariableValuesString->var = NULL;
8495  }
8496  return this->optimization->variables->initialVariableValuesString->setVar(numberOfVar, var);
8497 }//setInitVarValuesStringSparse
8498 
8500 {
8501  if (this->optimization == NULL)
8502  this->optimization = new OptimizationOption();
8503  if (this->optimization->variables == NULL)
8504  this->optimization->variables = new VariableOption();
8507  return this->optimization->variables->initialVariableValuesString->setVar(numberOfVar, var, disp);
8508 }//setInitVarValuesStringSparse
8509 
8510 bool OSOption::setInitVarValuesStringDense(int numberOfVar, std::string *value)
8511 {
8512  if (this->optimization == NULL)
8513  this->optimization = new OptimizationOption();
8514  if (this->optimization->variables == NULL)
8515  this->optimization->variables = new VariableOption();
8518  else
8519  {
8522  }
8523  int i;
8524  for (i = 0; i < numberOfVar; i++)
8525  {
8526  if (value[i] != "")
8527  if (!this->optimization->variables->initialVariableValuesString->addVar(i, value[i]))
8528  return false;
8529  }
8530  return true;
8531 }//setInitVarValuesStringDense
8532 
8533 bool OSOption::setAnotherInitVarValueString(int idx, std::string value)
8534 {
8535  if (this->optimization == NULL)
8536  this->optimization = new OptimizationOption();
8537  if (this->optimization->variables == NULL)
8538  this->optimization->variables = new VariableOption();
8541  return this->optimization->variables->initialVariableValuesString->addVar(idx, value);
8542 }//setAnotherInitVarValueString
8543 
8544 bool OSOption::setInitBasisStatus(int object, int status, int *i, int ni)
8545 {
8546  if (optimization == NULL) return false;
8547 
8548  switch (object)
8549  {
8551  {
8552  if (optimization->variables == NULL)
8556 
8557  for (int j=0; j<ni; j++)
8558  {
8559  if (i[j] < 0)
8560  return false;
8561  }
8562  return optimization->variables->initialBasisStatus->setIntVector(status, i, ni);
8563  }
8565  {
8566  if (optimization->objectives == NULL)
8570  for (int j=0; j<ni; j++)
8571  {
8572  if (i[j] >= 0)
8573  return false;
8574  }
8575  return optimization->objectives->initialBasisStatus->setIntVector(status, i, ni);
8576  }
8578  {
8579  if (optimization->constraints == NULL)
8583  for (int j=0; j<ni; j++)
8584  {
8585  if (i[j] < 0)
8586  return false;
8587  }
8588  return optimization->constraints->initialBasisStatus->setIntVector(status, i, ni);
8589  }
8590  default:
8591  throw ErrorClass("target object not implemented in setInitBasisStatus");
8592  }
8593 }//setInitBasisStatus
8594 
8595 bool OSOption::setAnotherInitBasisStatus(int object, int idx, int status)
8596 {
8597  if (optimization == NULL) return false;
8598 
8599  switch (object)
8600  {
8602  {
8603  if (optimization->variables == NULL)
8607  if (idx < 0) return false;
8608  return optimization->variables->initialBasisStatus->addIdx(status, idx);
8609  }
8611  {
8612  if (optimization->objectives == NULL)
8616  if (idx >= 0) return false;
8617  return optimization->objectives->initialBasisStatus->addIdx(status, idx);
8618  }
8620  {
8621  if (optimization->constraints == NULL)
8625  if (idx < 0) return false;
8626  return optimization->constraints->initialBasisStatus->addIdx(status, idx);
8627  }
8628  default:
8629  throw ErrorClass("target object not implemented in setAnotherInitBasisStatus");
8630  }
8631 }//setAnotherInitBasisStatus
8632 
8633 bool OSOption::setIntegerVariableBranchingWeights(int numberOfVar, int* idx, double* value, std::string* name)
8634 {
8635  if (this->optimization == NULL)
8636  this->optimization = new OptimizationOption();
8637  if (this->optimization->variables == NULL)
8638  this->optimization->variables = new VariableOption();
8640  return false;
8641 
8643 
8644  return this->optimization->variables->integerVariableBranchingWeights->setVar(numberOfVar, idx, value, name);
8645 }//setIntegerVariableBranchingWeights
8646 
8648 {
8649  if (this->optimization == NULL)
8650  this->optimization = new OptimizationOption();
8651  if (this->optimization->variables == NULL)
8652  this->optimization->variables = new VariableOption();
8655  else
8656  {
8657  int i;
8658  for (i = 0; i < this->optimization->variables->integerVariableBranchingWeights->numberOfVar; i++)
8660  delete[] this->optimization->variables->integerVariableBranchingWeights->var;
8661  this->optimization->variables->integerVariableBranchingWeights->var = NULL;
8662  }
8663  return this->optimization->variables->integerVariableBranchingWeights->setVar(numberOfVar, var);
8664 }//setIntegerVariableBranchingWeightsSparse
8665 
8667 {
8668  if (this->optimization == NULL)
8669  this->optimization = new OptimizationOption();
8670  if (this->optimization->variables == NULL)
8671  this->optimization->variables = new VariableOption();
8674  return this->optimization->variables->integerVariableBranchingWeights->setVar(numberOfVar, var, disp);
8675 }//setIntegerVariableBranchingWeightsSparse
8676 
8677 bool OSOption::setIntegerVariableBranchingWeightsDense(int numberOfVar, double *value)
8678 {
8679  if (this->optimization == NULL)
8680  this->optimization = new OptimizationOption();
8681  if (this->optimization->variables == NULL)
8682  this->optimization->variables = new VariableOption();
8685  else
8686  {
8689  }
8690  int i;
8691  for (i = 0; i < numberOfVar; i++)
8692  {
8693 // if (!CoinIsnan(value[i]))
8694  if (!this->optimization->variables->integerVariableBranchingWeights->addVar(i, value[i]))
8695  return false;
8696  }
8697  return true;
8698 }//setIntegerVariableBranchingWeightsDense
8699 
8701 {
8702  if (this->optimization == NULL)
8703  this->optimization = new OptimizationOption();
8704  if (this->optimization->variables == NULL)
8705  this->optimization->variables = new VariableOption();
8708  return this->optimization->variables->integerVariableBranchingWeights->addVar(idx, value);
8709 }//setAnotherIntegerVariableBranchingWeight
8710 
8711 
8713 {
8714  if (this->optimization == NULL)
8715  this->optimization = new OptimizationOption();
8716  if (this->optimization->variables == NULL)
8717  this->optimization->variables = new VariableOption();
8720  else
8721  {
8722  int i;
8723  for (i = 0; i < this->optimization->variables->sosVariableBranchingWeights->numberOfSOS; i++)
8725  delete[] this->optimization->variables->sosVariableBranchingWeights->sos;
8726  this->optimization->variables->sosVariableBranchingWeights->sos = NULL;
8727  }
8728  return this->optimization->variables->sosVariableBranchingWeights->setSOS(numberOfSOS, sos);
8729 }//setSOSVariableBranchingWeights
8730 
8731 bool OSOption::setAnotherSOSVariableBranchingWeight(int sosIdx, int nvar, double weight, int* idx, double* value, std::string* name)
8732 {
8733  if (this->optimization == NULL)
8734  this->optimization = new OptimizationOption();
8735  if (this->optimization->variables == NULL)
8736  this->optimization->variables = new VariableOption();
8739  return this->optimization->variables->sosVariableBranchingWeights->addSOS(sosIdx, nvar, weight, idx, value, name);
8740 }//setAnotherSOSVariableBranchingWeight
8741 
8743 {
8744  if (optimization == NULL)
8746  if (optimization->variables == NULL)
8748  if(optimization->variables->numberOfOtherVariableOptions < 0) return false;
8749 
8751 
8752  if (numberOfOther > 0)
8753  {
8754  optimization->variables->other = new OtherVariableOption*[numberOfOther];
8755 
8756  for (int j=0; j < numberOfOther; j++)
8758  }
8759 
8760  return true;
8761 }//setNumberOfOtherVariableOptions
8762 
8763 bool OSOption::setOtherVariableOptionAttributes(int iOther, int numberOfVar,
8764  int numberOfEnumerations, std::string name,
8765  std::string value, std::string solver,
8766  std::string category, std::string type,
8767  std::string varType, std::string enumType,
8768  std::string description)
8769 {
8770  if (optimization == NULL) return false;
8771  if (optimization->variables == NULL) return false;
8772  if (optimization->variables->other == NULL) return false;
8773 
8774  if (iOther < 0 || iOther >= optimization->variables->numberOfOtherVariableOptions) return false;
8775 
8776 
8777  optimization->variables->other[iOther]->numberOfVar = numberOfVar;
8778  optimization->variables->other[iOther]->numberOfEnumerations = numberOfEnumerations;
8779  optimization->variables->other[iOther]->name = name;
8780  optimization->variables->other[iOther]->value = value;
8781  optimization->variables->other[iOther]->solver = solver;
8782  optimization->variables->other[iOther]->category = category;
8783  optimization->variables->other[iOther]->type = type;
8784  optimization->variables->other[iOther]->varType = varType;
8785  optimization->variables->other[iOther]->enumType = enumType;
8786  optimization->variables->other[iOther]->description = description;
8787 
8788  if (numberOfVar > 0)
8789  {
8790  optimization->variables->other[iOther]->var = new OtherVarOption*[numberOfVar];
8791  for (int j=0; j<numberOfVar; j++)
8792  optimization->variables->other[iOther]->var[j] = new OtherVarOption();
8793  }
8794 
8795  if (numberOfEnumerations > 0)
8796  {
8797  optimization->variables->other[iOther]->enumeration = new OtherOptionOrResultEnumeration*[numberOfEnumerations];
8798  for (int j=0; j<numberOfEnumerations; j++)
8800  }
8801  return true;
8802 }//setOtherVariableOptionAttributes
8803 
8804 bool OSOption::setOtherOptionOrResultEnumeration(int object, int otherOptionNumber, int enumerationNumber,
8805  int numberOfEl, std::string value, std::string description, int* idxArray)
8806 {
8807  if (optimization == NULL) return false;
8808  if (numberOfEl < 0) return false;
8809 
8810  switch (object)
8811  {
8813  {
8814  if (optimization->variables == NULL) return false;
8815  if (optimization->variables->other == NULL) return false;
8816  if (otherOptionNumber < 0 || otherOptionNumber >= optimization->variables->numberOfOtherVariableOptions) return false;
8817  if (optimization->variables->other[otherOptionNumber] == NULL) return false;
8818  for (int j=0; j<numberOfEl; j++) if (idxArray[j] < 0) return false;
8819 
8820  if (optimization->variables->other[otherOptionNumber]->enumeration == NULL) return false;
8821  if (enumerationNumber < 0 || enumerationNumber >= optimization->variables->other[otherOptionNumber]->numberOfEnumerations) return false;
8822  if (optimization->variables->other[otherOptionNumber]->enumeration[enumerationNumber] == NULL) return false;
8823 
8824  return optimization->variables->other[otherOptionNumber]->enumeration[enumerationNumber]->setOtherOptionOrResultEnumeration(value, description, idxArray, numberOfEl);
8825  }
8826 
8828  {
8829  if (optimization->objectives == NULL) return false;
8830  if (optimization->objectives->other == NULL) return false;
8831  if (otherOptionNumber < 0 || otherOptionNumber >= optimization->objectives->numberOfOtherObjectiveOptions) return false;
8832  if (optimization->objectives->other[otherOptionNumber] == NULL) return false;
8833  for (int j=0; j<numberOfEl; j++) if (idxArray[j] >= 0) return false;
8834 
8835  if (optimization->objectives->other[otherOptionNumber]->enumeration == NULL) return false;
8836  if (enumerationNumber < 0 || enumerationNumber >= optimization->objectives->other[otherOptionNumber]->numberOfEnumerations) return false;
8837  if (optimization->objectives->other[otherOptionNumber]->enumeration[enumerationNumber] == NULL) return false;
8838 
8839  return optimization->objectives->other[otherOptionNumber]->enumeration[enumerationNumber]->setOtherOptionOrResultEnumeration(value, description, idxArray, numberOfEl);
8840  }
8841 
8843  {
8844  if (optimization->constraints == NULL) return false;
8845  if (optimization->constraints->other == NULL) return false;
8846  if (otherOptionNumber < 0 || otherOptionNumber >= optimization->constraints->numberOfOtherConstraintOptions) return false;
8847  if (optimization->constraints->other[otherOptionNumber] == NULL) return false;
8848  for (int j=0; j<numberOfEl; j++) if (idxArray[j] < 0) return false;
8849 
8850 
8851  if (optimization->constraints->other[otherOptionNumber]->enumeration == NULL) return false;
8852  if (enumerationNumber < 0 || enumerationNumber >= optimization->constraints->other[otherOptionNumber]->numberOfEnumerations) return false;
8853  if (optimization->constraints->other[otherOptionNumber]->enumeration[enumerationNumber] == NULL) return false;
8854 
8855  return optimization->constraints->other[otherOptionNumber]->enumeration[enumerationNumber]->setOtherOptionOrResultEnumeration(value, description, idxArray, numberOfEl);
8856  }
8857  default:
8858  throw ErrorClass("target object not implemented in setOtherOptionOrResultEnumeration");
8859  }
8860 
8861 }//setOtherOptionOrResultEnumeration
8862 
8863 bool OSOption::setOtherVariableOptionVar(int otherOptionNumber, int varNumber,
8864  int idx, std::string name, std::string value, std::string lbValue, std::string ubValue)
8865 {
8866  if (optimization == NULL) return false;
8867 
8868  if (optimization->variables == NULL) return false;
8869  if (optimization->variables->other == NULL) return false;
8870  if (otherOptionNumber < 0 || otherOptionNumber >= optimization->variables->numberOfOtherVariableOptions) return false;
8871  if (optimization->variables->other[otherOptionNumber] == NULL) return false;
8872  if (idx < 0) return false;
8873 
8874  if (optimization->variables->other[otherOptionNumber]->var == NULL) return false;
8875  if (varNumber < 0 || varNumber >= optimization->variables->other[otherOptionNumber]->numberOfVar) return false;
8876  if (optimization->variables->other[otherOptionNumber]->var[varNumber] == NULL) return false;
8877 
8878  optimization->variables->other[otherOptionNumber]->var[varNumber]->idx = idx;
8879  optimization->variables->other[otherOptionNumber]->var[varNumber]->name = name;
8880  optimization->variables->other[otherOptionNumber]->var[varNumber]->value = value;
8881  optimization->variables->other[otherOptionNumber]->var[varNumber]->lbValue = lbValue;
8882  optimization->variables->other[otherOptionNumber]->var[varNumber]->ubValue = ubValue;
8883  return true;
8884 }//setOtherVariableOptionVar
8885 
8886 
8887 bool OSOption::setOtherVariableOptions(int numberOfOptions, OtherVariableOption** other)
8888 {
8889  if (this->optimization == NULL)
8890  this->optimization = new OptimizationOption();
8891  if (this->optimization->variables == NULL)
8892  this->optimization->variables = new VariableOption();
8893  else
8894  {
8895  int i;
8896  for (i = 0; i < this->optimization->variables->numberOfOtherVariableOptions; i++)
8897  delete this->optimization->variables->other[i];
8898  delete[] this->optimization->variables->other;
8899  this->optimization->variables->other = NULL;
8900  }
8901  return this->optimization->variables->setOther(numberOfOptions, other);
8902 }//setOtherVariableOptions
8903 
8905 {
8906  if (this->optimization == NULL)
8907  this->optimization = new OptimizationOption();
8908  if (this->optimization->variables == NULL)
8909  this->optimization->variables = new VariableOption();
8910  return this->optimization->variables->addOther(optionValue);
8911 }//setAnOtherVariableOption
8912 
8913 bool OSOption::setInitObjValues(int numberOfObj, int* idx, double* value, std::string* name)
8914 {
8915  if (this->optimization == NULL)
8916  this->optimization = new OptimizationOption();
8917  if (this->optimization->objectives == NULL)
8918  this->optimization->objectives = new ObjectiveOption();
8919  if (this->optimization->objectives->initialObjectiveValues != NULL)
8920  return false;
8921 
8923 
8924  return this->optimization->objectives->initialObjectiveValues->setObj(numberOfObj, idx, value, name);
8925 }//setInitObjValues
8926 
8928 {
8929  if (this->optimization == NULL)
8930  this->optimization = new OptimizationOption();
8931  if (this->optimization->objectives == NULL)
8932  this->optimization->objectives = new ObjectiveOption();
8933  if (this->optimization->objectives->initialObjectiveValues == NULL)
8935  else
8936  {
8937  int i;
8938  for (i = 0; i < this->optimization->objectives->initialObjectiveValues->numberOfObj; i++)
8940  delete[] this->optimization->objectives->initialObjectiveValues->obj;
8941  this->optimization->objectives->initialObjectiveValues->obj = NULL;
8942  }
8943  return this->optimization->objectives->initialObjectiveValues->setObj(numberOfObj, obj);
8944 }//setInitObjValuesSparse
8945 
8947 {
8948  if (this->optimization == NULL)
8949  this->optimization = new OptimizationOption();
8950  if (this->optimization->objectives == NULL)
8951  this->optimization->objectives = new ObjectiveOption();
8952  if (this->optimization->objectives->initialObjectiveValues == NULL)
8954  return this->optimization->objectives->initialObjectiveValues->setObj(numberOfObj, obj, disp);
8955 }//setInitObjValuesSparse
8956 
8957 bool OSOption::setInitObjValuesDense(int numberOfObj, double *value)
8958 {
8959  if (this->optimization == NULL)
8960  this->optimization = new OptimizationOption();
8961  if (this->optimization->objectives == NULL)
8962  this->optimization->objectives = new ObjectiveOption();
8963  if (this->optimization->objectives->initialObjectiveValues == NULL)
8965  else
8966  {
8969  }
8970  int i;
8971  for (i = 0; i < numberOfObj; i++)
8972  {
8973 // if (!CoinIsnan(value[i]))
8974  if (!this->optimization->objectives->initialObjectiveValues->addObj(-1-i, value[i]))
8975  return false;
8976  }
8977  return true;
8978 }//setInitObjValuesDense
8979 
8980 bool OSOption::setAnotherInitObjValue(int idx, double value)
8981 {
8982  if (this->optimization == NULL)
8983  this->optimization = new OptimizationOption();
8984  if (this->optimization->objectives == NULL)
8985  this->optimization->objectives = new ObjectiveOption();
8986  if (this->optimization->objectives->initialObjectiveValues == NULL)
8988  return this->optimization->objectives->initialObjectiveValues->addObj(idx, value);
8989 }//setAnotherInitObjValue
8990 
8991 bool OSOption::setInitObjBounds(int numberOfObj, int* idx, double* lbValue, double* ubValue, std::string* name)
8992 {
8993  if (this->optimization == NULL)
8994  this->optimization = new OptimizationOption();
8995  if (this->optimization->objectives == NULL)
8996  this->optimization->objectives = new ObjectiveOption();
8997 
8998  if (this->optimization->objectives->initialObjectiveBounds != NULL)
8999  return false;
9000 
9002 
9003  return this->optimization->objectives->initialObjectiveBounds->setObj(numberOfObj, idx, lbValue, ubValue, name);
9004 }//setInitObjBounds
9005 
9007 {
9008  if (this->optimization == NULL)
9009  this->optimization = new OptimizationOption();
9010  if (this->optimization->objectives == NULL)
9011  this->optimization->objectives = new ObjectiveOption();
9012  if (this->optimization->objectives->initialObjectiveBounds == NULL)
9014  else
9015  {
9016  int i;
9017  for (i = 0; i < this->optimization->objectives->initialObjectiveBounds->numberOfObj; i++)
9019  delete[] this->optimization->objectives->initialObjectiveBounds->obj;
9020  this->optimization->objectives->initialObjectiveBounds->obj = NULL;
9021  }
9022  return this->optimization->objectives->initialObjectiveBounds->setObj(numberOfObj, obj);
9023 }//setInitObjBoundsSparse
9024 
9026 {
9027  if (this->optimization == NULL)
9028  this->optimization = new OptimizationOption();
9029  if (this->optimization->objectives == NULL)
9030  this->optimization->objectives = new ObjectiveOption();
9031  if (this->optimization->objectives->initialObjectiveBounds == NULL)
9033  return this->optimization->objectives->initialObjectiveBounds->setObj(numberOfObj, obj, disp);
9034 }//setInitObjBoundsSparse
9035 
9036 bool OSOption::setInitObjBoundsDense(int numberOfObj, double* lb, double* ub)
9037 {
9038  if (this->optimization == NULL)
9039  this->optimization = new OptimizationOption();
9040  if (this->optimization->objectives == NULL)
9041  this->optimization->objectives = new ObjectiveOption();
9042  if (this->optimization->objectives->initialObjectiveBounds == NULL)
9044  else
9045  {
9048  }
9049  int i;
9050  for (i = 0; i < numberOfObj; i++)
9051  {
9052  if (!this->optimization->objectives->initialObjectiveBounds->addObj(-1-i, lb[i], ub[i]))
9053  return false;
9054  }
9055  return true;
9056 }//setInitObjBoundsDense
9057 
9058 bool OSOption::setAnotherInitObjBound(int idx, double lb, double ub)
9059 {
9060  if (this->optimization == NULL)
9061  this->optimization = new OptimizationOption();
9062  if (this->optimization->objectives == NULL)
9063  this->optimization->objectives = new ObjectiveOption();
9064  if (this->optimization->objectives->initialObjectiveBounds == NULL)
9066  return this->optimization->objectives->initialObjectiveBounds->addObj(idx, lb, ub);
9067 }//setAnotherInitObjBound
9068 
9069 bool OSOption::setOtherObjectiveOptionObj(int otherOptionNumber, int objNumber,
9070  int idx, std::string name, std::string value, std::string lbValue, std::string ubValue)
9071 {
9072  if (optimization == NULL) return false;
9073 
9074  if (optimization->objectives == NULL) return false;
9075  if (optimization->objectives->other == NULL) return false;
9076  if (otherOptionNumber < 0 || otherOptionNumber >= optimization->objectives->numberOfOtherObjectiveOptions) return false;
9077  if (optimization->objectives->other[otherOptionNumber] == NULL) return false;
9078  if (idx >= 0) return false;
9079 
9080  if (optimization->objectives->other[otherOptionNumber]->obj == NULL) return false;
9081  if (objNumber < 0 || objNumber >= optimization->objectives->other[otherOptionNumber]->numberOfObj) return false;
9082  if (optimization->objectives->other[otherOptionNumber]->obj[objNumber] == NULL) return false;
9083 
9084  optimization->objectives->other[otherOptionNumber]->obj[objNumber]->idx = idx;
9085  optimization->objectives->other[otherOptionNumber]->obj[objNumber]->name = name;
9086  optimization->objectives->other[otherOptionNumber]->obj[objNumber]->value = value;
9087  optimization->objectives->other[otherOptionNumber]->obj[objNumber]->lbValue = lbValue;
9088  optimization->objectives->other[otherOptionNumber]->obj[objNumber]->ubValue = ubValue;
9089  return true;
9090 }//setOtherOptionObj
9091 
9093 {
9094  if (optimization == NULL) return false;
9095  if (optimization->objectives == NULL)
9097  if (optimization->objectives->numberOfOtherObjectiveOptions < 0) return false;
9098 
9100 
9101  if (numberOfOther > 0)
9102  {
9103  optimization->objectives->other = new OtherObjectiveOption*[numberOfOther];
9104 
9105  for (int j=0; j < numberOfOther; j++)
9107  }
9108  return true;
9109 
9110 }//setNumberOfOtherObjectiveOptions
9111 
9112 bool OSOption::setOtherObjectiveOptionAttributes(int iOther, int numberOfObj,
9113  int numberOfEnumerations, std::string name,
9114  std::string value, std::string solver,
9115  std::string category, std::string type,
9116  std::string objType, std::string enumType,
9117  std::string description)
9118 {
9119  if (optimization == NULL) return false;
9120  if (optimization->objectives == NULL) return false;
9121  if (optimization->objectives->other == NULL) return false;
9122 
9123  if (iOther < 0 || iOther >= optimization->objectives->numberOfOtherObjectiveOptions) return false;
9124 
9125  optimization->objectives->other[iOther]->numberOfObj = numberOfObj;
9126  optimization->objectives->other[iOther]->numberOfEnumerations = numberOfEnumerations;
9127  optimization->objectives->other[iOther]->name = name;
9128  optimization->objectives->other[iOther]->value = value;
9129  optimization->objectives->other[iOther]->solver = solver;
9130  optimization->objectives->other[iOther]->category = category;
9131  optimization->objectives->other[iOther]->type = type;
9132  optimization->objectives->other[iOther]->objType = objType;
9133  optimization->objectives->other[iOther]->enumType = enumType;
9134  optimization->objectives->other[iOther]->description = description;
9135 
9136  if (numberOfObj > 0)
9137  {
9138  optimization->objectives->other[iOther]->obj = new OtherObjOption*[numberOfObj];
9139  for (int j=0; j<numberOfObj; j++)
9140  optimization->objectives->other[iOther]->obj[j] = new OtherObjOption();
9141  }
9142 
9143  if (numberOfEnumerations > 0)
9144  {
9145  optimization->objectives->other[iOther]->enumeration = new OtherOptionOrResultEnumeration*[numberOfEnumerations];
9146  for (int j=0; j<numberOfEnumerations; j++)
9148  }
9149  return true;
9150 }//setOtherObjOptionAttributes
9151 
9153 {
9154  if (this->optimization == NULL)
9155  this->optimization = new OptimizationOption();
9156  if (this->optimization->objectives == NULL)
9157  this->optimization->objectives = new ObjectiveOption();
9158  else
9159  {
9160  int i;
9161  for (i = 0; i < this->optimization->objectives->numberOfOtherObjectiveOptions; i++)
9162  delete this->optimization->objectives->other[i];
9163  delete[] this->optimization->objectives->other;
9164  this->optimization->objectives->other = NULL;
9165  }
9166  return this->optimization->objectives->setOther(numberOfOptions, other);
9167 }//setOtherObjectiveOptions
9168 
9170 {
9171  if (this->optimization == NULL)
9172  this->optimization = new OptimizationOption();
9173  if (this->optimization->objectives == NULL)
9174  this->optimization->objectives = new ObjectiveOption();
9175  return this->optimization->objectives->addOther(optionValue);
9176 }//setAnOtherObjectiveOption
9177 
9178 
9179 bool OSOption::setInitConValues(int numberOfCon, int* idx, double* value, std::string* name)
9180 {
9181  if (this->optimization == NULL)
9182  this->optimization = new OptimizationOption();
9183  if (this->optimization->constraints == NULL)
9184  this->optimization->constraints = new ConstraintOption();
9185  if (this->optimization->constraints->initialConstraintValues != NULL)
9186  return false;
9187 
9189 
9190  return this->optimization->constraints->initialConstraintValues->setCon(numberOfCon, idx, value, name);
9191 }//setInitConValues
9192 
9193 
9195 {
9196  if (this->optimization == NULL)
9197  this->optimization = new OptimizationOption();
9198  if (this->optimization->constraints == NULL)
9199  this->optimization->constraints = new ConstraintOption();
9200  if (this->optimization->constraints->initialConstraintValues == NULL)
9202  else
9203  {
9204  int i;
9205  for (i = 0; i < this->optimization->constraints->initialConstraintValues->numberOfCon; i++)
9207  delete[] this->optimization->constraints->initialConstraintValues->con;
9208  this->optimization->constraints->initialConstraintValues->con = NULL;
9209  }
9210  return this->optimization->constraints->initialConstraintValues->setCon(numberOfCon, con);
9211 }//setInitConValuesSparse
9212 
9214 {
9215  if (this->optimization == NULL)
9216  this->optimization = new OptimizationOption();
9217  if (this->optimization->constraints == NULL)
9218  this->optimization->constraints = new ConstraintOption();
9219  if (this->optimization->constraints->initialConstraintValues == NULL)
9221  return this->optimization->constraints->initialConstraintValues->setCon(numberOfCon, con, disp);
9222 }//setInitConValuesSparse
9223 
9224 bool OSOption::setInitConValuesDense(int numberOfCon, double *value)
9225 {
9226  if (this->optimization == NULL)
9227  this->optimization = new OptimizationOption();
9228  if (this->optimization->constraints == NULL)
9229  this->optimization->constraints = new ConstraintOption();
9230  if (this->optimization->constraints->initialConstraintValues == NULL)
9232  else
9233  {
9236  }
9237  int i;
9238  for (i = 0; i < numberOfCon; i++)
9239  {
9240 // if (!CoinIsnan(value[i]))
9241  if (!this->optimization->constraints->initialConstraintValues->addCon(i, value[i]))
9242  return false;
9243  }
9244  return true;
9245 }//setInitConValuesDense
9246 
9247 bool OSOption::setAnotherInitConValue(int idx, double value)
9248 {
9249  if (this->optimization == NULL)
9250  this->optimization = new OptimizationOption();
9251  if (this->optimization->constraints == NULL)
9252  this->optimization->constraints = new ConstraintOption();
9253  if (this->optimization->constraints->initialConstraintValues == NULL)
9255  return this->optimization->constraints->initialConstraintValues->addCon(idx, value);
9256 }//setAnotherInitConValue
9257 
9258 bool OSOption::setInitDualValues(int numberOfCon, int* idx, double* lbValue, double* ubValue, std::string* name)
9259 {
9260  if (this->optimization == NULL)
9261  this->optimization = new OptimizationOption();
9262  if (this->optimization->constraints == NULL)
9263  this->optimization->constraints = new ConstraintOption();
9264  if (this->optimization->constraints->initialDualValues != NULL)
9265  return false;
9266 
9268 
9269  return this->optimization->constraints->initialDualValues->setCon(numberOfCon, idx, lbValue, ubValue, name);
9270 }//setInitDualValues
9271 
9273 {
9274  if (this->optimization == NULL)
9275  this->optimization = new OptimizationOption();
9276  if (this->optimization->constraints == NULL)
9277  this->optimization->constraints = new ConstraintOption();
9278  if (this->optimization->constraints->initialDualValues == NULL)
9280  else
9281  {
9282  int i;
9283  for (i = 0; i < this->optimization->constraints->initialDualValues->numberOfCon; i++)
9284  delete this->optimization->constraints->initialDualValues->con[i];
9285  delete[] this->optimization->constraints->initialDualValues->con;
9286  this->optimization->constraints->initialDualValues->con = NULL;
9287  }
9288  return this->optimization->constraints->initialDualValues->setCon(numberOfCon, con);
9289 }//setInitDualVarValuesSparse
9290 
9292 {
9293  if (this->optimization == NULL)
9294  this->optimization = new OptimizationOption();
9295  if (this->optimization->constraints == NULL)
9296  this->optimization->constraints = new ConstraintOption();
9297  if (this->optimization->constraints->initialDualValues == NULL)
9299  return this->optimization->constraints->initialDualValues->setCon(numberOfCon, con, disp);
9300 }//setInitDualVarValuesSparse
9301 
9302 bool OSOption::setInitDualVarValuesDense(int numberOfCon, double* lb, double* ub)
9303 {
9304  if (this->optimization == NULL)
9305  this->optimization = new OptimizationOption();
9306  if (this->optimization->constraints == NULL)
9307  this->optimization->constraints = new ConstraintOption();
9308  if (this->optimization->constraints->initialDualValues == NULL)
9310  else
9311  {
9312  delete[] this->optimization->constraints->initialDualValues->con;
9314  }
9315  int i;
9316  for (i = 0; i < numberOfCon; i++)
9317  {
9318  if ((lb[i] != 0.0) || (ub[i] != 0.0))
9319  if (!this->optimization->constraints->initialDualValues->addCon(i, lb[i], ub[i]))
9320  return false;
9321  }
9322  return true;
9323 }//setInitDualVarValuesDense
9324 
9325 bool OSOption::setAnotherInitDualVarValue(int idx, double lbValue, double ubValue)
9326 {
9327  if (this->optimization == NULL)
9328  this->optimization = new OptimizationOption();
9329  if (this->optimization->constraints == NULL)
9330  this->optimization->constraints = new ConstraintOption();
9331  if (this->optimization->constraints->initialDualValues == NULL)
9333  return this->optimization->constraints->initialDualValues->addCon(idx, lbValue, ubValue);
9334 }//setAnotherInitConValue
9335 
9337 {
9338  if (optimization == NULL) return false;
9339  if (optimization->constraints == NULL)
9342 
9344 
9345  if (numberOfOther > 0)
9346  {
9347  optimization->constraints->other = new OtherConstraintOption*[numberOfOther];
9348 
9349  for (int j=0; j < numberOfOther; j++)
9351  }
9352 
9353  return true;
9354 }//setNumberOfOtherConstraintOptions
9355 
9356 bool OSOption::setOtherConstraintOptionAttributes(int iOther, int numberOfCon,
9357  int numberOfEnumerations, std::string name,
9358  std::string value, std::string solver,
9359  std::string category, std::string type,
9360  std::string conType, std::string enumType,
9361  std::string description)
9362 {
9363  if (optimization == NULL) return false;
9364  if (optimization->constraints == NULL) return false;
9365  if (optimization->constraints->other == NULL) return false;
9366  if (iOther < 0 || iOther >= optimization->constraints->numberOfOtherConstraintOptions) return false;
9367 
9368  optimization->constraints->other[iOther]->numberOfCon = numberOfCon;
9369  optimization->constraints->other[iOther]->numberOfEnumerations = numberOfEnumerations;
9370  optimization->constraints->other[iOther]->name = name;
9371  optimization->constraints->other[iOther]->value = value;
9372  optimization->constraints->other[iOther]->solver = solver;
9373  optimization->constraints->other[iOther]->category = category;
9374  optimization->constraints->other[iOther]->type = type;
9375  optimization->constraints->other[iOther]->conType = conType;
9376  optimization->constraints->other[iOther]->enumType = enumType;
9377  optimization->constraints->other[iOther]->description = description;
9378 
9379  if (numberOfCon > 0)
9380  {
9381  optimization->constraints->other[iOther]->con = new OtherConOption*[numberOfCon];
9382  for (int j=0; j<numberOfCon; j++)
9383  optimization->constraints->other[iOther]->con[j] = new OtherConOption();
9384  }
9385 
9386  if (numberOfEnumerations > 0)
9387  {
9388  optimization->constraints->other[iOther]->enumeration = new OtherOptionOrResultEnumeration*[numberOfEnumerations];
9389  for (int j=0; j<numberOfEnumerations; j++)
9391  }
9392  return true;
9393 }//setOtherConOptionAttributes
9394 
9395 
9396 bool OSOption::setOtherConstraintOptionCon(int otherOptionNumber, int conNumber,
9397  int idx, std::string name, std::string value, std::string lbValue, std::string ubValue)
9398 {
9399  if (optimization == NULL) return false;
9400 
9401  if (optimization->constraints == NULL) return false;
9402  if (optimization->constraints->other == NULL) return false;
9403  if (otherOptionNumber < 0 || otherOptionNumber >= optimization->constraints->numberOfOtherConstraintOptions) return false;
9404  if (optimization->constraints->other[otherOptionNumber] == NULL) return false;
9405  if (idx < 0) return false;
9406 
9407  if (optimization->constraints->other[otherOptionNumber]->con == NULL) return false;
9408  if (conNumber < 0 || conNumber >= optimization->constraints->other[otherOptionNumber]->numberOfCon) return false;
9409  if (optimization->constraints->other[otherOptionNumber]->con[conNumber] == NULL) return false;
9410 
9411  optimization->constraints->other[otherOptionNumber]->con[conNumber]->idx = idx;
9412  optimization->constraints->other[otherOptionNumber]->con[conNumber]->name = name;
9413  optimization->constraints->other[otherOptionNumber]->con[conNumber]->value = value;
9414  optimization->constraints->other[otherOptionNumber]->con[conNumber]->lbValue = lbValue;
9415  optimization->constraints->other[otherOptionNumber]->con[conNumber]->ubValue = ubValue;
9416  return true;
9417 }//setOtherOptionCon
9418 
9419 
9420 
9422 {
9423  if (this->optimization == NULL)
9424  this->optimization = new OptimizationOption();
9425  if (this->optimization->constraints == NULL)
9426  this->optimization->constraints = new ConstraintOption();
9427  else
9428  {
9429  int i;
9430  for (i = 0; i < this->optimization->constraints->numberOfOtherConstraintOptions; i++)
9431  delete this->optimization->constraints->other[i];
9432  delete[] this->optimization->constraints->other;
9433  this->optimization->constraints->other = NULL;
9434  }
9435  return this->optimization->constraints->setOther(numberOfOptions, other);
9436 }//setOtherConstraintOptions
9437 
9439 {
9440  if (this->optimization == NULL)
9441  this->optimization = new OptimizationOption();
9442  if (this->optimization->constraints == NULL)
9443  this->optimization->constraints = new ConstraintOption();
9444  return this->optimization->constraints->addOther(optionValue);
9445 }//setAnOtherConstraintOption
9446 
9447 
9448 bool OSOption::setNumberOfSolverOptions(int numberOfOptions)
9449 {
9450  if (optimization == NULL) return false;
9451  if (optimization->solverOptions != NULL) return false;
9452 
9454  optimization->solverOptions->numberOfSolverOptions = numberOfOptions;
9455  optimization->solverOptions->solverOption = new SolverOption*[numberOfOptions];
9456 
9457  for (int j=0; j < numberOfOptions; j++)
9459  return true;
9460 }//setNumberOfSolverOptions
9461 
9462 bool OSOption::setSolverOptionContent(int iOption, int numberOfItems,
9463  std::string name,
9464  std::string value, std::string solver,
9465  std::string category, std::string type,
9466  std::string description, std::string *itemList)
9467 {
9468  if (optimization == NULL) return false;
9469  if (optimization->solverOptions == NULL) return false;
9470  if (optimization->solverOptions->solverOption == NULL) return false;
9471 
9472  if (iOption < 0 || iOption >= optimization->solverOptions->numberOfSolverOptions) return false;
9473 
9474  optimization->solverOptions->solverOption[iOption]->numberOfItems = numberOfItems;
9475  optimization->solverOptions->solverOption[iOption]->name = name;
9476  optimization->solverOptions->solverOption[iOption]->value = value;
9477  optimization->solverOptions->solverOption[iOption]->solver = solver;
9478  optimization->solverOptions->solverOption[iOption]->category = category;
9479  optimization->solverOptions->solverOption[iOption]->type = type;
9480  optimization->solverOptions->solverOption[iOption]->description = description;
9481 
9482  if (numberOfItems > 0)
9483  {
9484  optimization->solverOptions->solverOption[iOption]->item = new std::string[numberOfItems];
9485  for (int j=0; j<numberOfItems; j++)
9486  optimization->solverOptions->solverOption[iOption]->item[j] = itemList[j];
9487  }
9488 
9489  return true;
9490 }//setSolverOptionContent
9491 
9492 bool OSOption::setSolverOptions(int numberOfSolverOptions, SolverOption** solverOption)
9493 {
9494  if (this->optimization == NULL)
9495  this->optimization = new OptimizationOption();
9496  if (this->optimization->solverOptions == NULL)
9497  this->optimization->solverOptions = new SolverOptions();
9498  else
9499  {
9500  int i;
9501  for (i = 0; i < this->optimization->solverOptions->numberOfSolverOptions; i++)
9502  delete this->optimization->solverOptions->solverOption[i];
9503  delete[] this->optimization->solverOptions->solverOption;
9504  this->optimization->solverOptions->solverOption = NULL;
9505  }
9506  return this->optimization->solverOptions->setSolverOptions(numberOfSolverOptions, solverOption);
9507 }//setSolverOptions
9508 
9509 bool OSOption::setAnotherSolverOption(std::string name, std::string value, std::string solver,
9510  std::string category, std::string type, std::string description)
9511 {
9512  if (this->optimization == NULL)
9513  this->optimization = new OptimizationOption();
9514  if (this->optimization->solverOptions == NULL)
9515  this->optimization->solverOptions = new SolverOptions();
9516  return this->optimization->solverOptions->addSolverOption(name, value, solver, category, type, description);
9517 }//setAnotherSolverOption
9518 
9519 
9520 bool OSOption::setOptionStr(std::string optionName, std::string optionValue)
9521 {
9522  if (optionName == "serviceURI")
9523  return this->setServiceURI(optionValue);
9524 
9525  if (optionName == "serviceName")
9526  return this->setServiceName(optionValue);
9527 
9528  if (optionName == "instanceName")
9529  return this->setInstanceName(optionValue);
9530 
9531  if (optionName == "instanceLocation")
9532  return this->setInstanceLocation(optionValue);
9533 
9534  if (optionName == "locationType")
9535  return this->setInstanceLocationType(optionValue);
9536 
9537  if (optionName == "jobID")
9538  return this->setJobID(optionValue);
9539 
9540  if (optionName == "solverName")
9541  return this->setSolverToInvoke(optionValue);
9542 
9543  if (optionName == "solverToInvoke")
9544  return this->setSolverToInvoke(optionValue);
9545 
9546  if (optionName == "license")
9547  return this->setLicense(optionValue);
9548 
9549  if (optionName == "userName")
9550  return this->setUserName(optionValue);
9551 
9552  if (optionName == "password")
9553  return this->setPassword(optionValue);
9554 
9555  if (optionName == "contact")
9556  return this->setContact(optionValue);
9557 
9558  if (optionName == "transportType")
9559  return this->setContactTransportType(optionValue);
9560 
9561  if (optionName == "minDiskSpaceUnit")
9562  return this->setMinDiskSpaceUnit(optionValue);
9563 
9564  if (optionName == "minMemoryUnit")
9565  return this->setMinMemoryUnit(optionValue);
9566 
9567  if (optionName == "minCPUSpeedUnit")
9568  return this->setMinCPUSpeedUnit(optionValue);
9569 
9570  if (optionName == "serviceType")
9571  return this->setServiceType(optionValue);
9572 
9573  if (optionName == "maxTimeUnit")
9574  return this->setMaxTimeUnit(optionValue);
9575 
9576  if (optionName == "requestedStartTime")
9577  return this->setRequestedStartTime(optionValue);
9578 
9579  return false;
9580 }//setOptionStr
9581 
9582 
9583 bool OSOption::setOptionInt(std::string optionName, int optionValue)
9584 {
9585  if (optionName == "minCPUNumber")
9586  return this->setMinCPUNumber(optionValue);
9587 
9588  return false;
9589 }//setOptionInt
9590 
9591 
9592 bool OSOption::setOptionDbl(std::string optionName, double value)
9593 {
9594  if (optionName == "minDiskSpaceValue")
9595  return this->setMinDiskSpace(value);
9596 
9597  if (optionName == "minMemoryValue")
9598  return this->setMinMemorySize(value);
9599 
9600  if (optionName == "minCPUSpeedValue")
9601 
9602  return this->setMinCPUSpeed(value);
9603 
9604  if (optionName == "maxTime")
9605  return this->setMaxTime(value);
9606 
9607  return false;
9608 }//setOptionDbl
9609 
9610 /***************************************************
9611  * methods to test whether two OSOption objects
9612  * or their components are equal to each other
9613  ***************************************************/
9615 {
9616 #ifndef NDEBUG
9617  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in OSOption");
9618 #endif
9619  if (this == NULL)
9620  {
9621  if (that == NULL)
9622  return true;
9623  else
9624  {
9625 #ifndef NDEBUG
9626  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
9627 #endif
9628  return false;
9629  }
9630  }
9631  else
9632  {
9633  if (that == NULL)
9634  {
9635 #ifndef NDEBUG
9636  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
9637 #endif
9638  return false;
9639  }
9640  else
9641  {
9642  if (!this->optionHeader->IsEqual(that->optionHeader))
9643  return false;
9644  if (!this->general->IsEqual(that->general))
9645  return false;
9646  if (!this->system->IsEqual(that->system))
9647 
9648  return false;
9649  if (!this->service->IsEqual(that->service))
9650  return false;
9651  if (!this->job->IsEqual(that->job))
9652  return false;
9653  if (!this->optimization->IsEqual(that->optimization))
9654  return false;
9655  return true;
9656  }
9657  }
9658 }//OSOption::IsEqual
9659 
9660 
9662 {
9663  std::ostringstream outStr;
9664 
9665 #ifndef NDEBUG
9666  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in GeneralOption");
9667 #endif
9668  if (this == NULL)
9669  {
9670  if (that == NULL)
9671  return true;
9672  else
9673  {
9674 #ifndef NDEBUG
9675  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
9676 #endif
9677  return false;
9678  }
9679  }
9680  else
9681  {
9682  if (that == NULL)
9683  {
9684 #ifndef NDEBUG
9685  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
9686 #endif
9687  return false;
9688  }
9689  else
9690  {
9691  bool same;
9692  same = (this->serviceURI == that->serviceURI);
9693  same = ((this->serviceName == that->serviceName ) && same);
9694  same = ((this->instanceName == that->instanceName ) && same);
9695  same = ((this->jobID == that->jobID ) && same);
9696  same = ((this->solverToInvoke == that->solverToInvoke) && same);
9697  same = ((this->license == that->license ) && same);
9698  same = ((this->userName == that->userName ) && same);
9699  same = ((this->password == that->password ) && same);
9700  if (!same)
9701  {
9702 #ifndef NDEBUG
9703  outStr.str("");
9704  outStr.clear();
9705  outStr << "serviceURI: " << this->serviceURI << " vs. " << that->serviceURI << endl;
9706  outStr << "serviceName: " << this->serviceName << " vs. " << that->serviceName << endl;
9707  outStr << "instanceName: " << this->instanceName << " vs. " << that->instanceName << endl;
9708  outStr << "jobID: " << this->jobID << " vs. " << that->jobID << endl;
9709  outStr << "solverToInvoke:" << this->solverToInvoke << " vs. " << that->solverToInvoke << endl;
9710  outStr << "license: " << this->license << " vs. " << that->license << endl;
9711  outStr << "userName: " << this->userName << " vs. " << that->userName << endl;
9712  outStr << "password: " << this->password << " vs. " << that->password << endl;
9714 #endif
9715  return false;
9716  }
9717  if (!this->instanceLocation->IsEqual(that->instanceLocation))
9718  return false;
9719  if (!this->contact->IsEqual(that->contact))
9720  return false;
9721  if (!this->otherOptions->IsEqual(that->otherOptions))
9722  return false;
9723  return true;
9724  }
9725  }
9726 }//GeneralOption::IsEqual
9727 
9728 
9730 {
9731 #ifndef NDEBUG
9732  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in SystemOption");
9733 #endif
9734  if (this == NULL)
9735  {
9736  if (that == NULL)
9737  return true;
9738  else
9739  {
9740 #ifndef NDEBUG
9741  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
9742 #endif
9743  return false;
9744  }
9745  }
9746  else
9747  {
9748  if (that == NULL)
9749  {
9750 #ifndef NDEBUG
9751  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
9752 #endif
9753  return false;
9754  }
9755  else
9756  {
9757  if (!this->minDiskSpace->IsEqual(that->minDiskSpace))
9758  return false;
9759  if (!this->minMemorySize->IsEqual(that->minMemorySize))
9760  return false;
9761  if (!this->minCPUSpeed->IsEqual(that->minCPUSpeed))
9762  return false;
9763  if (!this->minCPUNumber->IsEqual(that->minCPUNumber))
9764  return false;
9765  if (!this->otherOptions->IsEqual(that->otherOptions))
9766  return false;
9767  return true;
9768  }
9769  }
9770 }//SystemOption::IsEqual
9771 
9772 
9774 {
9775  std::ostringstream outStr;
9776 
9777 #ifndef NDEBUG
9778  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in ServiceOption");
9779 #endif
9780  if (this == NULL)
9781  {
9782  if (that == NULL)
9783  return true;
9784  else
9785  {
9786 #ifndef NDEBUG
9787  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
9788 #endif
9789  return false;
9790  }
9791  }
9792  else
9793  {
9794  if (that == NULL)
9795  {
9796 #ifndef NDEBUG
9797  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
9798 #endif
9799  return false;
9800  }
9801  else
9802  {
9803  if (this->type != that->type)
9804  {
9805 #ifndef NDEBUG
9806  outStr.str("");
9807  outStr.clear();
9808  outStr << "service type: " << this->type << " vs. " << that->type << endl;
9810 #endif
9811  return false;
9812  }
9813 
9814  if (!this->otherOptions->IsEqual(that->otherOptions))
9815  return false;
9816  return true;
9817  }
9818  }
9819 }//ServiceOption::IsEqual
9820 
9821 
9823 {
9824  std::ostringstream outStr;
9825 
9826 #ifndef NDEBUG
9827  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in JobOption");
9828 #endif
9829  if (this == NULL)
9830  {
9831  if (that == NULL)
9832  return true;
9833  else
9834  {
9835 #ifndef NDEBUG
9836  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
9837 #endif
9838  return false;
9839  }
9840  }
9841  else
9842  {
9843  if (that == NULL)
9844  {
9845 #ifndef NDEBUG
9846  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
9847 #endif
9848 
9849  return false;
9850  }
9851  else
9852  {
9853  if (this->requestedStartTime != that->requestedStartTime)
9854  {
9855 #ifndef NDEBUG
9856  outStr.str("");
9857  outStr.clear();
9858  outStr << "requestedStartTime: " << this->requestedStartTime << " vs. " << that->requestedStartTime << endl;
9860 #endif
9861  return false;
9862  }
9863 
9864 
9865  if (!this->maxTime->IsEqual(that->maxTime))
9866  return false;
9867  if (!this->dependencies->IsEqual(that->dependencies))
9868  return false;
9869  if (!this->requiredDirectories->IsEqual(that->requiredDirectories))
9870  return false;
9871  if (!this->requiredFiles->IsEqual(that->requiredFiles))
9872  return false;
9873  if (!this->directoriesToMake->IsEqual(that->directoriesToMake))
9874  return false;
9875  if (!this->filesToMake->IsEqual(that->filesToMake))
9876  return false;
9878  return false;
9879  if (!this->inputFilesToMove->IsEqual(that->inputFilesToMove))
9880  return false;
9881  if (!this->outputFilesToMove->IsEqual(that->outputFilesToMove))
9882  return false;
9884  return false;
9885  if (!this->filesToDelete->IsEqual(that->filesToDelete))
9886  return false;
9887  if (!this->directoriesToDelete->IsEqual(that->directoriesToDelete))
9888  return false;
9889  if (!this->processesToKill->IsEqual(that->processesToKill))
9890  return false;
9891  if (!this->otherOptions->IsEqual(that->otherOptions))
9892  return false;
9893  return true;
9894  }
9895  }
9896 }//JobOption::IsEqual
9897 
9899 {
9900  std::ostringstream outStr;
9901 
9902 #ifndef NDEBUG
9903  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in OptimizationOption");
9904 #endif
9905  if (this == NULL)
9906  {
9907  if (that == NULL)
9908  return true;
9909  else
9910  {
9911 #ifndef NDEBUG
9912  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
9913 #endif
9914  return false;
9915  }
9916  }
9917  else
9918  {
9919  if (that == NULL)
9920  {
9921 #ifndef NDEBUG
9922  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
9923 #endif
9924  return false;
9925  }
9926  else
9927  {
9928  if ((this->numberOfVariables != that->numberOfVariables) &&
9929  (this->numberOfVariables * that->numberOfVariables) != 0)
9930  {
9931 #ifndef NDEBUG
9932  outStr.str("");
9933  outStr.clear();
9934  outStr << "numberOfVariables: "
9935  << this->numberOfVariables << " vs. " << that->numberOfVariables << endl;
9937 #endif
9938  return false;
9939  }
9940  if ((this->numberOfObjectives != that->numberOfObjectives) &&
9941  (this->numberOfObjectives * that->numberOfObjectives) != 0)
9942  {
9943 #ifndef NDEBUG
9944  outStr.str("");
9945  outStr.clear();
9946  outStr << "numberOfObjectives: "
9947  << this->numberOfObjectives << " vs. " << that->numberOfObjectives << endl;
9949 #endif
9950  return false;
9951  }
9952  if ((this->numberOfConstraints != that->numberOfConstraints) &&
9953  (this->numberOfConstraints * that->numberOfConstraints) != 0)
9954  {
9955 #ifndef NDEBUG
9956  outStr.str("");
9957  outStr.clear();
9958  outStr << "numberOfConstraints: "
9959  << this->numberOfConstraints << " vs. " << that->numberOfConstraints << endl;
9961 #endif
9962  return false;
9963  }
9964 
9965  if (!this->variables->IsEqual(that->variables))
9966  return false;
9967  if (!this->objectives->IsEqual(that->objectives))
9968  return false;
9969  if (!this->constraints->IsEqual(that->constraints))
9970  return false;
9971  if (!this->solverOptions->IsEqual(that->solverOptions))
9972  return false;
9973  return true;
9974  }
9975  }
9976 }//OptimizationOption::IsEqual
9977 
9979 {
9980  std::ostringstream outStr;
9981 
9982 #ifndef NDEBUG
9983  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in InstanceLocation");
9984 #endif
9985  if (this == NULL)
9986  {
9987  if (that == NULL)
9988  return true;
9989  else
9990  {
9991 #ifndef NDEBUG
9992  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
9993 #endif
9994  return false;
9995  }
9996  }
9997  else
9998  {
9999  if (that == NULL)
10000  {
10001 #ifndef NDEBUG
10002  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
10003 #endif
10004  return false;
10005  }
10006  else
10007  {
10008  if ((this->locationType != that->locationType) || (this->value != that->value))
10009  {
10010 #ifndef NDEBUG
10011  outStr.str("");
10012  outStr.clear();
10013  outStr << "location type: " << this->locationType << " vs. " << that->locationType << endl;
10014  outStr << "value: " << this->value << " vs. " << that->value << endl;
10016 #endif
10017  return false;
10018  }
10019  return true;
10020  }
10021  }
10022 }//InstanceLocationOption::IsEqual
10023 
10025 {
10026  std::ostringstream outStr;
10027 
10028 #ifndef NDEBUG
10029  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in ContactOption");
10030 #endif
10031  if (this == NULL)
10032  {
10033  if (that == NULL)
10034  return true;
10035  else
10036  {
10037 #ifndef NDEBUG
10038  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
10039 #endif
10040  return false;
10041  }
10042  }
10043  else
10044  {
10045  if (that == NULL)
10046  {
10047 #ifndef NDEBUG
10048  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
10049 #endif
10050  return false;
10051  }
10052  else
10053  {
10054  if ((this->transportType != that->transportType) || (this->value != that->value))
10055  {
10056 #ifndef NDEBUG
10057  outStr.str("");
10058  outStr.clear();
10059  outStr << "transport type: " << this->transportType << " vs. " << that->transportType << endl;
10060  outStr << "value: " << this->value << " vs. " << that->value << endl;
10062 #endif
10063  return false;
10064  }
10065  return true;
10066  }
10067  }
10068 }//ContactOption::IsEqual
10069 
10071 {
10072  std::ostringstream outStr;
10073 
10074 #ifndef NDEBUG
10075  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in OtherOptions");
10076 #endif
10077  if (this == NULL)
10078  {
10079  if (that == NULL)
10080  return true;
10081  else
10082  {
10083 #ifndef NDEBUG
10084  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
10085 #endif
10086  return false;
10087  }
10088  }
10089  else
10090  {
10091  if (that == NULL)
10092  {
10093 #ifndef NDEBUG
10094  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
10095 #endif
10096  return false;
10097  }
10098  else
10099  {
10100  if (this->numberOfOtherOptions != that->numberOfOtherOptions)
10101  {
10102 #ifndef NDEBUG
10103  outStr.str("");
10104  outStr.clear();
10105  outStr << "numberOfOtherOptions: " << this->numberOfOtherOptions << " vs. " << that->numberOfOtherOptions << endl;
10107 #endif
10108  return false;
10109  }
10110  int i;
10111  for (i = 0; i < this->numberOfOtherOptions; i++)
10112  if (!this->other[i]->IsEqual(that->other[i]))
10113  return false;
10114  return true;
10115  }
10116  }
10117 }//OtherOptions::IsEqual
10118 
10119 
10121 {
10122  std::ostringstream outStr;
10123 
10124 #ifndef NDEBUG
10125  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in OtherOption");
10126 #endif
10127  if (this == NULL)
10128  {
10129  if (that == NULL)
10130  return true;
10131  else
10132  {
10133 #ifndef NDEBUG
10134  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
10135 #endif
10136  return false;
10137  }
10138  }
10139  else
10140  {
10141  if (that == NULL)
10142  {
10143 #ifndef NDEBUG
10144  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
10145 #endif
10146  return false;
10147  }
10148  else
10149  {
10150  if ((this->name != that->name) ||
10151  (this->value != that->value) ||
10152  (this->description != that->description) )
10153  {
10154 #ifndef NDEBUG
10155  outStr.str("");
10156  outStr.clear();
10157  outStr << "name: " << this->name << " vs. " << that->name << endl;
10158  outStr << "value: " << this->value << " vs. " << that->value << endl;
10159  outStr << "description: " << this->description << " vs. " << that->description << endl;
10161 #endif
10162  return false;
10163  }
10164  return true;
10165  }
10166  }
10167 }//OtherOption::IsEqual
10168 
10170 {
10171  std::ostringstream outStr;
10172 
10173 #ifndef NDEBUG
10174  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in MinDiskSpace");
10175 #endif
10176  if (this == NULL)
10177  {
10178  if (that == NULL)
10179  return true;
10180  else
10181  {
10182 #ifndef NDEBUG
10183  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
10184 #endif
10185  return false;
10186  }
10187  }
10188  else
10189  {
10190  if (that == NULL)
10191  {
10192 #ifndef NDEBUG
10193  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
10194 #endif
10195  return false;
10196  }
10197  else
10198  {
10199  if ((this->unit != that->unit) ||
10200  !OSIsEqual(this->value, that->value) ||
10201  (this->description != that->description) )
10202  {
10203 #ifndef NDEBUG
10204  outStr.str("");
10205  outStr.clear();
10206  outStr << "unit: " << this->unit << " vs. " << that->unit << endl;
10207  outStr << "value: " << this->value << " vs. " << that->value << endl;
10208  outStr << "description: " << this->description << " vs. " << that->description << endl;
10210 #endif
10211  return false;
10212  }
10213  return true;
10214  }
10215  }
10216 }//MinDiskSpace::IsEqual
10217 
10219 {
10220  std::ostringstream outStr;
10221 
10222 #ifndef NDEBUG
10223  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in MinMemorySize");
10224 #endif
10225  if (this == NULL)
10226  {
10227  if (that == NULL)
10228  return true;
10229  else
10230  {
10231 #ifndef NDEBUG
10232  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
10233 #endif
10234  return false;
10235  }
10236  }
10237  else
10238  {
10239  if (that == NULL)
10240  {
10241 #ifndef NDEBUG
10242  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
10243 #endif
10244  return false;
10245  }
10246  else
10247  {
10248  if ((this->unit != that->unit) ||
10249  !OSIsEqual(this->value, that->value) ||
10250  (this->description != that->description) )
10251  {
10252 #ifndef NDEBUG
10253  outStr.str("");
10254  outStr.clear();
10255  outStr << "unit: " << this->unit << " vs. " << that->unit << endl;
10256  outStr << "value: " << this->value << " vs. " << that->value << endl;
10258 #endif
10259  return false;
10260  }
10261  return true;
10262  }
10263  }
10264 }//MinMemorySize::IsEqual
10265 
10267 {
10268  std::ostringstream outStr;
10269 
10270 #ifndef NDEBUG
10271  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in MinCPUSpeed");
10272 #endif
10273  if (this == NULL)
10274  {
10275  if (that == NULL)
10276  return true;
10277  else
10278  {
10279 #ifndef NDEBUG
10280  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
10281 #endif
10282  return false;
10283  }
10284  }
10285  else
10286  {
10287  if (that == NULL)
10288  {
10289 #ifndef NDEBUG
10290  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
10291 #endif
10292  return false;
10293  }
10294  else
10295  {
10296  if ((this->unit != that->unit) ||
10297  !OSIsEqual(this->value, that->value) ||
10298  (this->description != that->description) )
10299  {
10300 #ifndef NDEBUG
10301  outStr.str("");
10302  outStr.clear();
10303  outStr << "unit: " << this->unit << " vs. " << that->unit << endl;
10304  outStr << "value: " << this->value << " vs. " << that->value << endl;
10306 #endif
10307  return false;
10308  }
10309  return true;
10310  }
10311  }
10312 }//MinCPUSpeed::IsEqual
10313 
10315 {
10316  std::ostringstream outStr;
10317 
10318 #ifndef NDEBUG
10319  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in MinCPUNumber");
10320 #endif
10321  if (this == NULL)
10322  {
10323  if (that == NULL)
10324  return true;
10325  else
10326  {
10327 #ifndef NDEBUG
10328  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
10329 #endif
10330  return false;
10331  }
10332  }
10333  else
10334  {
10335  if (that == NULL)
10336  {
10337 #ifndef NDEBUG
10338  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
10339 #endif
10340  return false;
10341  }
10342  else
10343  {
10344  if ((this->description != that->description) ||
10345  (this->value != that->value) )
10346  {
10347 #ifndef NDEBUG
10348  outStr.str("");
10349  outStr.clear();
10350  outStr << "description: " << this->description << " vs. " << that->description << endl;
10351  outStr << "value: " << this->value << " vs. " << that->value << endl;
10353 #endif
10354  return false;
10355  }
10356  return true;
10357  }
10358  }
10359 }//MinCPUNumber::IsEqual
10360 
10362 {
10363  std::ostringstream outStr;
10364 
10365 #ifndef NDEBUG
10366  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in JobDependencies");
10367 #endif
10368  if (this == NULL)
10369  {
10370  if (that == NULL)
10371  return true;
10372  else
10373  {
10374 #ifndef NDEBUG
10375  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
10376 #endif
10377  return false;
10378  }
10379  }
10380  else
10381  {
10382  if (that == NULL)
10383  {
10384 #ifndef NDEBUG
10385  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
10386 #endif
10387  return false;
10388  }
10389  else
10390  {
10391  if (this->numberOfJobIDs != that->numberOfJobIDs)
10392  {
10393 #ifndef NDEBUG
10394  outStr.str("");
10395  outStr.clear();
10396  outStr << "numberOfJobIDs: " << this->numberOfJobIDs << " vs. " << that->numberOfJobIDs << endl;
10398 #endif
10399  return false;
10400  }
10401  int i;
10402  for (i = 0; i < numberOfJobIDs; i++)
10403  if (this->jobID[i] != that->jobID[i])
10404  {
10405 #ifndef NDEBUG
10406  outStr.str("");
10407  outStr.clear();
10408  outStr << "jobID[" << i << "]: " << this->jobID[i] << " vs. " << that->jobID[i] << endl;
10410 #endif
10411  return false;
10412  }
10413  return true;
10414  }
10415  }
10416 }//JobDependencies::IsEqual
10417 
10419 {
10420  std::ostringstream outStr;
10421 
10422 #ifndef NDEBUG
10423  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in DirectoriesAndFiles");
10424 #endif
10425  if (this == NULL)
10426  {
10427  if (that == NULL)
10428  return true;
10429  else
10430  {
10431 #ifndef NDEBUG
10432  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
10433 #endif
10434  return false;
10435  }
10436  }
10437  else
10438  {
10439  if (that == NULL)
10440  {
10441 #ifndef NDEBUG
10442  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
10443 #endif
10444  return false;
10445  }
10446  else
10447  {
10448  if (this->numberOfPaths != that->numberOfPaths)
10449  {
10450 #ifndef NDEBUG
10451  outStr.str("");
10452  outStr.clear();
10453  outStr << "numberOfPaths: " << this->numberOfPaths << " vs. " << that->numberOfPaths << endl;
10455 #endif
10456  return false;
10457  }
10458  int i;
10459  for (i = 0; i < numberOfPaths; i++)
10460  if (this->path[i] != that->path[i])
10461  {
10462 #ifndef NDEBUG
10463  outStr.str("");
10464  outStr.clear();
10465  outStr << "path[" << i << "]: \'" << this->path[i] << "\' vs. \'" << that->path[i] << "\'" << endl;
10467 #endif
10468  return false;
10469  }
10470  return true;
10471  }
10472  }
10473 }//DirectoriesAndFiles::IsEqual
10474 
10476 {
10477  std::ostringstream outStr;
10478 
10479 #ifndef NDEBUG
10480  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in PathPairs");
10481 #endif
10482  if (this == NULL)
10483  {
10484  if (that == NULL)
10485  return true;
10486  else
10487  {
10488 #ifndef NDEBUG
10489  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
10490 #endif
10491  return false;
10492  }
10493  }
10494  else
10495  {
10496  if (that == NULL)
10497  {
10498 #ifndef NDEBUG
10499  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
10500 #endif
10501  return false;
10502  }
10503  else
10504  {
10505  if (this->numberOfPathPairs != that->numberOfPathPairs)
10506  {
10507 #ifndef NDEBUG
10508  outStr.str("");
10509  outStr.clear();
10510  outStr << "numberOfPathPairs: " << this->numberOfPathPairs << " vs. " << that->numberOfPathPairs << endl;
10512 #endif
10513  return false;
10514  }
10515  int i;
10516  for (i = 0; i < numberOfPathPairs; i++)
10517  if (!this->pathPair[i]->IsEqual(that->pathPair[i]))
10518  return false;
10519  return true;
10520  }
10521  }
10522 }//PathPairs::IsEqual
10523 
10524 
10526 {
10527  std::ostringstream outStr;
10528 
10529 #ifndef NDEBUG
10530  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in PathPair");
10531 #endif
10532  if (this == NULL)
10533  {
10534  if (that == NULL)
10535  return true;
10536 
10537  else
10538  {
10539 #ifndef NDEBUG
10540  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
10541 #endif
10542  return false;
10543  }
10544  }
10545  else
10546  {
10547  if (that == NULL)
10548  {
10549 #ifndef NDEBUG
10550  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
10551 #endif
10552  return false;
10553  }
10554  else
10555  {
10556  if ((this->from != that->from) || (this->to != that->to) ||
10557  (this->makeCopy != that->makeCopy))
10558  {
10559 #ifndef NDEBUG
10560  outStr.str("");
10561  outStr.clear();
10562  outStr << "from: " << this->from << " vs. " << that->from << endl;
10563  outStr << "to: " << this->to << " vs. " << that->to << endl;
10564  outStr << "makeCopy: " << this->makeCopy << " vs. " << that->makeCopy << endl;
10566 #endif
10567  return false;
10568  }
10569  return true;
10570  }
10571  }
10572 }//PathPair::IsEqual
10573 
10575 {
10576  std::ostringstream outStr;
10577 
10578 #ifndef NDEBUG
10579  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in Processes");
10580 #endif
10581  if (this == NULL)
10582  {
10583  if (that == NULL)
10584  return true;
10585  else
10586  {
10587 #ifndef NDEBUG
10588  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
10589 #endif
10590  return false;
10591  }
10592  }
10593  else
10594  {
10595  if (that == NULL)
10596  {
10597 #ifndef NDEBUG
10598  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
10599 #endif
10600  return false;
10601  }
10602  else
10603  {
10604  if (this->numberOfProcesses != that->numberOfProcesses)
10605  {
10606 #ifndef NDEBUG
10607  outStr.str("");
10608  outStr.clear();
10609  outStr << "numberOfProcesses: " << this->numberOfProcesses << " vs. " << that->numberOfProcesses << endl;
10611 #endif
10612  return false;
10613  }
10614  int i;
10615  for (i = 0; i < numberOfProcesses; i++)
10616  if (this->process[i] != that->process[i])
10617  {
10618 #ifndef NDEBUG
10619  outStr.str("");
10620  outStr.clear();
10621  outStr << "process[" << i << "]: " << this->process[i] << " vs. " << that->process[i] << endl;
10623 #endif
10624  return false;
10625  }
10626  return true;
10627  }
10628  }
10629 }//Processes::IsEqual
10630 
10631 
10633 {
10634  std::ostringstream outStr;
10635 
10636 #ifndef NDEBUG
10637  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in VariableOption");
10638 #endif
10639  if (this == NULL)
10640  {
10641  if (that == NULL)
10642  return true;
10643  else
10644  {
10645 #ifndef NDEBUG
10646  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
10647 #endif
10648  return false;
10649  }
10650  }
10651  else
10652  {
10653  if (that == NULL)
10654  {
10655 #ifndef NDEBUG
10656  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
10657 #endif
10658  return false;
10659  }
10660  else
10661  {
10663  return false;
10665  return false;
10666  if (!this->initialBasisStatus->IsEqual(that->initialBasisStatus))
10667  return false;
10669  return false;
10671  return false;
10672 
10674  {
10675 #ifndef NDEBUG
10676  outStr.str("");
10677  outStr.clear();
10678  outStr << "numberOfOtherVariableOptions: " << this->numberOfOtherVariableOptions << " vs. " << that->numberOfOtherVariableOptions << endl;
10680 #endif
10681  return false;
10682  }
10683 
10684  int i;
10685  for (i = 0; i < numberOfOtherVariableOptions; i++)
10686  if (!this->other[i]->IsEqual(that->other[i]))
10687  {
10688 #ifndef NDEBUG
10689  outStr.str("");
10690  outStr.clear();
10691  outStr << "other[" << i << "]: " << this->other[i] << " vs. " << that->other[i] << endl;
10693 #endif
10694  return false;
10695  }
10696 
10697  return true;
10698  }
10699  }
10700 }//VariableOption::IsEqual
10701 
10703 {
10704  std::ostringstream outStr;
10705 
10706 #ifndef NDEBUG
10707  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in InitVariableValues");
10708 #endif
10709  if (this == NULL)
10710  {
10711  if (that == NULL)
10712  return true;
10713  else
10714  {
10715 #ifndef NDEBUG
10716  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
10717 #endif
10718  return false;
10719  }
10720  }
10721  else
10722  {
10723  if (that == NULL)
10724  {
10725 #ifndef NDEBUG
10726  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
10727 #endif
10728  return false;
10729  }
10730  else
10731  {
10732  if (this->numberOfVar != that->numberOfVar)
10733  {
10734 #ifndef NDEBUG
10735  outStr.str("");
10736  outStr.clear();
10737  outStr << "numberOfVar: " << this->numberOfVar << " vs. " << that->numberOfVar << endl;
10739 #endif
10740  return false;
10741  }
10742  int i;
10743  for (i = 0; i < numberOfVar; i++)
10744  if (!this->var[i]->IsEqual(that->var[i]))
10745  return false;
10746  return true;
10747  }
10748  }
10749 }//InitVariableValues::IsEqual
10750 
10752 {
10753  std::ostringstream outStr;
10754 
10755 #ifndef NDEBUG
10756  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in InitVarValue");
10757 #endif
10758  if (this == NULL)
10759  {
10760  if (that == NULL)
10761  return true;
10762  else
10763  {
10764 #ifndef NDEBUG
10765  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
10766 #endif
10767  return false;
10768  }
10769  }
10770  else
10771  {
10772  if (that == NULL)
10773  {
10774 #ifndef NDEBUG
10775  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
10776 #endif
10777  return false;
10778  }
10779  else
10780  {
10781  if ((this->idx != that->idx) || this->name != that->name
10782  || !OSIsEqual(this->value, that->value))
10783  {
10784 #ifndef NDEBUG
10785  outStr.str("");
10786  outStr.clear();
10787  outStr << "idx: " << this->idx << " vs. " << that->idx << endl;
10788  outStr << "value: " << this->value << " vs. " << that->value << endl;
10790 #endif
10791  return false;
10792  }
10793  return true;
10794  }
10795  }
10796 }//InitVarValue::IsEqual
10797 
10798 
10800 {
10801  std::ostringstream outStr;
10802 
10803 #ifndef NDEBUG
10804  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in InitVariableValuesString");
10805 #endif
10806  if (this == NULL)
10807  {
10808  if (that == NULL)
10809  return true;
10810  else
10811  {
10812 #ifndef NDEBUG
10813  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
10814 #endif
10815  return false;
10816  }
10817  }
10818  else
10819  {
10820  if (that == NULL)
10821  {
10822 #ifndef NDEBUG
10823  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
10824 #endif
10825  return false;
10826  }
10827  else
10828  {
10829  if (this->numberOfVar != that->numberOfVar)
10830  {
10831 #ifndef NDEBUG
10832  outStr.str("");
10833  outStr.clear();
10834  outStr << "numberOfVar: " << this->numberOfVar << " vs. " << that->numberOfVar << endl;
10836 #endif
10837  return false;
10838  }
10839  int i;
10840  for (i = 0; i < numberOfVar; i++)
10841  if (!this->var[i]->IsEqual(that->var[i]))
10842  return false;
10843  return true;
10844  }
10845  }
10846 }//InitVariableValuesString::IsEqual
10847 
10849 {
10850  std::ostringstream outStr;
10851 
10852 #ifndef NDEBUG
10853  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in InitVarValueString");
10854 #endif
10855  if (this == NULL)
10856  {
10857  if (that == NULL)
10858  return true;
10859  else
10860  {
10861 #ifndef NDEBUG
10862  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
10863 #endif
10864  return false;
10865  }
10866  }
10867  else
10868  {
10869  if (that == NULL)
10870  {
10871 #ifndef NDEBUG
10872  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
10873 #endif
10874  return false;
10875  }
10876  else
10877  {
10878  if ((this->idx != that->idx) || this->name != that->name || (this->value != that->value))
10879  {
10880 #ifndef NDEBUG
10881  outStr.str("");
10882  outStr.clear();
10883  outStr << "idx: " << this->idx << " vs. " << that->idx << endl;
10884  outStr << "value: " << this->value << " vs. " << that->value << endl;
10886 #endif
10887  return false;
10888  }
10889  return true;
10890  }
10891  }
10892 }//InitVarValueString::IsEqual
10893 
10895 {
10896  std::ostringstream outStr;
10897 
10898 #ifndef NDEBUG
10899  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in InitialBasisStatus");
10900 #endif
10901  if (this == NULL)
10902  {
10903  if (that == NULL)
10904  return true;
10905  else
10906  {
10907 #ifndef NDEBUG
10908  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
10909 #endif
10910  return false;
10911  }
10912  }
10913  else
10914  {
10915  if (that == NULL)
10916  {
10917 #ifndef NDEBUG
10918  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
10919 #endif
10920  return false;
10921  }
10922  else
10923  {
10924  if (this->numberOfVar != that->numberOfVar)
10925  {
10926 #ifndef NDEBUG
10927  outStr.str("");
10928  outStr.clear();
10929  outStr << "numberOfVar: " << this->numberOfVar << " vs. " << that->numberOfVar << endl;
10931 #endif
10932  return false;
10933  }
10934  int i;
10935  for (i = 0; i < numberOfVar; i++)
10936  if (!this->var[i]->IsEqual(that->var[i]))
10937  return false;
10938  return true;
10939  }
10940  }
10941 }//InitialBasisStatus::IsEqual
10942 
10944 {
10945  std::ostringstream outStr;
10946 
10947 #ifndef NDEBUG
10948  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in InitBasStatus");
10949 #endif
10950  if (this == NULL)
10951  {
10952  if (that == NULL)
10953  return true;
10954  else
10955  {
10956 #ifndef NDEBUG
10957  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
10958 #endif
10959  return false;
10960  }
10961  }
10962  else
10963  {
10964  if (that == NULL)
10965  {
10966 #ifndef NDEBUG
10967  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
10968 #endif
10969  return false;
10970  }
10971  else
10972  {
10973  if ((this->idx != that->idx) || (this->value != that->value))
10974  if ((this->value != "unknown" && that->value != "") ||
10975  (that->value != "unknown" && this->value != "") )
10976  {
10977 #ifndef NDEBUG
10978  outStr.str("");
10979  outStr.clear();
10980  outStr << "idx: " << this->idx << " vs. " << that->idx << endl;
10981  outStr << "value: " << this->value << " vs. " << that->value << endl;
10983 #endif
10984  return false;
10985  }
10986  return true;
10987  }
10988  }
10989 }//InitBasStatus::IsEqual
10990 
10991 
10993 {
10994  std::ostringstream outStr;
10995 
10996 #ifndef NDEBUG
10997  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in IntegerVariableBranchingWeights");
10998 #endif
10999  if (this == NULL)
11000  {
11001  if (that == NULL)
11002  return true;
11003  else
11004  {
11005 #ifndef NDEBUG
11006  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
11007 #endif
11008  return false;
11009  }
11010  }
11011  else
11012  {
11013  if (that == NULL)
11014  {
11015 #ifndef NDEBUG
11016  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
11017 #endif
11018  return false;
11019  }
11020  else
11021  {
11022  if (this->numberOfVar != that->numberOfVar)
11023  {
11024 #ifndef NDEBUG
11025  outStr.str("");
11026  outStr.clear();
11027  outStr << "numberOfVar: " << this->numberOfVar << " vs. " << that->numberOfVar << endl;
11029 #endif
11030  return false;
11031  }
11032  int i;
11033  for (i = 0; i < numberOfVar; i++)
11034  if (!this->var[i]->IsEqual(that->var[i]))
11035  return false;
11036  return true;
11037  }
11038  }
11039 }//IntegerVariableBranchingWeights::IsEqual
11040 
11042 {
11043  std::ostringstream outStr;
11044 
11045 #ifndef NDEBUG
11046  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in SOSVariableBranchingWeights");
11047 #endif
11048  if (this == NULL)
11049  {
11050  if (that == NULL)
11051  return true;
11052  else
11053  {
11054 #ifndef NDEBUG
11055  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
11056 #endif
11057  return false;
11058  }
11059  }
11060  else
11061  {
11062  if (that == NULL)
11063  {
11064 #ifndef NDEBUG
11065  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
11066 #endif
11067  return false;
11068  }
11069  else
11070  {
11071  if (this->numberOfSOS != that->numberOfSOS)
11072  {
11073 #ifndef NDEBUG
11074  outStr.str("");
11075  outStr.clear();
11076  outStr << "numberOfSOS: " << this->numberOfSOS << " vs. " << that->numberOfSOS << endl;
11078 #endif
11079  return false;
11080  }
11081  int i;
11082  for (i = 0; i < numberOfSOS; i++)
11083  {
11084  if (!this->sos[i]->IsEqual(that->sos[i]))
11085  return false;
11086  }
11087  return true;
11088  }
11089  }
11090 }//SOSVariableBranchingWeights::IsEqual
11091 
11092 
11094 {
11095  std::ostringstream outStr;
11096 
11097 #ifndef NDEBUG
11098  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in SOSWeights");
11099 #endif
11100  if (this == NULL)
11101  {
11102  if (that == NULL)
11103  return true;
11104  else
11105  {
11106 #ifndef NDEBUG
11107  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
11108 #endif
11109  return false;
11110  }
11111  }
11112  else
11113  {
11114  if (that == NULL)
11115  {
11116 #ifndef NDEBUG
11117  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
11118 #endif
11119  return false;
11120  }
11121  else
11122  {
11123  if ((this->sosIdx != that->sosIdx) ||
11124  !OSIsEqual(this->groupWeight, that->groupWeight))
11125  {
11126 #ifndef NDEBUG
11127  outStr.str("");
11128  outStr.clear();
11129  outStr << "sosIdx: " << this->sosIdx << " vs. " << that->sosIdx << endl;
11130  outStr << "groupWeight: " << this->groupWeight << " vs. " << that->groupWeight << endl;
11132 #endif
11133  return false;
11134  }
11135 
11136  if (this->numberOfVar != that->numberOfVar)
11137  {
11138 #ifndef NDEBUG
11139  outStr.str("");
11140  outStr.clear();
11141  outStr << "numberOfVar: " << this->numberOfVar << " vs. " << that->numberOfVar << endl;
11143 #endif
11144  return false;
11145  }
11146  int i;
11147  for (i = 0; i < numberOfVar; i++)
11148  {
11149  //outStr << "var[" << i << "] of " << numberOfVar << endl;
11150  if (!this->var[i]->IsEqual(that->var[i]))
11151  return false;
11152  }
11153  return true;
11154  }
11155  }
11156 }//SOSWeights::IsEqual
11157 
11158 
11160 {
11161  std::ostringstream outStr;
11162 
11163 #ifndef NDEBUG
11164  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in BranchingWeight");
11165 #endif
11166  if (this == NULL)
11167  {
11168  if (that == NULL)
11169  return true;
11170  else
11171  {
11172 #ifndef NDEBUG
11173  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
11174 #endif
11175  return false;
11176  }
11177  }
11178  else
11179  {
11180  if (that == NULL)
11181  {
11182 #ifndef NDEBUG
11183  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
11184 #endif
11185  return false;
11186  }
11187  else
11188  {
11189  if ((this->idx != that->idx) || this->name != that->name || !OSIsEqual(this->value, that->value))
11190  {
11191 #ifndef NDEBUG
11192  outStr.str("");
11193  outStr.clear();
11194  outStr << "idx: " << this->idx << " vs. " << that->idx << endl;
11195  outStr << "value: " << this->value << " vs. " << that->value << endl;
11196  outStr << "name: -" << this->name << "- vs. -" << that->name << "-" << endl;
11198 #endif
11199  return false;
11200  }
11201  return true;
11202  }
11203  }
11204 }//BranchingWeight::IsEqual
11205 
11207 {
11208  std::ostringstream outStr;
11209 
11210 #ifndef NDEBUG
11211  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in OtherVariableOption");
11212 #endif
11213  if (this == NULL)
11214  {
11215  if (that == NULL)
11216  return true;
11217  else
11218  {
11219 #ifndef NDEBUG
11220  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
11221 #endif
11222  return false;
11223  }
11224  }
11225  else
11226  {
11227  if (that == NULL)
11228  {
11229 #ifndef NDEBUG
11230  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
11231 #endif
11232  return false;
11233  }
11234  else
11235  {
11236  if ((this->name != that->name) ||
11237  (this->value != that->value) ||
11238  (this->solver != that->solver) ||
11239  (this->category != that->category) ||
11240  (this->type != that->type) ||
11241  (this->description != that->description))
11242  {
11243 #ifndef NDEBUG
11244  outStr.str("");
11245  outStr.clear();
11246  outStr << "name: " << this->name << " vs. " << that->name << endl;
11247  outStr << "value: " << this->value << " vs. " << that->value << endl;
11248  outStr << "solver: " << this->solver << " vs. " << that->solver << endl;
11249  outStr << "category: " << this->category << " vs. " << that->category << endl;
11250  outStr << "type: " << this->type << " vs. " << that->type << endl;
11251  outStr << "description: " << this->description << " vs. " << that->description << endl;
11253 #endif
11254  return false;
11255  }
11256 
11257  if (this->numberOfVar != that->numberOfVar)
11258  {
11259 #ifndef NDEBUG
11260  outStr.str("");
11261  outStr.clear();
11262  outStr << "numberOfVar: " << this->numberOfVar << " vs. " << that->numberOfVar << endl;
11264 #endif
11265  return false;
11266  }
11267  int i;
11268  for (i = 0; i < numberOfVar; i++)
11269  if (!this->var[i]->IsEqual(that->var[i]))
11270  return false;
11271 
11272  if (this->numberOfEnumerations != that->numberOfEnumerations)
11273  {
11274 #ifndef NDEBUG
11275  outStr.str("");
11276  outStr.clear();
11277  outStr << "numberOfEnumerations: " << this->numberOfEnumerations << " vs. " << that->numberOfEnumerations << endl;
11279 #endif
11280  return false;
11281  }
11282  for (i = 0; i < numberOfEnumerations; i++)
11283  if (!this->enumeration[i]->IsEqual(that->enumeration[i]))
11284  return false;
11285  return true;
11286  }
11287  }
11288 }//OtherVariableOption::IsEqual
11289 
11291 {
11292  std::ostringstream outStr;
11293 
11294 #ifndef NDEBUG
11295  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in OtherVarOption");
11296 #endif
11297  if (this == NULL)
11298  {
11299  if (that == NULL)
11300  return true;
11301  else
11302  {
11303 #ifndef NDEBUG
11304  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
11305 #endif
11306  return false;
11307  }
11308  }
11309  else
11310  {
11311  if (that == NULL)
11312  {
11313 #ifndef NDEBUG
11314  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
11315 #endif
11316  return false;
11317  }
11318  else
11319  {
11320  if ((this->idx != that->idx) || this->name != that->name || (this->value != that->value) ||
11321  (this->lbValue != that->lbValue) || (this->ubValue != that->ubValue))
11322  {
11323 #ifndef NDEBUG
11324  outStr.str("");
11325  outStr.clear();
11326  outStr << "idx: " << this->idx << " vs. " << that->idx << endl;
11327  outStr << "value: " << this->value << " vs. " << that->value << endl;
11328  outStr << "lbValue: " << this->lbValue << " vs. " << that->lbValue << endl;
11329  outStr << "ubValue: " << this->ubValue << " vs. " << that->ubValue << endl;
11331 #endif
11332  return false;
11333  }
11334  return true;
11335  }
11336  }
11337 }//OtherVarOption::IsEqual
11338 
11340 {
11341  std::ostringstream outStr;
11342 
11343 #ifndef NDEBUG
11344  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in ObjectiveOption");
11345 #endif
11346  if (this == NULL)
11347  {
11348  if (that == NULL)
11349  return true;
11350  else
11351  {
11352 #ifndef NDEBUG
11353  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
11354 #endif
11355  return false;
11356  }
11357  }
11358  else
11359  {
11360  if (that == NULL)
11361  {
11362 #ifndef NDEBUG
11363  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
11364 #endif
11365  return false;
11366  }
11367  else
11368  {
11370  return false;
11372  return false;
11373  if (!this->initialBasisStatus->IsEqual(that->initialBasisStatus))
11374  return false;
11375 
11377  {
11378 #ifndef NDEBUG
11379  outStr.str("");
11380  outStr.clear();
11381  outStr << "numberOfOtherObjectiveOptions: " << this->numberOfOtherObjectiveOptions << " vs. " << that->numberOfOtherObjectiveOptions << endl;
11383 #endif
11384  return false;
11385  }
11386  int i;
11387  for (i = 0; i < numberOfOtherObjectiveOptions; i++)
11388  if (!this->other[i]->IsEqual(that->other[i]))
11389  return false;
11390 
11391  return true;
11392  }
11393  }
11394 }//ObjectiveOption::IsEqual
11395 
11397 {
11398  std::ostringstream outStr;
11399 
11400 #ifndef NDEBUG
11401  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in InitObjectiveValues");
11402 #endif
11403  if (this == NULL)
11404  {
11405  if (that == NULL)
11406  return true;
11407  else
11408  {
11409 #ifndef NDEBUG
11410  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
11411 #endif
11412  return false;
11413  }
11414  }
11415  else
11416  {
11417  if (that == NULL)
11418  {
11419 #ifndef NDEBUG
11420  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
11421 #endif
11422  return false;
11423  }
11424  else
11425  {
11426  if (this->numberOfObj != that->numberOfObj)
11427  {
11428 #ifndef NDEBUG
11429  outStr.str("");
11430  outStr.clear();
11431  outStr << "numberOfObj: " << this->numberOfObj << " vs. " << that->numberOfObj << endl;
11433 #endif
11434  return false;
11435  }
11436  int i;
11437  for (i = 0; i < numberOfObj; i++)
11438  if (!this->obj[i]->IsEqual(that->obj[i]))
11439  return false;
11440  return true;
11441  }
11442  }
11443 }//InitObjectiveValues::IsEqual
11444 
11446 {
11447  std::ostringstream outStr;
11448 
11449 #ifndef NDEBUG
11450  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in InitObjValue");
11451 #endif
11452  if (this == NULL)
11453  {
11454  if (that == NULL)
11455  return true;
11456  else
11457  {
11458 #ifndef NDEBUG
11459  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
11460 #endif
11461  return false;
11462  }
11463  }
11464  else
11465  {
11466  if (that == NULL)
11467  {
11468 #ifndef NDEBUG
11469  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
11470 #endif
11471  return false;
11472  }
11473  else
11474  {
11475  if ((this->idx != that->idx) || this->name != that->name || !OSIsEqual(this->value, that->value))
11476  {
11477 #ifndef NDEBUG
11478  outStr.str("");
11479  outStr.clear();
11480  outStr << "idx: " << this->idx << " vs. " << that->idx << endl;
11481  outStr << "value: " << this->value << " vs. " << that->value << endl;
11483 #endif
11484  return false;
11485  }
11486  return true;
11487  }
11488  }
11489 }//InitObjValue::IsEqual
11490 
11492 {
11493  std::ostringstream outStr;
11494 
11495 #ifndef NDEBUG
11496  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in InitObjectiveBounds");
11497 #endif
11498  if (this == NULL)
11499  {
11500  if (that == NULL)
11501  return true;
11502  else
11503  {
11504 #ifndef NDEBUG
11505  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
11506 #endif
11507  return false;
11508  }
11509  }
11510  else
11511  {
11512  if (that == NULL)
11513  {
11514 #ifndef NDEBUG
11515  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
11516 #endif
11517  return false;
11518  }
11519  else
11520  {
11521  if (this->numberOfObj != that->numberOfObj)
11522  {
11523 #ifndef NDEBUG
11524  outStr.str("");
11525  outStr.clear();
11526  outStr << "numberOfObj: " << this->numberOfObj << " vs. " << that->numberOfObj << endl;
11528 #endif
11529  return false;
11530  }
11531  int i;
11532  for (i = 0; i < numberOfObj; i++)
11533  if (!this->obj[i]->IsEqual(that->obj[i]))
11534  return false;
11535  return true;
11536  }
11537  }
11538 }//InitObjectiveBounds::IsEqual
11539 
11541 {
11542  std::ostringstream outStr;
11543 
11544 #ifndef NDEBUG
11545  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in InitObjBound");
11546 #endif
11547  if (this == NULL)
11548  {
11549  if (that == NULL)
11550  return true;
11551  else
11552  {
11553 #ifndef NDEBUG
11554  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
11555 #endif
11556  return false;
11557  }
11558  }
11559  else
11560  {
11561  if (that == NULL)
11562  {
11563 #ifndef NDEBUG
11564  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
11565 #endif
11566  return false;
11567  }
11568  else
11569  {
11570  if ((this->idx != that->idx) ||
11571  this->name != that->name ||
11572  !OSIsEqual(this->lbValue, that->lbValue) ||
11573  !OSIsEqual(this->ubValue, that->ubValue) )
11574  {
11575 #ifndef NDEBUG
11576  outStr.str("");
11577  outStr.clear();
11578  outStr << "idx: " << this->idx << " vs. " << that->idx << endl;
11579  outStr << "lbValue: " << this->lbValue << " vs. " << that->lbValue << endl;
11580  outStr << "ubValue: " << this->ubValue << " vs. " << that->ubValue << endl;
11582 #endif
11583  return false;
11584  }
11585  return true;
11586  }
11587  }
11588 }//InitObjBound::IsEqual
11589 
11591 {
11592  std::ostringstream outStr;
11593 
11594 #ifndef NDEBUG
11595  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in OtherObjectiveOption");
11596 #endif
11597  if (this == NULL)
11598  {
11599  if (that == NULL)
11600  return true;
11601  else
11602  {
11603 #ifndef NDEBUG
11604  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
11605 #endif
11606  return false;
11607  }
11608  }
11609  else
11610  {
11611  if (that == NULL)
11612  {
11613 #ifndef NDEBUG
11614  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
11615 #endif
11616  return false;
11617  }
11618  else
11619  {
11620  if ((this->name != that->name) ||
11621  (this->value != that->value) ||
11622  (this->solver != that->solver) ||
11623  (this->category != that->category) ||
11624  (this->type != that->type) ||
11625  (this->description != that->description))
11626  {
11627 #ifndef NDEBUG
11628  outStr.str("");
11629  outStr.clear();
11630  outStr << "name: " << this->name << " vs. " << that->name << endl;
11631  outStr << "value: " << this->value << " vs. " << that->value << endl;
11632  outStr << "solver: " << this->solver << " vs. " << that->solver << endl;
11633  outStr << "category: " << this->category << " vs. " << that->category << endl;
11634  outStr << "type: " << this->type << " vs. " << that->type << endl;
11635  outStr << "description: " << this->description << " vs. " << that->description << endl;
11637 #endif
11638  return false;
11639  }
11640 
11641  if (this->numberOfObj != that->numberOfObj)
11642  {
11643 #ifndef NDEBUG
11644  outStr.str("");
11645  outStr.clear();
11646  outStr << "numberOfObj: " << this->numberOfObj << " vs. " << that->numberOfObj << endl;
11648 #endif
11649  return false;
11650  }
11651  int i;
11652  for (i = 0; i < numberOfObj; i++)
11653  if (!this->obj[i]->IsEqual(that->obj[i]))
11654  return false;
11655  return true;
11656  }
11657  }
11658 }//OtherObjectiveOption::IsEqual
11659 
11661 {
11662  std::ostringstream outStr;
11663 
11664 #ifndef NDEBUG
11665  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in OtherObjOption");
11666 #endif
11667  if (this == NULL)
11668  {
11669  if (that == NULL)
11670  return true;
11671  else
11672  {
11673 #ifndef NDEBUG
11674  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
11675 #endif
11676  return false;
11677  }
11678  }
11679  else
11680  {
11681  if (that == NULL)
11682  {
11683 #ifndef NDEBUG
11684  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
11685 #endif
11686  return false;
11687  }
11688  else
11689  {
11690  if ((this->idx != that->idx) || this->name != that->name || (this->value != that->value) ||
11691  (this->lbValue != that->lbValue) || (this->ubValue != that->ubValue))
11692  {
11693 #ifndef NDEBUG
11694  outStr.str("");
11695  outStr.clear();
11696  outStr << "idx: " << this->idx << " vs. " << that->idx << endl;
11697  outStr << "value: " << this->value << " vs. " << that->value << endl;
11698  outStr << "lbValue: " << this->lbValue << " vs. " << that->lbValue << endl;
11699  outStr << "ubValue: " << this->ubValue << " vs. " << that->ubValue << endl;
11701 #endif
11702  return false;
11703  }
11704  return true;
11705  }
11706  }
11707 }//OtherObjOption::IsEqual
11708 
11710 {
11711  std::ostringstream outStr;
11712 
11713 #ifndef NDEBUG
11714  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in ConstraintOption");
11715 #endif
11716  if (this == NULL)
11717  {
11718  if (that == NULL)
11719  return true;
11720  else
11721  {
11722 #ifndef NDEBUG
11723  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
11724 #endif
11725  return false;
11726  }
11727  }
11728  else
11729  {
11730  if (that == NULL)
11731  {
11732 #ifndef NDEBUG
11733  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
11734 #endif
11735  return false;
11736  }
11737  else
11738  {
11740  return false;
11741  if (!this->initialDualValues->IsEqual(that->initialDualValues))
11742  return false;
11743  if (!this->initialBasisStatus->IsEqual(that->initialBasisStatus))
11744  return false;
11745 
11747  {
11748 #ifndef NDEBUG
11749  outStr.str("");
11750  outStr.clear();
11751  outStr << "numberOfOtherConstraintOptions: " << this->numberOfOtherConstraintOptions << " vs. " << that->numberOfOtherConstraintOptions << endl;
11753 #endif
11754  return false;
11755  }
11756  int i;
11757  for (i = 0; i < numberOfOtherConstraintOptions; i++)
11758  if (!this->other[i]->IsEqual(that->other[i]))
11759  return false;
11760 
11761  return true;
11762  }
11763  }
11764 }//ConstraintOption::IsEqual
11765 
11767 {
11768  std::ostringstream outStr;
11769 
11770 #ifndef NDEBUG
11771  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in InitConstraintValues");
11772 #endif
11773  if (this == NULL)
11774  {
11775  if (that == NULL)
11776  return true;
11777  else
11778  {
11779 #ifndef NDEBUG
11780  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
11781 #endif
11782  return false;
11783  }
11784  }
11785  else
11786  {
11787  if (that == NULL)
11788  {
11789 #ifndef NDEBUG
11790  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
11791 #endif
11792  return false;
11793  }
11794  else
11795  {
11796  if (this->numberOfCon != that->numberOfCon)
11797  {
11798 #ifndef NDEBUG
11799  outStr.str("");
11800  outStr.clear();
11801  outStr << "numberOfCon: " << this->numberOfCon << " vs. " << that->numberOfCon << endl;
11803 #endif
11804  return false;
11805  }
11806  int i;
11807  for (i = 0; i < numberOfCon; i++)
11808  if (!this->con[i]->IsEqual(that->con[i]))
11809  return false;
11810  return true;
11811  }
11812  }
11813 }//InitConstraintValues::IsEqual
11814 
11816 {
11817  std::ostringstream outStr;
11818 
11819 #ifndef NDEBUG
11820  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in InitConValue");
11821 #endif
11822  if (this == NULL)
11823  {
11824  if (that == NULL)
11825  return true;
11826  else
11827  {
11828 #ifndef NDEBUG
11829  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
11830 #endif
11831  return false;
11832  }
11833  }
11834  else
11835  {
11836  if (that == NULL)
11837  {
11838 #ifndef NDEBUG
11839  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
11840 #endif
11841  return false;
11842  }
11843  else
11844  {
11845  if ((this->idx != that->idx) || this->name != that->name || !OSIsEqual(this->value, that->value))
11846  {
11847 #ifndef NDEBUG
11848  outStr.str("");
11849  outStr.clear();
11850  outStr << "idx: " << this->idx << " vs. " << that->idx << endl;
11851  outStr << "value: " << this->value << " vs. " << that->value << endl;
11853 #endif
11854  return false;
11855  }
11856  return true;
11857  }
11858  }
11859 }//InitConValue::IsEqual
11860 
11862 {
11863  std::ostringstream outStr;
11864 
11865 #ifndef NDEBUG
11866  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in InitDualVariableValues");
11867 #endif
11868  if (this == NULL)
11869  {
11870  if (that == NULL)
11871  return true;
11872  else
11873  {
11874 #ifndef NDEBUG
11875  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
11876 #endif
11877  return false;
11878  }
11879  }
11880  else
11881  {
11882  if (that == NULL)
11883  {
11884 #ifndef NDEBUG
11885  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
11886 #endif
11887  return false;
11888  }
11889  else
11890  {
11891  if (this->numberOfCon != that->numberOfCon)
11892  {
11893 #ifndef NDEBUG
11894  outStr.str("");
11895  outStr.clear();
11896  outStr << "numberOfCon: " << this->numberOfCon << " vs. " << that->numberOfCon << endl;
11898 #endif
11899  return false;
11900  }
11901  int i;
11902  for (i = 0; i < numberOfCon; i++)
11903  if (!this->con[i]->IsEqual(that->con[i]))
11904  return false;
11905  return true;
11906  }
11907  }
11908 }//InitDualVariableValues::IsEqual
11909 
11911 {
11912  std::ostringstream outStr;
11913 
11914 #ifndef NDEBUG
11915  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in InitDualVarValue");
11916 #endif
11917  if (this == NULL)
11918  {
11919  if (that == NULL)
11920  return true;
11921  else
11922  {
11923 #ifndef NDEBUG
11924  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
11925 #endif
11926  return false;
11927  }
11928  }
11929  else
11930  {
11931  if (that == NULL)
11932  {
11933 #ifndef NDEBUG
11934  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
11935 #endif
11936  return false;
11937  }
11938  else
11939  {
11940  if ((this->idx != that->idx) || this->name != that->name ||
11941  !OSIsEqual(this->lbDualValue, that->lbDualValue) ||
11942  !OSIsEqual(this->ubDualValue, that->ubDualValue))
11943  {
11944 #ifndef NDEBUG
11945  outStr.str("");
11946  outStr.clear();
11947  outStr << "idx: " << this->idx << " vs. " << that->idx << endl;
11948  outStr << "lbDualValue: " << this->lbDualValue << " vs. " << that->lbDualValue << endl;
11949  outStr << "ubDualValue: " << this->ubDualValue << " vs. " << that->ubDualValue << endl;
11951 #endif
11952  return false;
11953  }
11954  return true;
11955  }
11956  }
11957 }//InitDualVarValue::IsEqual
11958 
11960 {
11961  std::ostringstream outStr;
11962 
11963 #ifndef NDEBUG
11964  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in OtherConstraintOption");
11965 #endif
11966  if (this == NULL)
11967  {
11968  if (that == NULL)
11969  return true;
11970  else
11971  {
11972 #ifndef NDEBUG
11973  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
11974 #endif
11975  return false;
11976  }
11977  }
11978  else
11979  {
11980  if (that == NULL)
11981  {
11982 #ifndef NDEBUG
11983  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
11984 #endif
11985  return false;
11986  }
11987  else
11988  {
11989  if ((this->name != that->name) ||
11990  (this->value != that->value) ||
11991  (this->solver != that->solver) ||
11992  (this->category != that->category) ||
11993  (this->type != that->type) ||
11994  (this->description != that->description))
11995  {
11996 #ifndef NDEBUG
11997  outStr.str("");
11998  outStr.clear();
11999  outStr << "name: " << this->name << " vs. " << that->name << endl;
12000  outStr << "value: " << this->value << " vs. " << that->value << endl;
12001  outStr << "solver: " << this->solver << " vs. " << that->solver << endl;
12002  outStr << "category: " << this->category << " vs. " << that->category << endl;
12003  outStr << "type: " << this->type << " vs. " << that->type << endl;
12004  outStr << "description: " << this->description << " vs. " << that->description << endl;
12006 #endif
12007  return false;
12008  }
12009 
12010  if (this->numberOfCon != that->numberOfCon)
12011  {
12012 #ifndef NDEBUG
12013  outStr.str("");
12014  outStr.clear();
12015  outStr << "numberOfCon: " << this->numberOfCon << " vs. " << that->numberOfCon << endl;
12017 #endif
12018  return false;
12019  }
12020  int i;
12021  for (i = 0; i < numberOfCon; i++)
12022  if (!this->con[i]->IsEqual(that->con[i]))
12023  return false;
12024  return true;
12025  }
12026  }
12027 }//OtherConstraintOption::IsEqual
12028 
12030 {
12031  std::ostringstream outStr;
12032 
12033 #ifndef NDEBUG
12034  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in OtherConOption");
12035 #endif
12036  if (this == NULL)
12037  {
12038  if (that == NULL)
12039  return true;
12040  else
12041  {
12042 #ifndef NDEBUG
12043  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
12044 #endif
12045  return false;
12046  }
12047  }
12048  else
12049  {
12050  if (that == NULL)
12051  {
12052 #ifndef NDEBUG
12053  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
12054 #endif
12055  return false;
12056  }
12057 
12058  else
12059  {
12060  if ((this->idx != that->idx) || this->name != that->name || (this->value != that->value) ||
12061  (this->lbValue != that->lbValue) || (this->ubValue != that->ubValue))
12062  {
12063 #ifndef NDEBUG
12064  outStr.str("");
12065  outStr.clear();
12066  outStr << "idx: " << this->idx << " vs. " << that->idx << endl;
12067  outStr << "value: " << this->value << " vs. " << that->value << endl;
12068  outStr << "lbValue: " << this->lbValue << " vs. " << that->lbValue << endl;
12069  outStr << "ubValue: " << this->ubValue << " vs. " << that->ubValue << endl;
12071 #endif
12072  return false;
12073  }
12074  return true;
12075  }
12076  }
12077 }//OtherConOption::IsEqual
12078 
12079 
12081 {
12082  std::ostringstream outStr;
12083 
12084 #ifndef NDEBUG
12085  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in SolverOptions");
12086 #endif
12087  if (this == NULL)
12088  {
12089  if (that == NULL)
12090  return true;
12091  else
12092  {
12093 #ifndef NDEBUG
12094  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
12095 #endif
12096  return false;
12097  }
12098  }
12099  else
12100  {
12101  if (that == NULL)
12102  {
12103 #ifndef NDEBUG
12104  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
12105 #endif
12106  return false;
12107  }
12108  else
12109  {
12110  if (this->numberOfSolverOptions != that->numberOfSolverOptions)
12111  {
12112 #ifndef NDEBUG
12113  outStr.str("");
12114  outStr.clear();
12115  outStr << "numberOfSolverOptions: " << this->numberOfSolverOptions << " vs. " << that->numberOfSolverOptions << endl;
12117 #endif
12118  return false;
12119  }
12120 
12121  int i;
12122  for (i = 0; i < numberOfSolverOptions; i++)
12123  if (!this->solverOption[i]->IsEqual(that->solverOption[i]))
12124  return false;
12125 
12126  return true;
12127  }
12128  }
12129 }//SolverOptions::IsEqual
12130 
12132 {
12133  std::ostringstream outStr;
12134 
12135 #ifndef NDEBUG
12136  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Start comparing in SolverOption");
12137 #endif
12138  if (this == NULL)
12139  {
12140  if (that == NULL)
12141  return true;
12142  else
12143  {
12144 #ifndef NDEBUG
12145  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "First object is NULL, second is not");
12146 #endif
12147  return false;
12148  }
12149  }
12150  else
12151  {
12152  if (that == NULL)
12153  {
12154 #ifndef NDEBUG
12155  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_debug, "Second object is NULL, first is not");
12156 #endif
12157  return false;
12158  }
12159  else
12160  {
12161  if ((this->name != that->name) ||
12162  (this->value != that->value) ||
12163  (this->solver != that->solver) ||
12164  (this->category != that->category) ||
12165  (this->type != that->type) ||
12166  (this->description != that->description))
12167  {
12168 #ifndef NDEBUG
12169  outStr.str("");
12170  outStr.clear();
12171  outStr << "name: " << this->name << " vs. " << that->name << endl;
12172  outStr << "value: " << this->value << " vs. " << that->value << endl;
12173  outStr << "solver: " << this->solver << " vs. " << that->solver << endl;
12174  outStr << "category: " << this->category << " vs. " << that->category << endl;
12175  outStr << "type: " << this->type << " vs. " << that->type << endl;
12176  outStr << "description: " << this->description << " vs. " << that->description << endl;
12178 #endif
12179  return false;
12180  }
12181  return true;
12182  }
12183  }
12184 }//SolverOption::IsEqual
12185 
12186 
12187 /***********************************************************************
12188  *
12189  * Methods to set a random OSOption object.
12190  *
12191  * These methods are mostly useful during the debugging process
12192  * but might come in handy in other ways
12193  * The calling sequence is identical in all cases: setRandom( double density, bool conformant )
12194  * @param density gives the probability that a particular child element is generated
12195  * @param conformant controls whether side constraints (such as agreement of "numberOfChildren"
12196  * attributes with the number of <child> elements) should be enforced (conformant=true) or not
12197  *
12198  ***********************************************************************/
12199 bool OSOption::setRandom( double density, bool conformant )
12200 {
12201 #ifndef NDEBUG
12202  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random OSOption");
12203 #endif
12204  if (OSRand() <= density)
12205  {
12207  optionHeader->setRandom(density, conformant);
12208  }
12209  if (OSRand() <= density)
12210  {
12211  general = new GeneralOption();
12212  general->setRandom(density, conformant);
12213  }
12214  if (OSRand() <= density)
12215  {
12216  system = new SystemOption();
12217  system->setRandom(density, conformant);
12218  }
12219  if (OSRand() <= density)
12220  {
12221  service = new ServiceOption();
12222  service->setRandom(density, conformant);
12223  }
12224  if (OSRand() <= density)
12225  {
12226  job = new JobOption();
12227  job->setRandom(density, conformant);
12228  }
12229  if (OSRand() <= density)
12230  {
12232  optimization->setRandom(density, conformant);
12233  }
12234  return true;
12235 }//OSOption::setRandom
12236 
12237 
12238 bool GeneralOption::setRandom( double density, bool conformant )
12239 {
12240 #ifndef NDEBUG
12241  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random GeneralOption");
12242 #endif
12243  if (OSRand() <= density) this->serviceURI = "random string";
12244  if (OSRand() <= density) this->serviceName = "random string";
12245  if (OSRand() <= density) this->instanceName = "random string";
12246  if (OSRand() <= density) this->jobID = "random string";
12247  if (OSRand() <= density) this->solverToInvoke = "random string";
12248  if (OSRand() <= density) this->license = "random string";
12249  if (OSRand() <= density) this->userName = "random string";
12250  if (OSRand() <= density) this->password = "random string";
12251 
12252  if (OSRand() <= density)
12253  {
12255  instanceLocation->setRandom(density, conformant);
12256  }
12257  if (OSRand() <= density)
12258  {
12259  contact = new ContactOption();
12260  contact->setRandom(density, conformant);
12261  }
12262  if (OSRand() <= density)
12263  {
12264  otherOptions = new OtherOptions();
12265  otherOptions->setRandom(density, conformant);
12266  }
12267  return true;
12268 }//GeneralOption::setRandom
12269 
12270 
12271 bool SystemOption::setRandom( double density, bool conformant )
12272 {
12273 #ifndef NDEBUG
12274  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random SystemOption");
12275 #endif
12276  if (OSRand() <= density)
12277  {
12278  minDiskSpace = new StorageCapacity();
12279  minDiskSpace->setRandom(density, conformant);
12280  }
12281  if (OSRand() <= density)
12282  {
12284  minMemorySize->setRandom(density, conformant);
12285  }
12286  if (OSRand() <= density)
12287  {
12288  minCPUSpeed = new CPUSpeed();
12289  minCPUSpeed->setRandom(density, conformant);
12290  }
12291  if (OSRand() <= density)
12292  {
12293  minCPUNumber = new CPUNumber();
12294  minCPUNumber->setRandom(density, conformant);
12295  }
12296  if (OSRand() <= density)
12297  {
12298  otherOptions = new OtherOptions();
12299  otherOptions->setRandom(density, conformant);
12300  }
12301  return true;
12302 }//SystemOption::setRandom
12303 
12304 
12305 bool ServiceOption::setRandom( double density, bool conformant )
12306 {
12307 #ifndef NDEBUG
12308  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random ServiceOption");
12309 #endif
12310  if (OSRand() <= density)
12311  {
12312  double temp = OSRand();
12313  if (conformant) temp = 0.5*temp;
12314 
12315  if (temp <= 0.25) this->type = "solver";
12316  else if (temp <= 0.50) this->type = "agent";
12317  else if (temp <= 0.75) this->type = "";
12318  else this->type = "spy";
12319  }
12320 
12321  if (OSRand() <= density)
12322  {
12323  otherOptions = new OtherOptions();
12324  otherOptions->setRandom(density, conformant);
12325  }
12326 
12327  return true;
12328 }//ServiceOption::setRandom
12329 
12330 
12331 bool JobOption::setRandom( double density, bool conformant )
12332 {
12333 #ifndef NDEBUG
12334  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random JobOption");
12335 #endif
12336  if (OSRand() <= density) this->requestedStartTime = "1997-08-11T01:23:45-09:13";
12337 
12338  if (OSRand() <= density)
12339  {
12340  maxTime = new TimeSpan();
12341  maxTime->setRandom(density, conformant);
12342  }
12343  if (OSRand() <= density)
12344  {
12345  dependencies = new JobDependencies();
12346  dependencies->setRandom(density, conformant);
12347  }
12348  if (OSRand() <= density)
12349  {
12351  requiredDirectories->setRandom(density, conformant);
12352  }
12353  if (OSRand() <= density)
12354  {
12356  requiredFiles->setRandom(density, conformant);
12357  }
12358  if (OSRand() <= density)
12359  {
12361  directoriesToMake->setRandom(density, conformant);
12362  }
12363  if (OSRand() <= density)
12364  {
12366  filesToMake->setRandom(density, conformant);
12367  }
12368  if (OSRand() <= density)
12369  {
12371  inputDirectoriesToMove->setRandom(density, conformant);
12372  }
12373  if (OSRand() <= density)
12374  {
12375  inputFilesToMove = new PathPairs();
12376  inputFilesToMove->setRandom(density, conformant);
12377  }
12378  if (OSRand() <= density)
12379  {
12380  outputFilesToMove = new PathPairs();
12381  outputFilesToMove->setRandom(density, conformant);
12382  }
12383  if (OSRand() <= density)
12384  {
12386  outputDirectoriesToMove->setRandom(density, conformant);
12387  }
12388  if (OSRand() <= density)
12389  {
12391  filesToDelete->setRandom(density, conformant);
12392  }
12393  if (OSRand() <= density)
12394  {
12396  directoriesToDelete->setRandom(density, conformant);
12397  }
12398  if (OSRand() <= density)
12399  {
12400  processesToKill = new Processes();
12401  processesToKill->setRandom(density, conformant);
12402  }
12403  if (OSRand() <= density)
12404  {
12405  otherOptions = new OtherOptions();
12406  otherOptions->setRandom(density, conformant);
12407  }
12408  return true;
12409 }//JobOption::setRandom
12410 
12411 bool OptimizationOption::setRandom( double density, bool conformant )
12412 {
12413 #ifndef NDEBUG
12414  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random OptimizationOption");
12415 #endif
12416  if (OSRand() <= density && !conformant) this->numberOfVariables = (int)(1+9*OSRand());
12417  if (OSRand() <= density && !conformant) this->numberOfObjectives = (int)(1+9*OSRand());
12418  if (OSRand() <= density && !conformant) this->numberOfConstraints = (int)(1+9*OSRand());
12419 
12420  if (OSRand() <= density)
12421  {
12422  variables = new VariableOption();
12423  variables->setRandom(density, conformant);
12424  }
12425  if (OSRand() <= density)
12426  {
12427  objectives = new ObjectiveOption();
12428  objectives->setRandom(density, conformant);
12429  }
12430  if (OSRand() <= density)
12431  {
12432  constraints = new ConstraintOption();
12433  constraints->setRandom(density, conformant);
12434  }
12435  if (OSRand() <= density)
12436  {
12437  solverOptions = new SolverOptions();
12438  solverOptions->setRandom(density, conformant);
12439  }
12440 
12441  return true;
12442 }//OptimizationOption::setRandom
12443 
12444 bool InstanceLocationOption::setRandom( double density, bool conformant )
12445 {
12446 #ifndef NDEBUG
12447  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random InstanceLocationOption");
12448 #endif
12449  if (OSRand() <= density) this->value = "http://www.google.com";
12450  if (OSRand() <= density)
12451  {
12452  double temp = OSRand();
12453  if (conformant) temp = 0.5*temp;
12454 
12455  if (temp <= 0.25) this->locationType = "local";
12456  else if (temp <= 0.50) this->locationType = "ftp";
12457  else if (temp <= 0.75) this->locationType = "";
12458  else this->locationType = "global";
12459  }
12460  return true;
12461 }//InstanceLocationOption::setRandom
12462 
12463 bool ContactOption::setRandom( double density, bool conformant )
12464 {
12465 #ifndef NDEBUG
12466  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random ContactOption");
12467 #endif
12468  if (OSRand() <= density) this->value = "http://www.google.com";
12469  if (OSRand() <= density)
12470  {
12471  double temp = OSRand();
12472  if (conformant) temp = 0.5*temp;
12473 
12474  if (temp <= 0.25) this->transportType = "osp";
12475  else if (temp <= 0.50) this->transportType = "ftp";
12476  else if (temp <= 0.75) this->transportType = "";
12477  else this->transportType = "nlp";
12478  }
12479  return true;
12480 }//ContactOption::setRandom
12481 
12482 bool OtherOptions::setRandom( double density, bool conformant )
12483 {
12484 #ifndef NDEBUG
12485  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random OtherOptions");
12486 #endif
12487  int n;
12488 
12489  this->numberOfOtherOptions = (int)(1+4*OSRand());
12490 
12491  if (conformant) n = this->numberOfOtherOptions;
12492  else n = (int)(1+4*OSRand());
12493 
12494  other = new OtherOption*[n];
12495 
12496  for (int i = 0; i < n; i++)
12497  {
12498  other[i] = new OtherOption();
12499  other[i]->setRandom(density, conformant);
12500  }
12501 
12502  return true;
12503 }//OtherOptions::setRandom
12504 
12505 bool OtherOption::setRandom( double density, bool conformant )
12506 {
12507 #ifndef NDEBUG
12508  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random OtherOption");
12509 #endif
12510  if (OSRand() <= density || conformant) this->name = "random string";
12511  if (OSRand() <= density) this->value = "random string";
12512  if (OSRand() <= density) this->description = "random string";
12513  return true;
12514 }//OtherOption::setRandom
12515 
12516 
12517 
12518 bool JobDependencies::setRandom( double density, bool conformant )
12519 {
12520 #ifndef NDEBUG
12521  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random JobDependencies");
12522 #endif
12523  int n;
12524 
12525  this->numberOfJobIDs = (int)(1+4*OSRand());
12526 
12527  if (conformant) n = this->numberOfJobIDs;
12528  else n = (int)(1+4*OSRand());
12529 
12530  jobID = new std::string[n];
12531  for (int i = 0; i < n; i++)
12532  jobID[i] = "random string";
12533 
12534  return true;
12535 }//JobDependencies::setRandom
12536 
12537 bool DirectoriesAndFiles::setRandom( double density, bool conformant )
12538 {
12539 #ifndef NDEBUG
12540  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random DirectoriesAndFiles");
12541 #endif
12542  int n;
12543 
12544  this->numberOfPaths = (int)(1+4*OSRand());
12545 
12546  if (conformant) n = this->numberOfPaths;
12547  else n = (int)(1+4*OSRand());
12548 
12549 
12550  path = new std::string[n];
12551  for (int i = 0; i < n; i++)
12552  path[i] = "random string";
12553 
12554  return true;
12555 }//DirectoriesAndFiles::setRandom
12556 
12557 bool PathPairs::setRandom( double density, bool conformant )
12558 {
12559 #ifndef NDEBUG
12560  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random PathPairs");
12561 #endif
12562  int n;
12563 
12564  this->numberOfPathPairs = (int)(1+4*OSRand());
12565 
12566  if (conformant) n = this->numberOfPathPairs;
12567  else n =(int)(1+4*OSRand());
12568 
12569  pathPair = new PathPair*[n];
12570  for (int i = 0; i < n; i++)
12571  {
12572  this->pathPair[i] = new PathPair();
12573  this->pathPair[i]->setRandom(density, conformant);
12574  }
12575 
12576  return true;
12577 }//PathPairs::setRandom
12578 
12579 bool PathPair::setRandom( double density, bool conformant )
12580 {
12581 #ifndef NDEBUG
12582  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random PathPair");
12583 #endif
12584  this->from = "random string";
12585  this->to = "random string";
12586  if (OSRand() <= density) this->makeCopy = (OSRand() <= 0.5);
12587  return true;
12588 }//PathPair::setRandom
12589 
12590 bool Processes::setRandom( double density, bool conformant )
12591 {
12592 #ifndef NDEBUG
12593  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random Processes");
12594 #endif
12595  int n;
12596 
12597  this->numberOfProcesses = (int)(1+4*OSRand());
12598 
12599  if (conformant) n = this->numberOfProcesses;
12600  else n = (int)(1+4*OSRand());
12601 
12602  process = new std::string[n];
12603  for (int i = 0; i < n; i++)
12604  process[i] = "random string";
12605 
12606  return true;
12607 }//Processes::setRandom
12608 
12609 bool VariableOption::setRandom( double density, bool conformant )
12610 {
12611 #ifndef NDEBUG
12612  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random VariableOption");
12613 #endif
12614  if (OSRand() <= density)
12615  {
12617  this->initialVariableValues->setRandom(density, conformant);
12618  }
12619  return false;
12620  if (OSRand() <= density)
12621  {
12623  this->initialVariableValuesString->setRandom(density, conformant);
12624  }
12625  if (OSRand() <= density)
12626  {
12627  this->initialBasisStatus = new BasisStatus();
12628  this->initialBasisStatus->setRandom(density, conformant, 0, 9);
12629  }
12630  if (OSRand() <= density)
12631  {
12633  this->integerVariableBranchingWeights->setRandom(density, conformant);
12634  }
12635  if (OSRand() <= density)
12636  {
12638  this->sosVariableBranchingWeights->setRandom(density, conformant);
12639  }
12640 
12641 
12642  this->numberOfOtherVariableOptions = (int)(4*OSRand());
12643 
12644  int n;
12645 
12646  if (conformant) n = this->numberOfOtherVariableOptions;
12647  else n = (int)(4*OSRand());
12648 
12649  other = new OtherVariableOption*[n];
12650  for (int i = 0; i < n; i++)
12651  {
12652  other[i] = new OtherVariableOption();
12653  other[i]->setRandom(density, conformant);
12654  }
12655  return true;
12656 }//VariableOption::setRandom
12657 
12658 bool InitVariableValues::setRandom( double density, bool conformant )
12659 {
12660 #ifndef NDEBUG
12661  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random InitVariableValues");
12662 #endif
12663  this->numberOfVar = (int)(1+4*OSRand());
12664 
12665  int n;
12666 
12667  if (conformant) n = this->numberOfVar;
12668  else n = (int)(1+4*OSRand());
12669 
12670  var = new InitVarValue*[n];
12671  for (int i = 0; i < n; i++)
12672  {
12673  var[i] = new InitVarValue();
12674  var[i]->setRandom(density, conformant);
12675  }
12676  return true;
12677 }//InitVariableValues::setRandom
12678 
12679 bool InitVarValue::setRandom( double density, bool conformant )
12680 {
12681 #ifndef NDEBUG
12682  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random InitVarValue");
12683 #endif
12684  this->idx = (int)(4*OSRand());
12685 
12686  if (OSRand() <= density)
12687  this->name = "random string";
12688 
12689  if (OSRand() <= density)
12690  {
12691  if (OSRand() <= 0.5) this->value = 3.14156;
12692  else this->value = 2.71828;
12693  }
12694  return true;
12695 }//InitVarValue::setRandom
12696 
12697 
12698 bool InitVariableValuesString::setRandom( double density, bool conformant )
12699 {
12700 #ifndef NDEBUG
12701  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random InitVariableValuesString");
12702 #endif
12703  this->numberOfVar = (int)(1+4*OSRand());
12704 
12705  int n;
12706 
12707  if (conformant) n = this->numberOfVar;
12708  else n = (int)(1+4*OSRand());
12709 
12710  var = new InitVarValueString*[n];
12711  for (int i = 0; i < n; i++)
12712  {
12713  var[i] = new InitVarValueString();
12714  var[i]->setRandom(density, conformant);
12715  }
12716  return true;
12717 }//InitVariableValuesString::setRandom
12718 
12719 bool InitVarValueString::setRandom( double density, bool conformant )
12720 {
12721 #ifndef NDEBUG
12722  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random InitVarValueString");
12723 #endif
12724  this->idx = (int)(4*OSRand());
12725 
12726  if (OSRand() <= density) this->name = "random string";
12727  if (OSRand() <= density) this->value = "random string";
12728 
12729  return true;
12730 }//InitVarValueString::setRandom
12731 
12732 
12733 bool IntegerVariableBranchingWeights::setRandom( double density, bool conformant )
12734 {
12735 #ifndef NDEBUG
12736  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random IntegerVariableBranchingWeights");
12737 #endif
12738  this->numberOfVar = (int)(1+4*OSRand());
12739 
12740  int n;
12741 
12742  if (conformant) n = this->numberOfVar;
12743  else n = (int)(1+4*OSRand());
12744 
12745  var = new BranchingWeight*[n];
12746  for (int i = 0; i < n; i++)
12747  {
12748  var[i] = new BranchingWeight();
12749  var[i]->setRandom(density, conformant);
12750  }
12751  return true;
12752 }//IntegerVariableBranchingWeights::setRandom
12753 
12754 bool SOSVariableBranchingWeights::setRandom( double density, bool conformant )
12755 {
12756 #ifndef NDEBUG
12757  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random SOSVariableBranchingWeights");
12758 #endif
12759  this->numberOfSOS = (int)(1+4*OSRand());
12760 
12761  int n;
12762 
12763  if (conformant) n = this->numberOfSOS;
12764  else n = (int)(1+4*OSRand());
12765 
12766  sos = new SOSWeights*[n];
12767  for (int i = 0; i < n; i++)
12768  {
12769  sos[i] = new SOSWeights();
12770  sos[i]->setRandom(density, conformant);
12771  }
12772  return true;
12773 }//SOSVariableBranchingWeights::setRandom
12774 
12775 
12776 bool SOSWeights::setRandom( double density, bool conformant )
12777 {
12778 #ifndef NDEBUG
12779  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random SOSWeights");
12780 #endif
12781  this->sosIdx = (int)(4*OSRand());
12782  this->numberOfVar = (int)(4*OSRand());
12783 
12784  if (OSRand() <= density) this->groupWeight = OSRand();
12785 
12786 
12787  int n;
12788 
12789  if (conformant) n = this->numberOfVar;
12790  else n = (int)(4*OSRand());
12791 
12792  var = new BranchingWeight*[n];
12793  for (int i = 0; i < n; i++)
12794  {
12795  var[i] = new BranchingWeight();
12796  var[i]->setRandom(density, conformant);
12797  }
12798  return true;
12799 }//SOSWeights::setRandom
12800 
12801 
12802 bool BranchingWeight::setRandom( double density, bool conformant )
12803 {
12804 #ifndef NDEBUG
12805  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random BranchingWeight");
12806 #endif
12807  this->idx = (int)(4*OSRand());
12808 
12809  if (OSRand() <= density) this->name = "random string";
12810 
12811  if (OSRand() <= density)
12812  this->value = OSRand();
12813  return true;
12814 }//BranchingWeight::setRandom
12815 
12816 bool OtherVariableOption::setRandom( double density, bool conformant )
12817 {
12818 #ifndef NDEBUG
12819  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random OtherVariableOption");
12820 #endif
12821  this->name = "random string";
12822  if (OSRand() <= density) this->value = "random string";
12823  if (OSRand() <= density) this->solver = "random string";
12824  if (OSRand() <= density) this->category = "random string";
12825  if (OSRand() <= density) this->type = "random string";
12826  if (OSRand() <= density) this->description = "random string";
12827 
12828  if (OSRand() <= density)
12829  {
12830  if (OSRand() <= 0.5)
12831  {
12832  this->numberOfVar = (int)(4*OSRand());
12833 
12834  int n;
12835 
12836  if (conformant) n = this->numberOfVar;
12837  else n = (int)(4*OSRand());
12838 
12839  var = new OtherVarOption*[n];
12840  for (int i = 0; i < n; i++)
12841  {
12842  var[i] = new OtherVarOption();
12843  var[i]->setRandom(density, conformant);
12844  }
12845  }
12846  else
12847  {
12848  this->numberOfEnumerations = (int)(4*OSRand());
12849 
12850  int n;
12851 
12852  if (conformant) n = this->numberOfEnumerations;
12853  else n = (int)(4*OSRand());
12854 
12856  for (int i = 0; i < n; i++)
12857  {
12859  enumeration[i]->setRandom(density, conformant, 0, 9);
12860  }
12861  }
12862  }
12863  return true;
12864 }//OtherVariableOption::setRandom
12865 
12866 bool OtherVarOption::setRandom( double density, bool conformant )
12867 {
12868 #ifndef NDEBUG
12869  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random OtherVarOption");
12870 #endif
12871  this->idx = (int)(4*OSRand());
12872  if (OSRand() <= density) this->name = "random string";
12873  if (OSRand() <= density) this->value = "random string";
12874  if (OSRand() <= density) this->lbValue = "random string";
12875  if (OSRand() <= density) this->ubValue = "random string";
12876  return true;
12877 }//OtherVarOption::setRandom
12878 
12879 bool ObjectiveOption::setRandom( double density, bool conformant )
12880 {
12881 #ifndef NDEBUG
12882  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random ObjectiveOption");
12883 #endif
12884  if (OSRand() <= density)
12885  {
12887  this->initialObjectiveValues->setRandom(density, conformant);
12888  }
12889  return false;
12890  if (OSRand() <= density)
12891  {
12893  this->initialObjectiveBounds->setRandom(density, conformant);
12894  }
12895  if (OSRand() <= density)
12896  {
12897  this->initialBasisStatus = new BasisStatus();
12898  this->initialBasisStatus->setRandom(density, conformant, -2, -1);
12899  }
12900 
12901  if (OSRand() <= density)
12902  {
12903  this->numberOfOtherObjectiveOptions = (int)(4*OSRand());
12904 
12905  int n;
12906 
12907  if (conformant) n = this->numberOfOtherObjectiveOptions;
12908  else n = (int)(4*OSRand());
12909 
12910  other = new OtherObjectiveOption*[n];
12911  for (int i = 0; i < n; i++)
12912  {
12913  other[i] = new OtherObjectiveOption();
12914  other[i]->setRandom(density, conformant);
12915  }
12916  }
12917  return true;
12918 }//ObjectiveOption::setRandom
12919 
12920 bool InitObjectiveValues::setRandom( double density, bool conformant )
12921 {
12922 #ifndef NDEBUG
12923  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random InitObjectiveValues");
12924 #endif
12925  this->numberOfObj = (int)(1+4*OSRand());
12926 
12927  int n;
12928 
12929  if (conformant) n = this->numberOfObj;
12930  else n = (int)(1+4*OSRand());
12931 
12932  obj = new InitObjValue*[n];
12933  for (int i = 0; i < n; i++)
12934  {
12935  obj[i] = new InitObjValue();
12936  obj[i]->setRandom(density, conformant);
12937  }
12938  return true;
12939 }//InitObjectiveValues::setRandom
12940 
12941 bool InitObjValue::setRandom( double density, bool conformant )
12942 {
12943 #ifndef NDEBUG
12944  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random InitObjValue");
12945 #endif
12946  if (OSRand() <= 0.5) idx = -1;
12947  else idx = -2;
12948 
12949  if (OSRand() <= density) this->name = "random string";
12950 
12951  if (OSRand() <= density)
12952  {
12953  if (OSRand() <= 0.5) this->value = 3.14156;
12954  else this->value = 2.71828;
12955  }
12956  return true;
12957 }//InitObjValue::setRandom
12958 
12959 bool InitObjectiveBounds::setRandom( double density, bool conformant )
12960 {
12961 
12962 #ifndef NDEBUG
12963  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random InitObjectiveBounds");
12964 #endif
12965  this->numberOfObj = (int)(1+4*OSRand());
12966 
12967  int n;
12968 
12969  if (conformant) n = this->numberOfObj;
12970  else n = (int)(1+4*OSRand());
12971 
12972  obj = new InitObjBound*[n];
12973  for (int i = 0; i < n; i++)
12974  {
12975  obj[i] = new InitObjBound();
12976  obj[i]->setRandom(density, conformant);
12977  }
12978  return true;
12979 }//InitObjectiveBounds::setRandom
12980 
12981 bool InitObjBound::setRandom( double density, bool conformant )
12982 {
12983 #ifndef NDEBUG
12984  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random InitObjBound");
12985 #endif
12986  if (OSRand() <= 0.5) idx = -1;
12987  else idx = -2;
12988 
12989  if (OSRand() <= density) this->name = "random string";
12990 
12991  if (OSRand() <= density)
12992  {
12993  if (OSRand() <= 0.5) this->lbValue = 3.14156;
12994  else this->lbValue = 2.71828;
12995  if (OSRand() <= 0.5) this->ubValue = 3.14156;
12996  else this->ubValue = 2.71828;
12997  }
12998  return true;
12999 }//InitObjBound::setRandom
13000 
13001 bool OtherObjectiveOption::setRandom( double density, bool conformant )
13002 {
13003 #ifndef NDEBUG
13004  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random OtherObjectiveOption");
13005 #endif
13006  this->name = "random string";
13007  if (OSRand() <= density) this->value = "random string";
13008  if (OSRand() <= density) this->solver = "random string";
13009  if (OSRand() <= density) this->category = "random string";
13010  if (OSRand() <= density) this->type = "random string";
13011  if (OSRand() <= density) this->description = "random string";
13012 
13013  if (OSRand() <= density)
13014  {
13015  if (OSRand() <= 0.5)
13016  {
13017  this->numberOfObj = (int)(4*OSRand());
13018 
13019  int n;
13020 
13021  if (conformant) n = this->numberOfObj;
13022  else n = (int)(4*OSRand());
13023 
13024  obj = new OtherObjOption*[n];
13025  for (int i = 0; i < n; i++)
13026  {
13027  obj[i] = new OtherObjOption();
13028  obj[i]->setRandom(density, conformant);
13029  }
13030  }
13031  else
13032  {
13033  this->numberOfEnumerations = (int)(4*OSRand());
13034 
13035  int n;
13036 
13037  if (conformant) n = this->numberOfEnumerations;
13038  else n = (int)(4*OSRand());
13039 
13041  for (int i = 0; i < n; i++)
13042  {
13044  enumeration[i]->setRandom(density, conformant, -2, -1);
13045  }
13046  }
13047  }
13048  return true;
13049 }//OtherObjectiveOption::setRandom
13050 
13051 bool OtherObjOption::setRandom( double density, bool conformant )
13052 {
13053 #ifndef NDEBUG
13054  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random OtherObjOption");
13055 #endif
13056  if (OSRand() <= 0.5) this->idx = -1;
13057  else this->idx = -2;
13058  if (OSRand() <= density) this->name = "random string";
13059  if (OSRand() <= density) this->value = "random string";
13060  if (OSRand() <= density) this->lbValue = "random string";
13061  if (OSRand() <= density) this->ubValue = "random string";
13062  return true;
13063 }//OtherObjOption::setRandom
13064 
13065 bool ConstraintOption::setRandom( double density, bool conformant )
13066 {
13067 #ifndef NDEBUG
13068  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random ConstraintOption");
13069 #endif
13070  if (OSRand() <= density)
13071  {
13073  this->initialConstraintValues->setRandom(density, conformant);
13074  }
13075  return false;
13076  if (OSRand() <= density)
13077  {
13079  this->initialDualValues->setRandom(density, conformant);
13080  }
13081  if (OSRand() <= density)
13082  {
13083  this->initialBasisStatus = new BasisStatus();
13084  this->initialBasisStatus->setRandom(density, conformant, 0, 4);
13085  }
13086 
13087  if (OSRand() <= density)
13088  {
13089  this->numberOfOtherConstraintOptions = (int)(4*OSRand());
13090 
13091  int n;
13092 
13093  if (conformant) n = this->numberOfOtherConstraintOptions;
13094  else n = (int)(4*OSRand());
13095 
13096  other = new OtherConstraintOption*[n];
13097  for (int i = 0; i < n; i++)
13098  {
13099  other[i] = new OtherConstraintOption();
13100  other[i]->setRandom(density, conformant);
13101  }
13102  }
13103  return true;
13104 }//ConstraintOption::setRandom
13105 
13106 bool InitConstraintValues::setRandom( double density, bool conformant )
13107 {
13108 #ifndef NDEBUG
13109  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random InitConstraintValues");
13110 #endif
13111  this->numberOfCon = (int)(1+4*OSRand());
13112 
13113  int n;
13114 
13115  if (conformant) n = this->numberOfCon;
13116  else n = (int)(1+4*OSRand());
13117 
13118  con = new InitConValue*[n];
13119  for (int i = 0; i < n; i++)
13120  {
13121  con[i] = new InitConValue();
13122  con[i]->setRandom(density, conformant);
13123  }
13124  return true;
13125 }//InitConstraintValues::setRandom
13126 
13127 bool InitConValue::setRandom( double density, bool conformant )
13128 {
13129 #ifndef NDEBUG
13130  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random InitConValue");
13131 #endif
13132  this->idx = (int)(4*OSRand());
13133 
13134  if (OSRand() <= density) this->name = "random string";
13135 
13136  if (OSRand() <= density)
13137 
13138  {
13139  if (OSRand() <= 0.5) this->value = 3.14156;
13140  else this->value = 2.71828;
13141  }
13142  return true;
13143 }//InitConValue::setRandom
13144 
13145 bool InitDualVariableValues::setRandom( double density, bool conformant )
13146 {
13147 #ifndef NDEBUG
13148  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random InitDualVariableValues");
13149 #endif
13150  this->numberOfCon = (int)(1+4*OSRand());
13151 
13152  int n;
13153 
13154  if (conformant) n = this->numberOfCon;
13155  else n = (int)(1+4*OSRand());
13156 
13157  con = new InitDualVarValue*[n];
13158  for (int i = 0; i < n; i++)
13159  {
13160  con[i] = new InitDualVarValue();
13161  con[i]->setRandom(density, conformant);
13162  }
13163  return true;
13164 }//InitDualVariableValues::setRandom
13165 
13166 bool InitDualVarValue::setRandom( double density, bool conformant )
13167 {
13168 #ifndef NDEBUG
13169  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random InitDualVarValue");
13170 #endif
13171  this->idx = (int)(4*OSRand());
13172 
13173  if (OSRand() <= density) this->name = "random string";
13174 
13175  if (OSRand() <= density)
13176  {
13177  if (OSRand() <= 0.5) this->lbDualValue = 3.14156;
13178  else this->lbDualValue = 2.71828;
13179  if (OSRand() <= 0.5) this->ubDualValue = 3.14156;
13180  else this->ubDualValue = 2.71828;
13181  }
13182  return true;
13183 }//InitDualVarValue::setRandom
13184 
13185 bool OtherConstraintOption::setRandom( double density, bool conformant )
13186 {
13187 #ifndef NDEBUG
13188  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random OtherConstraintOption");
13189 #endif
13190  this->name = "random string";
13191  if (OSRand() <= density) this->value = "random string";
13192  if (OSRand() <= density) this->solver = "random string";
13193  if (OSRand() <= density) this->category = "random string";
13194  if (OSRand() <= density) this->type = "random string";
13195  if (OSRand() <= density) this->description = "random string";
13196 
13197  if (OSRand() <= density)
13198  {
13199  if (OSRand() <= 0.5)
13200  {
13201  this->numberOfCon = (int)(4*OSRand());
13202 
13203  int n;
13204 
13205  if (conformant) n = this->numberOfCon;
13206  else n = (int)(4*OSRand());
13207 
13208  con = new OtherConOption*[n];
13209  for (int i = 0; i < n; i++)
13210  {
13211  con[i] = new OtherConOption();
13212  con[i]->setRandom(density, conformant);
13213  }
13214  }
13215  else
13216  {
13217  this->numberOfEnumerations = (int)(4*OSRand());
13218 
13219  int n;
13220 
13221  if (conformant) n = this->numberOfEnumerations;
13222  else n = (int)(4*OSRand());
13223 
13225  for (int i = 0; i < n; i++)
13226  {
13228  enumeration[i]->setRandom(density, conformant, 0, 4);
13229  }
13230  }
13231  }
13232  return true;
13233 }//OtherConstraintOption::setRandom
13234 
13235 bool OtherConOption::setRandom( double density, bool conformant )
13236 {
13237 #ifndef NDEBUG
13238  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random OtherConOption");
13239 #endif
13240  this->idx = (int)(4*OSRand());
13241  if (OSRand() <= density) this->name = "random string";
13242  if (OSRand() <= density) this->value = "random string";
13243  if (OSRand() <= density) this->lbValue = "random string";
13244  if (OSRand() <= density) this->ubValue = "random string";
13245  return true;
13246 }//OtherConOption::setRandom
13247 
13248 
13249 bool SolverOptions::setRandom( double density, bool conformant )
13250 {
13251 #ifndef NDEBUG
13252  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random SolverOptions");
13253 #endif
13254  this->numberOfSolverOptions = (int)(1+4*OSRand());
13255 
13256  int n;
13257 
13258  if (conformant) n = this->numberOfSolverOptions;
13259  else n = (int)(1+4*OSRand());
13260 
13261  solverOption = new SolverOption*[n];
13262  for (int i = 0; i < n; i++)
13263  {
13264  solverOption[i] = new SolverOption();
13265  solverOption[i]->setRandom(density, conformant);
13266  }
13267  return true;
13268 }//SolverOptions::setRandom
13269 
13270 bool SolverOption::setRandom( double density, bool conformant )
13271 {
13272 #ifndef NDEBUG
13273  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Set random SolverOption");
13274 #endif
13275  if (OSRand() <= density || conformant) this->name = "random string";
13276 
13277  if (OSRand() <= density) this->value = "random string";
13278  if (OSRand() <= density) this->solver = "random string";
13279  if (OSRand() <= density) this->category = "random string";
13280  if (OSRand() <= density) this->type = "random string";
13281  if (OSRand() <= density) this->description = "random string";
13282 
13283  if (OSRand() <= density)
13284  {
13285  this->numberOfItems = (int)(4*OSRand());
13286 
13287  int n;
13288 
13289  if (conformant) n = this->numberOfItems;
13290  else n = (int)(4*OSRand());
13291 
13292  item = new std::string[n];
13293  for (int i = 0; i < n; i++)
13294  item[i] = "random string";
13295  }
13296  return true;
13297 }//SolverOption::setRandom
13298 
13299 
13300 /***********************************************************************
13301  *
13302  * Methods that allow deep copies of an OSOption object.
13303  *
13304  * These methods call each other recursively.
13305  *
13306  ***********************************************************************/
13307 
13309 {
13310 #ifndef NDEBUG
13311  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of OSOption");
13312 #endif
13313  if (that->optionHeader != NULL)
13314  {
13315  this->optionHeader = new GeneralFileHeader();
13316  if (!this->optionHeader->deepCopyFrom(that->optionHeader))
13317  return false;
13318  }
13319  if (that->general != NULL)
13320  {
13321  this->general = new GeneralOption();
13322  if (!this->general->deepCopyFrom(that->general))
13323  return false;
13324  }
13325  if (that->system != NULL)
13326  {
13327  this->system = new SystemOption();
13328  if (!this->system->deepCopyFrom(that->system))
13329  return false;
13330  }
13331  if (that->service != NULL)
13332  {
13333  this->service = new ServiceOption();
13334  if (!this->service->deepCopyFrom(that->service))
13335  return false;
13336  }
13337  if (that->job != NULL)
13338  {
13339  this->job = new JobOption();
13340  if (!this->job->deepCopyFrom(that->job))
13341  return false;
13342  }
13343  if (that->optimization != NULL)
13344  {
13345  this->optimization = new OptimizationOption();
13346  if (!this->optimization->deepCopyFrom(that->optimization))
13347  return false;
13348  }
13349  return true;
13350 }//OSOption::deepCopyFrom
13351 
13352 
13354 {
13355 #ifndef NDEBUG
13356  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of GeneralOption");
13357 #endif
13358  this->serviceURI = that->serviceURI;
13359  this->serviceName = that->serviceName;
13360  this->instanceName = that->instanceName;
13361  this->jobID = that->jobID;
13362  this->solverToInvoke = that->solverToInvoke;
13363  this->license = that->license;
13364  this->userName = that->userName;
13365  this->password = that->password;
13366 
13367  if (that->instanceLocation != NULL)
13368  {
13370  if (!this->instanceLocation->deepCopyFrom(that->instanceLocation))
13371  return false;
13372  }
13373  if (that->contact != NULL)
13374  {
13375  this->contact = new ContactOption();
13376  if (!this->contact->deepCopyFrom(that->contact))
13377  return false;
13378  }
13379  if (that->otherOptions != NULL)
13380  {
13381  this->otherOptions = new OtherOptions();
13382  if (!this->otherOptions->deepCopyFrom(that->otherOptions))
13383  return false;
13384  }
13385  return true;
13386 }//GeneralOption::deepCopyFrom
13387 
13388 
13390 {
13391 #ifndef NDEBUG
13392  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of SystemOption");
13393 #endif
13394  if (that->minDiskSpace != NULL)
13395  {
13396  this->minDiskSpace = new StorageCapacity();
13397  if (!this->minDiskSpace->deepCopyFrom(that->minDiskSpace))
13398  return false;
13399  }
13400  if (that->minMemorySize != NULL)
13401  {
13402  this->minMemorySize = new StorageCapacity();
13403  if (!this->minMemorySize->deepCopyFrom(that->minMemorySize))
13404  return false;
13405  }
13406  if (that->minCPUSpeed != NULL)
13407  {
13408  this->minCPUSpeed = new CPUSpeed();
13409  if (!this->minCPUSpeed->deepCopyFrom(that->minCPUSpeed))
13410  return false;
13411  }
13412  if (that->minCPUNumber != NULL)
13413  {
13414  this->minCPUNumber = new CPUNumber();
13415  if (!this->minCPUNumber->deepCopyFrom(that->minCPUNumber))
13416  return false;
13417  }
13418  if (that->otherOptions != NULL)
13419  {
13420  this->otherOptions = new OtherOptions();
13421  if (!this->otherOptions->deepCopyFrom(that->otherOptions))
13422  return false;
13423  }
13424  return true;
13425 }//SystemOption::deepCopyFrom
13426 
13427 
13429 {
13430 #ifndef NDEBUG
13431  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of ServiceOption");
13432 #endif
13433  this->type = that->type;
13434 
13435  if (that->otherOptions != NULL)
13436  {
13437  otherOptions = new OtherOptions();
13438  if (!otherOptions->deepCopyFrom(that->otherOptions))
13439  return false;
13440  }
13441 
13442  return true;
13443 }//ServiceOption::deepCopyFrom
13444 
13445 
13447 {
13448 #ifndef NDEBUG
13449  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of JobOption");
13450 #endif
13451  this->requestedStartTime = that->requestedStartTime;
13452 
13453  if (that->maxTime != NULL)
13454  {
13455  maxTime = new TimeSpan();
13456  if (!maxTime->deepCopyFrom(that->maxTime))
13457  return false;
13458  }
13459  if (that->dependencies != NULL)
13460  {
13461  dependencies = new JobDependencies();
13462  if (!dependencies->deepCopyFrom(that->dependencies))
13463  return false;
13464  }
13465  if (that->requiredDirectories != NULL)
13466  {
13469  return false;
13470  }
13471  if (that->requiredFiles != NULL)
13472  {
13475  return false;
13476  }
13477  if (that->directoriesToMake != NULL)
13478  {
13481  return false;
13482  }
13483  if (that->filesToMake != NULL)
13484  {
13486  if (!filesToMake->deepCopyFrom(that->filesToMake))
13487  return false;
13488  }
13489  if (that->inputDirectoriesToMove != NULL)
13490  {
13493  return false;
13494  }
13495  if (that->inputFilesToMove != NULL)
13496  {
13497  inputFilesToMove = new PathPairs();
13499  return false;
13500  }
13501  if (that->outputFilesToMove != NULL)
13502  {
13503  outputFilesToMove = new PathPairs();
13505  return false;
13506  }
13507  if (that->outputDirectoriesToMove != NULL)
13508  {
13511  return false;
13512  }
13513  if (that->filesToDelete != NULL)
13514  {
13517  return false;
13518  }
13519  if (that->directoriesToDelete != NULL)
13520  {
13523  return false;
13524  }
13525  if (that->processesToKill != NULL)
13526  {
13527  processesToKill = new Processes();
13529  return false;
13530  }
13531  if (that->otherOptions != NULL)
13532  {
13533  otherOptions = new OtherOptions();
13534  if (!otherOptions->deepCopyFrom(that->otherOptions))
13535  return false;
13536  }
13537  return true;
13538 }//JobOption::deepCopyFrom
13539 
13541 {
13542 #ifndef NDEBUG
13543  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of OptimizationOption");
13544 #endif
13545  this->numberOfVariables = that->numberOfVariables;
13546  this->numberOfObjectives = that->numberOfObjectives;
13548 
13549  if (that->variables != NULL)
13550  {
13551  variables = new VariableOption();
13552  if (!variables->deepCopyFrom(that->variables))
13553  return false;
13554  }
13555  if (that->objectives != NULL)
13556  {
13557  objectives = new ObjectiveOption();
13558  if (!objectives->deepCopyFrom(that->objectives))
13559  return false;
13560  }
13561  if (that->constraints != NULL)
13562  {
13563  constraints = new ConstraintOption();
13564  if (!constraints->deepCopyFrom(that->constraints))
13565  return false;
13566  }
13567  if (that->solverOptions != NULL)
13568  {
13569  solverOptions = new SolverOptions();
13571  return false;
13572  }
13573 
13574  return true;
13575 }//OptimizationOption::deepCopyFrom
13576 
13578 {
13579 #ifndef NDEBUG
13580  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of InstanceLocationOption");
13581 #endif
13582  this->value = that->value;
13583  this->locationType = that->locationType;
13584  return true;
13585 }//InstanceLocationOption::deepCopyFrom
13586 
13588 {
13589 #ifndef NDEBUG
13590  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of ContactOption");
13591 #endif
13592  this->value = that->value;
13593  this->transportType = that->transportType;
13594  return true;
13595 }//ContactOption::deepCopyFrom
13596 
13598 {
13599 #ifndef NDEBUG
13600  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of OtherOptions");
13601 #endif
13602  int n;
13603 
13604  n = that->numberOfOtherOptions;
13605  this->numberOfOtherOptions = n;
13606 
13607  if (n < 0) return false;
13608  if (n == 0) return true;
13609 
13610  this->other = new OtherOption*[n];
13611 
13612  for (int i = 0; i < n; i++)
13613  {
13614  this->other[i] = new OtherOption();
13615  if (!this->other[i]->deepCopyFrom(that->other[i]))
13616  return false;
13617  }
13618 
13619  return true;
13620 }//OtherOptions::deepCopyFrom
13621 
13623 {
13624 #ifndef NDEBUG
13625  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of OtherOption");
13626 #endif
13627  this->name = that->name;
13628  this->value = that->value;
13629  this->description = that->description;
13630  return true;
13631 }//OtherOption::deepCopyFrom
13632 
13633 
13635 {
13636 #ifndef NDEBUG
13637  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of JobDependencies");
13638 #endif
13639  int n;
13640 
13641  this->numberOfJobIDs = that->numberOfJobIDs;
13642  n = this->numberOfJobIDs;
13643 
13644  if (n < 0) return false;
13645  if (n == 0) return true;
13646 
13647  this->jobID = new std::string[n];
13648  for (int i = 0; i < n; i++)
13649  this->jobID[i] = that->jobID[i];
13650 
13651  return true;
13652 }//JobDependencies::deepCopyFrom
13653 
13655 {
13656 #ifndef NDEBUG
13657  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of DirectoriesAndFiles");
13658 #endif
13659  int n;
13660 
13661  this->numberOfPaths = that->numberOfPaths;
13662  n = this->numberOfPaths;
13663 
13664  if (n < 0) return false;
13665  if (n == 0) return true;
13666 
13667  this->path = new std::string[n];
13668  for (int i = 0; i < n; i++)
13669  this->path[i] = that->path[i];
13670 
13671  return true;
13672 }//DirectoriesAndFiles::deepCopyFrom
13673 
13675 {
13676 #ifndef NDEBUG
13677  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of PathPairs");
13678 #endif
13679  int n;
13680 
13681  this->numberOfPathPairs = that->numberOfPathPairs;
13682  n = this->numberOfPathPairs;
13683 
13684  if (n < 0) return false;
13685  if (n == 0) return true;
13686 
13687  pathPair = new PathPair*[n];
13688  for (int i = 0; i < n; i++)
13689  {
13690  this->pathPair[i] = new PathPair();
13691  if (!this->pathPair[i]->deepCopyFrom(that->pathPair[i]))
13692  return false;
13693  }
13694 
13695  return true;
13696 }//PathPairs::deepCopyFrom
13697 
13699 {
13700 #ifndef NDEBUG
13701  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of PathPair");
13702 #endif
13703  this->from = that->from;
13704  this->to = that->to;
13705  this->makeCopy = that->makeCopy;
13706  return true;
13707 }//PathPair::deepCopyFrom
13708 
13710 {
13711 #ifndef NDEBUG
13712  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of Processes");
13713 #endif
13714  int n;
13715 
13716  this->numberOfProcesses = that->numberOfProcesses;
13717  n = this->numberOfProcesses;
13718 
13719  if (n < 0) return false;
13720  if (n == 0) return true;
13721 
13722  process = new std::string[n];
13723  for (int i = 0; i < n; i++)
13724  this->process[i] = that->process[i];
13725 
13726  return true;
13727 }//Processes::deepCopyFrom
13728 
13729 
13731 {
13732 #ifndef NDEBUG
13733  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of VariableOption");
13734 #endif
13735  if (that->initialVariableValues != NULL)
13736  {
13739  return false;
13740  }
13741  if (that->initialVariableValuesString != NULL)
13742  {
13745  return false;
13746  }
13747  if (that->initialBasisStatus != NULL)
13748  {
13749  this->initialBasisStatus = new BasisStatus();
13751  return false;
13752  }
13753  if (that->integerVariableBranchingWeights != NULL)
13754  {
13757  return false;
13758  }
13759  if (that->sosVariableBranchingWeights != NULL)
13760  {
13763  return false;
13764  }
13765 
13767  int n = this->numberOfOtherVariableOptions;
13768 
13769  if (n < 0) return false;
13770  if (n == 0) return true;
13771 
13772  this->other = new OtherVariableOption*[n];
13773  for (int i = 0; i < n; i++)
13774  {
13775  this->other[i] = new OtherVariableOption();
13776  if (!this->other[i]->deepCopyFrom(that->other[i]))
13777  return false;
13778  }
13779  return true;
13780 }//VariableOption::deepCopyFrom
13781 
13783 {
13784 #ifndef NDEBUG
13785  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of InitVariableValues");
13786 #endif
13787  this->numberOfVar = that->numberOfVar;
13788 
13789  int n = this->numberOfVar;
13790 
13791  if (n < 0) return false;
13792  if (n == 0) return true;
13793 
13794  this->var = new InitVarValue*[n];
13795  for (int i = 0; i < n; i++)
13796  {
13797  this->var[i] = new InitVarValue();
13798  if (!this->var[i]->deepCopyFrom(that->var[i]))
13799  return false;
13800  }
13801  return true;
13802 }//InitVariableValues::deepCopyFrom
13803 
13805 {
13806 #ifndef NDEBUG
13807  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of InitVarValue");
13808 #endif
13809  this->idx = that->idx;
13810  this->name = that->name;
13811  this->value = that->value;
13812  return true;
13813 }//InitVarValue::deepCopyFrom
13814 
13815 
13817 {
13818 #ifndef NDEBUG
13819  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of InitVariableValuesString");
13820 #endif
13821  this->numberOfVar = that->numberOfVar;
13822  int n = this->numberOfVar;
13823 
13824  if (n < 0) return false;
13825  if (n == 0) return true;
13826 
13827  this->var = new InitVarValueString*[n];
13828  for (int i = 0; i < n; i++)
13829  {
13830  this->var[i] = new InitVarValueString();
13831  if (!this->var[i]->deepCopyFrom(that->var[i]))
13832  return false;
13833  }
13834  return true;
13835 }//InitVariableValuesString::deepCopyFrom
13836 
13838 {
13839 #ifndef NDEBUG
13840  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of InitVarValueString");
13841 #endif
13842  this->idx = that->idx;
13843  this->name = that->name;
13844  this->value = that->value;
13845  return true;
13846 }//InitVarValueString::deepCopyFrom
13847 
13848 
13850 {
13851 #ifndef NDEBUG
13852  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of IntegerVariableBranchingWeights");
13853 #endif
13854  this->numberOfVar = that->numberOfVar;
13855  int n = this->numberOfVar;
13856 
13857  if (n < 0) return false;
13858  if (n == 0) return true;
13859 
13860  this->var = new BranchingWeight*[n];
13861  for (int i = 0; i < n; i++)
13862  {
13863  this->var[i] = new BranchingWeight();
13864  if (!this->var[i]->deepCopyFrom(that->var[i]))
13865  return false;
13866  }
13867  return true;
13868 }//IntegerVariableBranchingWeights::deepCopyFrom
13869 
13871 {
13872 #ifndef NDEBUG
13873  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of SOSVariableBranchingWeights");
13874 #endif
13875  this->numberOfSOS = that->numberOfSOS;
13876  int n = this->numberOfSOS;
13877 
13878  if (n < 0) return false;
13879  if (n == 0) return true;
13880 
13881  this->sos = new SOSWeights*[n];
13882  for (int i = 0; i < n; i++)
13883  {
13884  this->sos[i] = new SOSWeights();
13885  if (!this->sos[i]->deepCopyFrom(that->sos[i]))
13886  return false;
13887  }
13888  return true;
13889 }//SOSVariableBranchingWeights::deepCopyFrom
13890 
13891 
13893 {
13894 #ifndef NDEBUG
13895  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of SOSWeights");
13896 #endif
13897  this->sosIdx = that->sosIdx;
13898  this->groupWeight = that->groupWeight;
13899 
13900  this->numberOfVar = that->numberOfVar;
13901  int n = this->numberOfVar;
13902 
13903  if (n < 0) return false;
13904  if (n == 0) return true;
13905 
13906  this->var = new BranchingWeight*[n];
13907  for (int i = 0; i < n; i++)
13908  {
13909  this->var[i] = new BranchingWeight();
13910  if (!this->var[i]->deepCopyFrom(that->var[i]))
13911  return false;
13912  }
13913  return true;
13914 }//SOSWeights::deepCopyFrom
13915 
13916 
13918 {
13919 #ifndef NDEBUG
13920  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of BranchingWeight");
13921 #endif
13922  this->idx = that->idx;
13923  this->name = that->name;
13924  this->value = that->value;
13925  return true;
13926 }//BranchingWeight::deepCopyFrom
13927 
13929 {
13930 #ifndef NDEBUG
13931  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of OtherVariableOption");
13932 #endif
13933  this->name = that->name;
13934  this->value = that->value;
13935  this->solver = that->solver;
13936  this->category = that->category;
13937  this->type = that->type;
13938  this->varType = that->varType;
13939  this->enumType = that->enumType;
13940  this->description = that->description;
13941 
13942  int n;
13943  this->numberOfVar = that->numberOfVar;
13944  n = this->numberOfVar;
13945 
13946  if (n < 0) return false;
13947  if (n > 0)
13948  {
13949  this->var = new OtherVarOption*[n];
13950  for (int i = 0; i < n; i++)
13951  {
13952  this->var[i] = new OtherVarOption();
13953  if (!this->var[i]->deepCopyFrom(that->var[i]))
13954  return false;
13955  }
13956  }
13957 
13959  n = this->numberOfEnumerations;
13960 
13961  if (n < 0) return false;
13962  if (n == 0) return true;
13963 
13965  for (int i = 0; i < n; i++)
13966  {
13968  if (!this->enumeration[i]->deepCopyFrom(that->enumeration[i]))
13969  return false;
13970  }
13971  return true;
13972 }//OtherVariableOption::deepCopyFrom
13973 
13975 {
13976 #ifndef NDEBUG
13977  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of OtherVarOption");
13978 #endif
13979  this->idx = that->idx;
13980  this->name = that->name;
13981  this->value = that->value;
13982  this->lbValue = that->lbValue;
13983  this->ubValue = that->ubValue;
13984  return true;
13985 }//OtherVarOption::deepCopyFrom
13986 
13988 {
13989 #ifndef NDEBUG
13990  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of ObjectiveOption");
13991 #endif
13992  if (that->initialObjectiveValues != NULL)
13993  {
13996  return false;
13997  }
13998  if (that->initialObjectiveBounds != NULL)
13999  {
14002  return false;
14003  }
14004  if (that->initialBasisStatus != NULL)
14005  {
14006  this->initialBasisStatus = new BasisStatus();
14008  return false;
14009  }
14010 
14012  int n = this->numberOfOtherObjectiveOptions;
14013 
14014  if (n < 0) return false;
14015  if (n == 0) return true;
14016 
14017  this->other = new OtherObjectiveOption*[n];
14018  for (int i = 0; i < n; i++)
14019  {
14020  this->other[i] = new OtherObjectiveOption();
14021  if (!this->other[i]->deepCopyFrom(that->other[i]))
14022  return false;
14023  }
14024  return true;
14025 }//ObjectiveOption::deepCopyFrom
14026 
14028 {
14029 #ifndef NDEBUG
14030  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of InitObjectiveValues");
14031 #endif
14032  this->numberOfObj = that->numberOfObj;
14033  int n = this->numberOfObj;
14034 
14035  if (n < 0) return false;
14036  if (n == 0) return true;
14037 
14038  this->obj = new InitObjValue*[n];
14039  for (int i = 0; i < n; i++)
14040  {
14041  this->obj[i] = new InitObjValue();
14042  if (!this->obj[i]->deepCopyFrom(that->obj[i]))
14043  return false;
14044  }
14045  return true;
14046 }//InitObjectiveValues::deepCopyFrom
14047 
14049 {
14050 #ifndef NDEBUG
14051  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of InitObjValue");
14052 #endif
14053  this->idx = that->idx;
14054  this->name = that->name;
14055  this->value = that->value;
14056  return true;
14057 }//InitObjValue::deepCopyFrom
14058 
14060 {
14061 #ifndef NDEBUG
14062  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of InitObjectiveBounds");
14063 #endif
14064  this->numberOfObj = that->numberOfObj;
14065  int n = this->numberOfObj;
14066 
14067  if (n < 0) return false;
14068  if (n == 0) return true;
14069 
14070  this->obj = new InitObjBound*[n];
14071  for (int i = 0; i < n; i++)
14072  {
14073  this->obj[i] = new InitObjBound();
14074  if (!this->obj[i]->deepCopyFrom(that->obj[i]))
14075  return false;
14076  }
14077  return true;
14078 }//InitObjectiveBounds::deepCopyFrom
14079 
14081 {
14082 #ifndef NDEBUG
14083  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of InitObjBound");
14084 #endif
14085  this->idx = that->idx;
14086  this->name = that->name;
14087  this->lbValue = that->lbValue;
14088  this->ubValue = that->ubValue;
14089  return true;
14090 }//InitObjBound::deepCopyFrom
14091 
14093 {
14094 #ifndef NDEBUG
14095  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of OtherObjectiveOption");
14096 #endif
14097  this->name = that->name;
14098  this->value = that->value;
14099  this->solver = that->solver;
14100  this->category = that->category;
14101  this->type = that->type;
14102  this->objType = that->objType;
14103  this->enumType = that->enumType;
14104  this->description = that->description;
14105 
14106  int n;
14107 
14108  this->numberOfObj = that->numberOfObj;
14109 
14110  n = this->numberOfObj;
14111 
14112  if (n < 0) return false;
14113  if (n > 0)
14114  {
14115  this->obj = new OtherObjOption*[n];
14116  for (int i = 0; i < n; i++)
14117  {
14118  this->obj[i] = new OtherObjOption();
14119  if (!this->obj[i]->deepCopyFrom(that->obj[i]))
14120  return false;
14121  }
14122  }
14123 
14125  n = this->numberOfEnumerations;
14126 
14127  if (n < 0) return false;
14128  if (n > 0)
14129  {
14131  for (int i = 0; i < n; i++)
14132  {
14134  if (!this->enumeration[i]->deepCopyFrom(that->enumeration[i]))
14135  return false;
14136  }
14137  }
14138  return true;
14139 }//OtherObjectiveOption::deepCopyFrom
14140 
14142 {
14143 #ifndef NDEBUG
14144  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of OtherObjOption");
14145 #endif
14146  this->idx = that->idx;
14147  this->name = that->name;
14148  this->value = that->value;
14149  this->lbValue = that->lbValue;
14150  this->ubValue = that->ubValue;
14151  return true;
14152 }//OtherObjOption::deepCopyFrom
14153 
14155 {
14156 #ifndef NDEBUG
14157  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of ConstraintOption");
14158 #endif
14159  if (that->initialConstraintValues != NULL)
14160  {
14163  return false;
14164  }
14165  if (that->initialDualValues != NULL)
14166  {
14169  return false;
14170  }
14171  if (that->initialBasisStatus != NULL)
14172  {
14173  this->initialBasisStatus = new BasisStatus();
14175  return false;
14176  }
14177 
14179  int n = this->numberOfOtherConstraintOptions;
14180 
14181  if (n < 0) return false;
14182  if (n == 0) return true;
14183 
14184  this->other = new OtherConstraintOption*[n];
14185  for (int i = 0; i < n; i++)
14186  {
14187  this->other[i] = new OtherConstraintOption();
14188  if (!this->other[i]->deepCopyFrom(that->other[i]))
14189  return false;
14190  }
14191  return true;
14192 }//ConstraintOption::deepCopyFrom
14193 
14195 {
14196 #ifndef NDEBUG
14197  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of InitConstraintValues");
14198 #endif
14199  this->numberOfCon = that->numberOfCon;
14200  int n = this->numberOfCon;
14201 
14202  if (n < 0) return false;
14203  if (n == 0) return true;
14204 
14205  this->con = new InitConValue*[n];
14206  for (int i = 0; i < n; i++)
14207  {
14208  this->con[i] = new InitConValue();
14209  if (!this->con[i]->deepCopyFrom(that->con[i]))
14210  return false;
14211  }
14212  return true;
14213 }//InitConstraintValues::deepCopyFrom
14214 
14216 {
14217 #ifndef NDEBUG
14218  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of InitConValue");
14219 #endif
14220  this->idx = that->idx;
14221  this->name = that->name;
14222  this->value = that->value;
14223  return true;
14224 }//InitConValue::deepCopyFrom
14225 
14227 {
14228 #ifndef NDEBUG
14229  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of InitDualVariableValues");
14230 #endif
14231  this->numberOfCon = that->numberOfCon;
14232  int n = this->numberOfCon;
14233 
14234  if (n < 0) return false;
14235  if (n == 0) return true;
14236 
14237  this->con = new InitDualVarValue*[n];
14238  for (int i = 0; i < n; i++)
14239  {
14240  this->con[i] = new InitDualVarValue();
14241  if (!this->con[i]->deepCopyFrom(that->con[i]))
14242  return false;
14243  }
14244  return true;
14245 }//InitDualVariableValues::deepCopyFrom
14246 
14248 {
14249 #ifndef NDEBUG
14250  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of InitDualVarValue");
14251 #endif
14252  this->idx = that->idx;
14253  this->name = that->name;
14254  this->lbDualValue = that->lbDualValue;
14255  this->ubDualValue = that->ubDualValue;
14256  return true;
14257 }//InitDualVarValue::deepCopyFrom
14258 
14260 {
14261 #ifndef NDEBUG
14262  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of OtherConstraintOption");
14263 #endif
14264  this->name = that->name;
14265  this->value = that->value;
14266  this->solver = that->solver;
14267  this->category = that->category;
14268  this->type = that->type;
14269  this->conType = that->conType;
14270  this->enumType = that->enumType;
14271  this->description = that->description;
14272 
14273  int n;
14274 
14275  this->numberOfCon = that->numberOfCon;
14276  n = this->numberOfCon;
14277 
14278  if (n < 0) return false;
14279  if (n > 0)
14280  {
14281  this->con = new OtherConOption*[n];
14282  for (int i = 0; i < n; i++)
14283  {
14284  this->con[i] = new OtherConOption();
14285  if (!this->con[i]->deepCopyFrom(that->con[i]))
14286  return false;
14287  }
14288  }
14289 
14291  n = this->numberOfEnumerations;
14292 
14293  if (n < 0) return false;
14294  if (n > 0)
14295  {
14297  for (int i = 0; i < n; i++)
14298  {
14300  if (!this->enumeration[i]->deepCopyFrom(that->enumeration[i]))
14301  return false;
14302  }
14303  }
14304  return true;
14305 }//OtherConstraintOption::deepCopyFrom
14306 
14308 {
14309 #ifndef NDEBUG
14310  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of OtherConOption");
14311 #endif
14312  this->idx = that->idx;
14313  this->name = that->name;
14314  this->value = that->value;
14315  this->lbValue = that->lbValue;
14316  this->ubValue = that->ubValue;
14317  return true;
14318 }//OtherConOption::deepCopyFrom
14319 
14320 
14322 {
14323 #ifndef NDEBUG
14324  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of SolverOptions");
14325 #endif
14327  int n = this->numberOfSolverOptions;
14328 
14329  if (n < 0) return false;
14330  if (n == 0) return true;
14331 
14332  this->solverOption = new SolverOption*[n];
14333  for (int i = 0; i < n; i++)
14334  {
14335  this->solverOption[i] = new SolverOption();
14336  if (!this->solverOption[i]->deepCopyFrom(that->solverOption[i]))
14337  return false;
14338  }
14339  return true;
14340 }//SolverOptions::deepCopyFrom
14341 
14343 {
14344 #ifndef NDEBUG
14345  osoutput->OSPrint(ENUM_OUTPUT_AREA_OSOption, ENUM_OUTPUT_LEVEL_trace, "Make deep copy of SolverOption");
14346 #endif
14347  this->name = that->name;
14348  this->value = that->value;
14349  this->solver = that->solver;
14350  this->category = that->category;
14351  this->type = that->type;
14352  this->description = that->description;
14353 
14354  this->numberOfItems = that->numberOfItems;
14355  int n = this->numberOfItems;
14356 
14357  if (n < 0) return false;
14358  if (n == 0) return true;
14359 
14360  this->item = new std::string[n];
14361  for (int i = 0; i < n; i++)
14362  this->item[i] = that->item[i];
14363 
14364  return true;
14365 }//SolverOption::deepCopyFrom
14366 
~SolverOption()
Class destructor.
Definition: OSOption.cpp:1194
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12920
int getNumberOfOutputFilesToMove()
Get the number of output files to move.
Definition: OSOption.cpp:1969
bool IsEqual(InitConstraintValues *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:11766
bool setAnotherSOSVariableBranchingWeight(int sosIdx, int nvar, double weight, int *idx, double *value, std::string *name)
Definition: OSOption.cpp:8731
std::string unit
the unit in which CPU speed is measured
Definition: OSGeneral.h:817
~GeneralOption()
Class destructor.
Definition: OSOption.cpp:131
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12537
std::string value
value of the option
Definition: OSOption.h:2003
IntVector * atUpper
Definition: OSGeneral.h:650
std::string getJobID()
Get the job ID.
Definition: OSOption.cpp:1473
bool IsEqual(InitObjValue *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:11445
PathPairs()
Default constructor.
Definition: OSOption.cpp:327
InitConstraintValues * initialConstraintValues
initial values for the constraints
Definition: OSOption.h:3271
the IntegerVariableBranchingWeights class.
Definition: OSOption.h:1671
InitDualVariableValues()
Default constructor.
Definition: OSOption.cpp:1047
~ConstraintOption()
Class destructor.
Definition: OSOption.cpp:1154
the SystemOption class.
Definition: OSOption.h:545
bool setOtherJobOptions(int numberOfOptions, OtherOption **other)
Definition: OSOption.cpp:8332
bool setAnotherFileToDelete(std::string path)
Definition: OSOption.cpp:8278
int idx
variable index
Definition: OSOption.h:3096
bool deepCopyFrom(OptimizationOption *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:13540
~OtherConOption()
Class destructor.
Definition: OSOption.cpp:1087
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12579
bool setIntegerVariableBranchingWeights(int numberOfVar, int *idx, double *value, std::string *name)
Definition: OSOption.cpp:8633
the OtherOption class.
Definition: OSOption.h:152
bool IsEqual(BranchingWeight *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:11159
the OtherConstraintOption class.
Definition: OSOption.h:3156
bool setInitBasisStatus(int object, int status, int *i, int ni)
Definition: OSOption.cpp:8544
int getNumberOfInitVarValues()
Get the number of initial variable values.
Definition: OSOption.cpp:2051
SOSVariableBranchingWeights()
Default constructor.
Definition: OSOption.cpp:645
bool setCon(int numberOfCon, OtherConOption **con)
A function to set an array of &lt;con&gt; elements.
Definition: OSOption.cpp:7186
OtherOptionOrResultEnumeration ** enumeration
Definition: OSOption.h:2612
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12981
OtherObjectiveOption ** getAllOtherObjectiveOptions()
Get all &lt;other&gt; objective options.
Definition: OSOption.cpp:3957
bool IsEqual(MinMemorySize *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:10218
InitObjectiveValues * initialObjectiveValues
initial values for the objectives
Definition: OSOption.h:2689
bool verifyCPUSpeedUnit(std::string unit)
Definition: OSParameters.h:192
bool addProcess(std::string process)
A function to add a &lt;process&gt; element.
Definition: OSOption.cpp:4974
std::string name
optional variable name
Definition: OSOption.h:1167
int value
the minimum number of CPUs required
Definition: OSOption.h:512
std::string * jobID
the list of job IDs
Definition: OSOption.h:717
int idx
variable index
Definition: OSOption.h:1486
MinCPUSpeed()
Default constructor.
Definition: OSOption.cpp:181
bool setVar(int numberOfVar, OtherVarOption **var)
A function to set an array of elements.
Definition: OSOption.cpp:5910
the InitBasStatus class.
Definition: OSOption.h:1481
double getMaxTime()
Get the maximum allowed time.
Definition: OSOption.cpp:1775
bool deepCopyFrom(Processes *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:13709
std::vector< OtherConstraintOption * > getOtherConstraintOptions(std::string solver_name)
Get the array of other constraint options.
Definition: OSOption.cpp:4435
std::string name
optional variable name
Definition: OSOption.h:1935
std::string description
additional description about the storage
Definition: OSGeneral.h:762
bool deepCopyFrom(DirectoriesAndFiles *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:13654
bool IsEqual(DirectoriesAndFiles *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:10418
bool setOtherVariableOptionAttributes(int iOther, int numberOfVar, int numberOfEnumerations, std::string name, std::string value, std::string solver, std::string category, std::string type, std::string varType, std::string enumType, std::string description)
Set the attributes for one particular &lt;other&gt; &lt;variable&gt; option.
Definition: OSOption.cpp:8763
bool addOther(OtherConstraintOption *other)
A function to add an &lt;other&gt; element.
Definition: OSOption.cpp:7346
InitBasStatus ** var
initial value for each variable
Definition: OSOption.h:1548
bool verifyLocationType(std::string type)
Definition: OSParameters.h:324
bool setAnotherInitObjValue(int idx, double value)
Definition: OSOption.cpp:8980
int getOptionInt(std::string optionName)
Get any of the integer-valued options.
Definition: OSOption.cpp:2222
double * m_mdInitObjLowerBoundsDense
m_mdInitObjLowerBoundsDense holds initial lower bounds for the objectives in dense form ...
Definition: OSOption.h:3650
bool setAnOtherGeneralOption(std::string name, std::string value, std::string description)
Add another general option to the &lt;other&gt; option array.
Definition: OSOption.cpp:7716
bool IsEqual(OtherOptions *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:10070
bool deepCopyFrom(BasisStatus *that)
A function to make a deep copy of an instance of this class.
Definition: OSGeneral.cpp:1301
bool deepCopyFrom(InstanceLocationOption *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:13577
bool setAnotherInitVarValue(int idx, double value)
Definition: OSOption.cpp:8453
double ubDualValue
initial upper bound
Definition: OSOption.h:2938
bool IsEqual(IntegerVariableBranchingWeights *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:10992
const OSSmartPtr< OSOutput > osoutput
Definition: OSOutput.cpp:39
std::string solver
name of the solver to which this option applies
Definition: OSOption.h:3173
InitVarValue ** var
initial value for each variable
Definition: OSOption.h:1226
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:13106
std::string getInstanceLocationType()
Get the location type.
Definition: OSOption.cpp:1461
bool setPathPair(int numberOfPathPairs, PathPair **pathPair)
A function to set an array of &lt;pathPair&gt; elements.
Definition: OSOption.cpp:4827
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSGeneral.cpp:1511
std::string description
additional description about the memory
Definition: OSOption.h:422
std::string name
optional variable name
Definition: OSOption.h:2932
std::string value
value of the option
Definition: OSOption.h:2520
int * getVariableInitialBasisStatusDense(int numberOfVariables)
Get the initial basis status for all variables in dense form.
Definition: OSOption.cpp:2968
DirectoriesAndFiles * requiredDirectories
directories required to run the job
Definition: OSOption.h:1078
int getNumberOfSOS()
Get the number of special ordered sets for which branching weights are provided.
Definition: OSOption.cpp:2094
~InstanceLocationOption()
Class destructor.
Definition: OSOption.cpp:41
int getNumberOfOtherConstraintOptions()
Get the number of other constraint options.
Definition: OSOption.cpp:2195
bool IsEqual(PathPairs *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:10475
InitConValue ** getInitConValuesSparse()
Get the initial values associated with the constraints in sparse form.
Definition: OSOption.cpp:3977
int numberOfCon
number of &lt;con&gt; children
Definition: OSOption.h:3161
std::string category
name of the category into which this option falls
Definition: OSOption.h:2009
bool verifyTransportType(std::string type)
Definition: OSParameters.h:348
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12590
InitConstraintValues()
Default constructor.
Definition: OSOption.cpp:1000
bool deepCopyFrom(JobOption *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:13446
std::string value
the value of the &lt;contact&gt; element
Definition: OSOption.h:104
the InitConValue class.
Definition: OSOption.h:2763
bool setInitObjBoundsSparse(int numberOfObj, InitObjBound **obj)
Definition: OSOption.cpp:9006
std::string getInstanceName()
Get the instance name.
Definition: OSOption.cpp:1438
bool IsEqual(VariableOption *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:10632
bool IsEqual(JobOption *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:9822
std::string solver
name of the solver to which this option applies
Definition: OSOption.h:2591
bool setOther(int numberOfOptions, OtherObjectiveOption **other)
A function to set an array of &lt;other&gt; elements.
Definition: OSOption.cpp:6629
~SOSVariableBranchingWeights()
Class destructor.
Definition: OSOption.cpp:654
bool setSolverOptions(int numberOfSolverOptions, SolverOption **solverOption)
Definition: OSOption.cpp:9492
the InitConstraintValues class.
Definition: OSOption.h:2822
std::string solver
the solver to which the option applies
Definition: OSOption.h:3355
ServiceOption * service
serviceOption holds the third child of the OSOption specified by the OSoL Schema. ...
Definition: OSOption.h:3588
bool IsEqual(CPUSpeed *that)
A function to check for the equality of two objects.
Definition: OSGeneral.cpp:1462
int * getSlackVariableInitialBasisStatusDense(int numberOfConstraints)
Get the initial basis status for all slack variables in dense form.
Definition: OSOption.cpp:4329
bool IsEqual(GeneralFileHeader *that)
A function to check for the equality of two objects.
Definition: OSGeneral.cpp:46
bool setInitObjValuesDense(int numberOfObj, double *value)
Definition: OSOption.cpp:8957
std::string serviceName
the name of the service
Definition: OSOption.h:293
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12866
std::string value
value of the option
Definition: OSOption.h:3102
InitObjectiveBounds()
Default constructor.
Definition: OSOption.cpp:850
std::string requestedStartTime
the requested time to start the job
Definition: OSOption.h:1072
bool setOther(int numberOfOptions, OtherVariableOption **other)
A function to set an array of &lt;other&gt; elements.
Definition: OSOption.cpp:5994
IntVector * superbasic
Definition: OSGeneral.h:653
OptimizationOption()
Default constructor.
Definition: OSOption.cpp:1232
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSGeneral.cpp:1415
bool setAnotherJobDependency(std::string jobID)
Definition: OSOption.cpp:8043
bool setAnotherSolverOption(std::string name, std::string value, std::string solver, std::string category, std::string type, std::string description)
Definition: OSOption.cpp:9509
int getNumberOfRequiredFiles()
Get the number of required files.
Definition: OSOption.cpp:1897
double * m_mdInitVarValuesDense
m_mdInitVarValuesDense holds the initial variable values in dense form
Definition: OSOption.h:3625
OtherObjOption()
Default constructor.
Definition: OSOption.cpp:878
std::string name
optional objective name
Definition: OSOption.h:2190
OtherConOption()
Default constructor.
Definition: OSOption.cpp:1075
~MinCPUNumber()
Class destructor.
Definition: OSOption.cpp:207
bool setVar(int numberOfVar, InitVarValue **var)
A function to set an array of elements.
Definition: OSOption.cpp:5013
IntVector * basic
Definition: OSGeneral.h:648
bool setObj(int numberOfObj, InitObjBound **obj)
A function to set an array of &lt;obj&gt; elements.
Definition: OSOption.cpp:6338
int numberOfCon
number of &lt;con&gt; children
Definition: OSOption.h:2827
bool setMinDiskSpace(std::string unit, std::string description, double value)
Set the minimum disk space required for the current job.
Definition: OSOption.cpp:7731
ENUM_COMBINE_ARRAYS
An enum to streamline set() methods of vectors.
Definition: OSParameters.h:820
bool deepCopyFrom(PathPairs *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:13674
std::string type
the service type
Definition: OSOption.h:615
GeneralFileHeader * optionHeader
OSOption has a header and five other children: general, system, service, job, and optimization...
Definition: OSOption.h:3576
BranchingWeight()
Default constructor.
Definition: OSOption.cpp:571
int numberOfEl
Definition: OSGeneral.h:483
bool setOptionDbl(std::string optionName, double value)
Definition: OSOption.cpp:9592
the InitObjectiveBounds class.
Definition: OSOption.h:2405
int numberOfVar
number of children
Definition: OSOption.h:1545
~InitObjectiveValues()
Class destructor.
Definition: OSOption.cpp:812
bool setInitConValues(int numberOfCon, int *idx, double *value, std::string *name)
Definition: OSOption.cpp:9179
bool addVar(int idx, double value)
A function to add a element.
Definition: OSOption.cpp:5136
int getNumberOfInitConValues()
Get the number of initial constraint values.
Definition: OSOption.cpp:2170
std::string errormsg
errormsg is the error that is causing the exception to be thrown
Definition: OSErrorClass.h:42
~SolverOptions()
Class destructor.
Definition: OSOption.cpp:1213
bool verifyStorageUnit(std::string unit)
Definition: OSParameters.h:224
double value
the minimum disk space required
Definition: OSOption.h:380
bool setMinMemorySize(std::string unit, std::string description, double value)
Set the minimum memory size required for the current job.
Definition: OSOption.cpp:7778
bool setAnOtherVariableOption(OtherVariableOption *varOption)
Definition: OSOption.cpp:8904
SOSVariableBranchingWeights * sosVariableBranchingWeights
branching weights for SOS variables and groups
Definition: OSOption.h:2116
std::string getMinMemoryDescription()
get the memory description
Definition: OSOption.cpp:1588
bool setSOSVariableBranchingWeights(int numberOfSOS, SOSWeights **sos)
Definition: OSOption.cpp:8712
JobOption * job
jobOption holds the fourth child of the OSOption specified by the OSoL Schema.
Definition: OSOption.h:3592
std::string description
further information about the file or the problem contained within it
Definition: OSGeneral.h:50
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12411
OtherOption ** other
the list of other options
Definition: OSOption.h:219
bool IsEqual(InitConValue *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:11815
bool setNumberOfConstraints(int numberOfConstraints)
Definition: OSOption.cpp:8376
StorageCapacity * minDiskSpace
the minimum disk space required
Definition: OSOption.h:550
~InitDualVariableValues()
Class destructor.
Definition: OSOption.cpp:1056
bool setInitDualVarValuesDense(int numberOfCon, double *lb, double *ub)
Definition: OSOption.cpp:9302
double * getInitObjUpperBoundsDense()
Get the initial upper bounds associated with the objectives in dense form.
Definition: OSOption.cpp:3641
bool setUserName(std::string userName)
Set the username.
Definition: OSOption.cpp:7637
double * m_mdIntegerVariableBranchingWeightsDense
m_mdIntegerVariableBranchingWeightsDense holds the branching weights for integer variables ...
Definition: OSOption.h:3640
the PathPairs class.
Definition: OSOption.h:910
the InitVarValue class.
Definition: OSOption.h:1159
int sosIdx
index of the SOS (to match the OSiL file)
Definition: OSOption.h:1780
ConstraintOption()
Default constructor.
Definition: OSOption.cpp:1142
std::vector< SolverOption * > getSolverOptions(std::string solver_name)
Get the options associated with a given solver.
Definition: OSOption.cpp:4508
bool deepCopyFrom(InitObjValue *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:14048
bool setInitVarValuesDense(int numberOfVar, double *value)
Definition: OSOption.cpp:8429
std::string * getInitVarValuesStringDense()
Get the initial value strings associated with the variables in dense form.
Definition: OSOption.cpp:2874
~InitVarValue()
Class destructor.
Definition: OSOption.cpp:446
int numberOfOtherObjectiveOptions
number of &lt;other&gt; child elements
Definition: OSOption.h:2686
JobOption()
Default constructor.
Definition: OSOption.cpp:378
bool setInitVarValuesString(int numberOfVar, int *idx, std::string *value, std::string *name)
Definition: OSOption.cpp:8464
bool setSolverOptionContent(int iOption, int numberOfItems, std::string name, std::string value, std::string solver, std::string category, std::string type, std::string description, std::string *itemList)
Set the attributes for one particular solver option.
Definition: OSOption.cpp:9462
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12505
std::string * path
the list of directory and file paths
Definition: OSOption.h:788
bool IsEqual(InitObjBound *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:11540
std::string getMinMemoryUnit()
Get the memory unit.
Definition: OSOption.cpp:1576
std::string description
additional description about the CPU
Definition: OSOption.h:509
std::string fileCreator
name(s) of author(s) who created this file
Definition: OSGeneral.h:55
std::string getSolverToInvoke()
Get the solver name.
Definition: OSOption.cpp:1484
~MinMemorySize()
Class destructor.
Definition: OSOption.cpp:173
bool deepCopyFrom(InitObjectiveValues *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:14027
bool deepCopyFrom(CPUNumber *that)
A function to make a deep copy of an instance of this class.
Definition: OSGeneral.cpp:1611
bool setVar(int numberOfVar, InitBasStatus **var)
A function to set an array of elements.
Definition: OSOption.cpp:5430
std::string getFileLicence()
Get licence information associated with the file.
Definition: OSOption.cpp:1404
bool IsEqual(BasisStatus *that)
A function to check for the equality of two objects.
Definition: OSGeneral.cpp:1213
~ContactOption()
Class destructor.
Definition: OSOption.cpp:58
bool setInitVarValuesStringSparse(int numberOfVar, InitVarValueString **var)
Definition: OSOption.cpp:8478
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:13235
double value
the number of units
Definition: OSGeneral.h:932
std::string description
additional description about the disk space
Definition: OSOption.h:377
the DirectoriesAndFiles class.
Definition: OSOption.h:780
SystemOption * system
systemOption holds the second child of the OSOption specified by the OSoL Schema. ...
Definition: OSOption.h:3584
bool IsEqual(OptimizationOption *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:9898
bool IsEqual(InitialBasisStatus *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:10894
double * m_mdInitConValuesDense
m_mdInitConValuesDense holds initial constraint values in dense form
Definition: OSOption.h:3660
~OSOption()
Class destructor.
Definition: OSOption.cpp:1287
bool setAnotherInputFileToMove(std::string fromPath, std::string toPath, bool makeCopy)
Definition: OSOption.cpp:8212
SolverOption()
Default constructor.
Definition: OSOption.cpp:1179
int value
the number of CPUs
Definition: OSGeneral.h:879
int numberOfEnumerations
number of &lt;enumeration&gt; child elements
Definition: OSOption.h:3164
PathPair ** getInputDirectoriesToMove()
Get the array of input directories to move.
Definition: OSOption.cpp:2590
std::string userName
the username
Definition: OSOption.h:311
int numberOfVariables
the number of variables
Definition: OSOption.h:3500
std::string category
the category to which the option belongs
Definition: OSOption.h:3358
~OtherConstraintOption()
Class destructor.
Definition: OSOption.cpp:1114
OtherVariableOption ** other
other variable options
Definition: OSOption.h:2119
bool setAnOtherJobOption(std::string name, std::string value, std::string description)
Definition: OSOption.cpp:8349
int idx
variable index
Definition: OSOption.h:1932
std::string type
type of the option value (integer, double, boolean, string)
Definition: OSOption.h:2012
double * m_mdInitObjUpperBoundsDense
m_mdInitObjUpperBoundsDense holds initial upper bounds for the objectives in dense form ...
Definition: OSOption.h:3655
double * m_mdInitObjValuesDense
m_mdInitObjValuesDense holds initial objective values in dense form
Definition: OSOption.h:3645
bool getIntVector(int status, int *i)
Get the entire array of indices for a particular status.
Definition: OSGeneral.cpp:950
int getNumberOfJobDependencies()
Get the number of job dependencies.
Definition: OSOption.cpp:1873
OtherOptions * otherOptions
the list of other general options
Definition: OSOption.h:320
IntVector * isFree
Definition: OSGeneral.h:652
std::string solver
name of the solver to which this option applies
Definition: OSOption.h:2006
InitDualVariableValues * initialDualValues
initial dual values for the constraints
Definition: OSOption.h:3274
PathPair()
Default constructor.
Definition: OSOption.cpp:309
bool deepCopyFrom(IntegerVariableBranchingWeights *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:13849
bool setRequiredDirectories(int numberOfPaths, std::string *paths)
Definition: OSOption.cpp:8053
std::string * m_mdInitVarValuesStringDense
m_mdInitVarValuesStringDense holds the initial values for string-valued variables ...
Definition: OSOption.h:3630
the MinCPUSpeed class.
Definition: OSOption.h:459
~OtherObjectiveOption()
Class destructor.
Definition: OSOption.cpp:917
std::string name
name of the option
Definition: OSOption.h:3167
std::string name
used to give a name to the file or the problem contained within it
Definition: OSGeneral.h:39
IntVector * atLower
Definition: OSGeneral.h:649
bool deepCopyFrom(OtherObjOption *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:14141
bool deepCopyFrom(JobDependencies *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:13634
bool setOther(int numberOfOptions, OtherConstraintOption **other)
A function to set an array of &lt;other&gt; elements.
Definition: OSOption.cpp:7271
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:13001
DirectoriesAndFiles * directoriesToDelete
directories to delete upon completion
Definition: OSOption.h:1105
ConstraintOption * constraints
the options for the constraints
Definition: OSOption.h:3515
std::string description
additional description about the CPU speed
Definition: OSGeneral.h:820
bool setMinDiskSpaceUnit(std::string unit)
Definition: OSOption.cpp:7756
int getNumberOfRequiredDirectories()
Get the number of required directories.
Definition: OSOption.cpp:1885
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12444
bool setSolverToInvoke(std::string solverToInvoke)
Set the solver to be invoked.
Definition: OSOption.cpp:7621
~MinDiskSpace()
Class destructor.
Definition: OSOption.cpp:155
bool setOutputFilesToMove(int numberOfPathPairs, PathPair **pathPair)
Definition: OSOption.cpp:8222
std::string category
name of the category into which this option falls
Definition: OSOption.h:2594
std::string name
name of the option
Definition: OSOption.h:2000
std::string * getRequiredFiles()
Get the array of required files.
Definition: OSOption.cpp:2536
StorageCapacity * minMemorySize
the minimum memory required
Definition: OSOption.h:553
std::string getContactTransportType()
Get the transport type.
Definition: OSOption.cpp:1540
std::string value
initial value
Definition: OSOption.h:1489
bool setOtherOptionOrResultEnumeration(int object, int otherOptionNumber, int enumerationNumber, int numberOfEl, std::string value, std::string description, int *idxArray)
Set one enumeration associated with an &lt;other&gt; option in the &lt;variables&gt;, &lt;objectives&gt; or &lt;constraint...
Definition: OSOption.cpp:8804
InitDualVarValue()
Default constructor.
Definition: OSOption.cpp:1028
bool deepCopyFrom(OtherVarOption *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:13974
std::string lbValue
lower bound of the option
Definition: OSOption.h:3105
OtherOptionOrResultEnumeration ** enumeration
Definition: OSOption.h:3194
std::string category
name of the category into which this option falls
Definition: OSOption.h:3176
std::string getServiceURI()
Get the service URI.
Definition: OSOption.cpp:1416
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12331
~InitVariableValues()
Class destructor.
Definition: OSOption.cpp:463
std::string getServiceType()
Get the service type.
Definition: OSOption.cpp:1636
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:13249
InitObjBound()
Default constructor.
Definition: OSOption.cpp:831
int getNumberOfObjectives()
Get the number of objectives in the instance.
Definition: OSOption.cpp:2028
ServiceOption()
Default constructor.
Definition: OSOption.cpp:245
double OSRand()
OSRand()
Definition: OSMathUtil.cpp:262
int numberOfVar
number of children
Definition: OSOption.h:1786
std::string getFileDescription()
Get a description for the file or problem.
Definition: OSOption.cpp:1382
bool setAnOtherServiceOption(std::string name, std::string value, std::string description)
Definition: OSOption.cpp:7962
bool verifyServiceType(std::string type)
Definition: OSParameters.h:376
int getNumberOfDirectoriesToMake()
Get the number of directories to make.
Definition: OSOption.cpp:1909
std::string getMinDiskSpaceDescription()
get the disk space description
Definition: OSOption.cpp:1564
std::string unit
the unit in which CPU speed is measured
Definition: OSOption.h:464
bool getInitialBasisElements(int type, int status, int *elem)
Get the initial basis elements for a particular variable type and basis status.
Definition: OSOption.cpp:3115
bool makeCopy
record whether a copy is to be made
Definition: OSOption.h:862
std::string instanceName
the name of the instance
Definition: OSOption.h:296
bool IsEqual(SolverOption *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:12131
PathPairs * outputFilesToMove
output files to move or copy
Definition: OSOption.h:1096
the SOSVariableBranchingWeights class.
Definition: OSOption.h:1853
bool setInputDirectoriesToMove(int numberOfPathPairs, PathPair **pathPair)
Definition: OSOption.cpp:8178
double groupWeight
branching weight for the entire SOS
Definition: OSOption.h:1783
Processes()
Default constructor.
Definition: OSOption.cpp:356
int numberOfCon
number of &lt;con&gt; children
Definition: OSOption.h:2992
bool addSOS(int sosIdx, int nvar, double weight, int *idx, double *value, std::string *name)
A function to add an &lt;sos&gt; element.
Definition: OSOption.cpp:5855
bool setAnOtherObjectiveOption(OtherObjectiveOption *objOption)
Definition: OSOption.cpp:9169
bool IsEqual(PathPair *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:10525
std::string name
optional variable name
Definition: OSOption.h:1619
OtherVariableOption ** getAllOtherVariableOptions()
Get all &lt;other&gt; variable options.
Definition: OSOption.cpp:3341
std::string * getRequiredDirectories()
Get the array of required directories.
Definition: OSOption.cpp:2518
std::string getMinCPUNumberDescription()
Get the CPU description.
Definition: OSOption.cpp:1624
bool setNumberOfVariables(int numberOfVariables)
Definition: OSOption.cpp:8360
std::string conType
type of the values in the con array
Definition: OSOption.h:3188
the InitVariableValues class.
Definition: OSOption.h:1218
a data structure that holds general information about files that conform to one of the OSxL schemas ...
Definition: OSGeneral.h:32
the OtherObjOption class.
Definition: OSOption.h:2509
int getNumberOfConstraints()
Get the number of constraints in the instance.
Definition: OSOption.cpp:2039
bool setRequestedStartTime(std::string time)
Definition: OSOption.cpp:8022
InitDualVarValue ** getInitDualVarValuesSparse()
Get the initial bounds associated with the dual variables in sparse form.
Definition: OSOption.cpp:4100
static char * j
Definition: OSdtoa.cpp:3622
bool setOtherConstraintOptionCon(int otherOptionNumber, int conNumber, int idx, std::string name, std::string value, std::string lbValue, std::string ubValue)
Set one &lt;con&gt; element associated with an &lt;other&gt; option in the &lt;constraints&gt; element.
Definition: OSOption.cpp:9396
bool IsEqual(ObjectiveOption *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:11339
The Option Class.
Definition: OSOption.h:3564
std::string name
optional variable name
Definition: OSOption.h:1328
bool setFilesToMake(int numberOfPaths, std::string *paths)
Definition: OSOption.cpp:8119
int getNumberOfOutputDirectoriesToMove()
Get the number of output directories to move.
Definition: OSOption.cpp:1957
int numberOfPathPairs
the number of &lt;path&gt; children
Definition: OSOption.h:915
std::string name
name of the option
Definition: OSOption.h:2585
bool deepCopyFrom(SolverOptions *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:14321
bool IsEqual(InitObjectiveBounds *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:11491
std::string password
the password
Definition: OSOption.h:314
double * getInitDualVarLowerBoundsDense()
Get the initial dual variables associated with the lower bounds in dense form.
Definition: OSOption.cpp:4125
bool setAnotherDirectoryToDelete(std::string path)
Definition: OSOption.cpp:8300
bool setAnotherIntegerVariableBranchingWeight(int idx, double value)
Definition: OSOption.cpp:8700
std::string jobID
the job ID
Definition: OSOption.h:302
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12776
std::string to
the file or directory to move/copy to
Definition: OSOption.h:859
double lbValue
initial lower bound
Definition: OSOption.h:2354
std::string locationType
the type of the location
Definition: OSOption.h:44
bool verifyTimeUnit(std::string unit)
Definition: OSParameters.h:256
int numberOfObj
number of &lt;obj&gt; children
Definition: OSOption.h:2410
IntegerVariableBranchingWeights()
Default constructor.
Definition: OSOption.cpp:589
bool setHeader(std::string name, std::string source, std::string description, std::string fileCreator, std::string licence)
A function to populate an instance of this class.
Definition: OSGeneral.cpp:133
SolverOptions()
Default constructor.
Definition: OSOption.cpp:1204
int numberOfSolverOptions
the number of solver options
Definition: OSOption.h:3423
bool deepCopyFrom(SOSVariableBranchingWeights *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:13870
std::string name
optional variable name
Definition: OSOption.h:3099
bool deepCopyFrom(InitObjBound *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:14080
int idx
variable index
Definition: OSOption.h:1164
bool deepCopyFrom(BranchingWeight *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:13917
OtherOption ** getAllOtherOptions()
Get the array of all other options associated with the &lt;general&gt;, &lt;system&gt;, &lt;service&gt; and &lt;job&gt; eleme...
Definition: OSOption.cpp:2406
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSGeneral.cpp:100
std::string * getProcessesToKill()
Get the array of processes to kill.
Definition: OSOption.cpp:2698
std::string varType
type of the values in the var array
Definition: OSOption.h:2021
~InitVarValueString()
Class destructor.
Definition: OSOption.cpp:492
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12959
bool deepCopyFrom(GeneralFileHeader *that)
A function to make a deep copy of an instance of this class.
Definition: OSGeneral.cpp:110
bool IsEqual(CPUNumber *that)
A function to check for the equality of two objects.
Definition: OSGeneral.cpp:1556
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:13127
the OtherVarOption class.
Definition: OSOption.h:1927
double OSNaN()
returns the value for NaN used in OS
bool setIntVector(int status, int *i, int ni)
Set the indices for a particular status.
Definition: OSGeneral.cpp:854
DirectoriesAndFiles * filesToDelete
files to delete upon completion
Definition: OSOption.h:1102
GeneralOption()
Default constructor.
Definition: OSOption.cpp:113
bool setVar(int numberOfVar, BranchingWeight **var)
A function to set an array of elements.
Definition: OSOption.cpp:5723
bool IsEqual(ServiceOption *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:9773
bool deepCopyFrom(OtherVariableOption *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:13928
bool setHeader(std::string name, std::string source, std::string description, std::string fileCreator, std::string licence)
A function to populate an instance of the option header element.
Definition: OSOption.cpp:7528
std::string getContact()
Get the contact information.
Definition: OSOption.cpp:1528
int getNumberOfOtherObjectiveOptions()
Get the number of other objective options.
Definition: OSOption.cpp:2159
int numberOfEnumerations
number of &lt;enumeration&gt; child elements
Definition: OSOption.h:1997
int numberOfObjectives
the number of objectives
Definition: OSOption.h:3503
bool addOther(OtherObjectiveOption *other)
A function to add an &lt;other&gt; element.
Definition: OSOption.cpp:6699
OtherVariableOption()
Default constructor.
Definition: OSOption.cpp:692
~DirectoriesAndFiles()
Class destructor.
Definition: OSOption.cpp:296
int numberOfVar
number of child elements
Definition: OSOption.h:1994
InstanceLocationOption * instanceLocation
the location of the instance
Definition: OSOption.h:299
std::string from
the file or directory to move/copy from
Definition: OSOption.h:856
double * m_mdInitDualVarLowerBoundsDense
m_mdInitDualVarLowerBoundsDense holds initial dual values for the lower bound of the constraints in d...
Definition: OSOption.h:3666
bool IsEqual(InitBasStatus *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:10943
std::string serviceURI
the service URI
Definition: OSOption.h:290
VariableOption()
Default constructor.
Definition: OSOption.cpp:740
double value
the minimum memory size required
Definition: OSOption.h:425
~PathPair()
Class destructor.
Definition: OSOption.cpp:319
std::string * getDirectoriesToMake()
Get the array of directories to make.
Definition: OSOption.cpp:2554
bool setMaxTime(double value, std::string unit)
Definition: OSOption.cpp:7985
bool IsEqual(OtherOption *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:10120
bool IsEqual(OtherVarOption *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:11290
OtherObjectiveOption()
Default constructor.
Definition: OSOption.cpp:898
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12199
bool setMinMemoryUnit(std::string unit)
Definition: OSOption.cpp:7803
InstanceLocationOption()
Default constructor.
Definition: OSOption.cpp:32
PathPair ** getOutputFilesToMove()
Get the array of output files to move.
Definition: OSOption.cpp:2626
~OtherVariableOption()
Class destructor.
Definition: OSOption.cpp:712
std::string getMinCPUSpeedUnit()
Get the CPU speed unit.
Definition: OSOption.cpp:1600
bool setServiceName(std::string serviceName)
Set the service name.
Definition: OSOption.cpp:7548
int getNumberOfInitDualVarValues()
Get the number of initial dual variable values.
Definition: OSOption.cpp:2182
bool setLicense(std::string license)
Set the license information.
Definition: OSOption.cpp:7629
std::string description
additional description about the CPU speed
Definition: OSOption.h:467
OSOption()
Default constructor.
Definition: OSOption.cpp:1262
std::string * getJobDependencies()
Get the array of job dependencies.
Definition: OSOption.cpp:2499
std::string description
additional description about the CPU
Definition: OSGeneral.h:876
std::string name
optional variable name
Definition: OSOption.h:2771
BasisStatus * initialBasisStatus
initial basis information
Definition: OSOption.h:2110
bool IsEqual(SolverOptions *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:12080
bool addObj(int idx, double lbValue, double ubValue)
A function to add a &lt;obj&gt; element.
Definition: OSOption.cpp:6454
bool IsEqual(Processes *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:10574
double getOptionDbl(std::string optionName)
Get any of the double-valued options.
Definition: OSOption.cpp:1790
bool addVar(int idx, double value)
A function to add a element.
Definition: OSOption.cpp:5637
the OptimizationOption class.
Definition: OSOption.h:3495
~Processes()
Class destructor.
Definition: OSOption.cpp:365
~ObjectiveOption()
Class destructor.
Definition: OSOption.cpp:957
~InitObjBound()
Class destructor.
Definition: OSOption.cpp:842
std::string * getFilesToMake()
Get the array of files to make.
Definition: OSOption.cpp:2572
bool deepCopyFrom(InitConValue *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:14215
bool IsEqual(MinCPUNumber *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:10314
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:13051
InitialBasisStatus()
Default constructor.
Definition: OSOption.cpp:544
bool IsEqual(InitVariableValuesString *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:10799
BranchingWeight ** var
branching weights for individual variables
Definition: OSOption.h:1789
bool deepCopyFrom(InitVariableValuesString *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:13816
bool deepCopyFrom(OtherOption *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:13622
DirectoriesAndFiles()
Default constructor.
Definition: OSOption.cpp:287
bool setOtherObjectiveOptions(int numberOfObj, OtherObjectiveOption **obj)
Definition: OSOption.cpp:9152
int numberOfOtherVariableOptions
number of &lt;other&gt; child elements
Definition: OSOption.h:2101
the VariableOption class.
Definition: OSOption.h:2096
bool setDirectoriesToDelete(int numberOfPaths, std::string *paths)
Definition: OSOption.cpp:8288
std::string getOptionStr(std::string optionName)
Get any of the string-valued options.
Definition: OSOption.cpp:1673
double * getInitVarValuesDense()
Get the initial values associated with the variables in dense form.
Definition: OSOption.cpp:2744
bool IsEqual(InitObjectiveValues *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:11396
std::string enumType
type of the values in the enumeration array
Definition: OSOption.h:3197
double * getInitConValuesDense()
Get the initial values associated with the constraints in dense form.
Definition: OSOption.cpp:4002
bool addOther(OtherVariableOption *other)
A function to add an &lt;other&gt; element.
Definition: OSOption.cpp:6064
bool setOtherGeneralOptions(int numberOfOptions, OtherOption **other)
Set the other general options as an entire array.
Definition: OSOption.cpp:7699
bool IsEqual(SOSWeights *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:11093
std::string description
the description of the option
Definition: OSOption.h:163
int numberOfVar
number of children
Definition: OSOption.h:1384
bool setProcess(int numberOfProcesses, std::string *process)
A function to set an array of &lt;process&gt; elements.
Definition: OSOption.cpp:4939
~VariableOption()
Class destructor.
Definition: OSOption.cpp:754
bool setAnotherInitDualVarValue(int idx, double lbValue, double ubValue)
Definition: OSOption.cpp:9325
InitObjValue ** obj
initial value for each objective
Definition: OSOption.h:2249
int getNumberOfOtherGeneralOptions()
Get the number of &lt;other&gt; options in the &lt;general&gt; element.
Definition: OSOption.cpp:1825
bool setAnotherInitConValue(int idx, double value)
Definition: OSOption.cpp:9247
double getMinDiskSpace()
Get the minimum required disk space.
Definition: OSOption.cpp:1739
CPUNumber * minCPUNumber
the minimum number of processors required
Definition: OSOption.h:559
bool IsEqual(OtherObjectiveOption *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:11590
bool setInitObjBounds(int numberOfObj, int *idx, double *lbValue, double *ubValue, std::string *name)
Definition: OSOption.cpp:8991
int idx
objective index
Definition: OSOption.h:2348
OtherOption ** getOtherServiceOptions()
Get the array of other options associated with the &lt;service&gt; element.
Definition: OSOption.cpp:2357
bool setAnotherRequiredFile(std::string path)
Definition: OSOption.cpp:8087
the MinCPUNumber class.
Definition: OSOption.h:504
bool setJobDependencies(int numberOfDependencies, std::string *jobDependencies)
Definition: OSOption.cpp:8031
int idx
objective index
Definition: OSOption.h:2187
bool setAnotherOutputDirectoryToMove(std::string fromPath, std::string toPath, bool makeCopy)
Definition: OSOption.cpp:8256
int numberOfPaths
the number of &lt;path&gt; children
Definition: OSOption.h:785
bool deepCopyFrom(InitDualVarValue *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:14247
the MinMemorySize class.
Definition: OSOption.h:414
std::string name
the name of the option
Definition: OSOption.h:3349
double value
branching weight
Definition: OSOption.h:1622
bool addSolverOption(std::string name, std::string value, std::string solver, std::string category, std::string type, std::string description)
A function to add a solver option.
Definition: OSOption.cpp:7480
the CPUSpeed class.
Definition: OSGeneral.h:812
int getNumberOfVariables()
Get the number of variables in the instance.
Definition: OSOption.cpp:2017
InitObjValue()
Default constructor.
Definition: OSOption.cpp:785
the OtherObjectiveOption class.
Definition: OSOption.h:2574
bool setServiceURI(std::string serviceURI)
Set the serviceURI.
Definition: OSOption.cpp:7540
bool deepCopyFrom(SOSWeights *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:13892
MinMemorySize()
Default constructor.
Definition: OSOption.cpp:163
SolverOption ** getAllSolverOptions()
Get all solver options.
Definition: OSOption.cpp:4567
int numberOfConstraints
the number of constraints
Definition: OSOption.h:3506
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:13065
OtherOption ** getOtherOptions(std::string elementName)
Get the array of other options associated with any element.
Definition: OSOption.cpp:2386
double value
initial value
Definition: OSOption.h:1170
~OtherObjOption()
Class destructor.
Definition: OSOption.cpp:890
std::string value
initial value
Definition: OSOption.h:1331
std::string description
description of the option
Definition: OSOption.h:2015
DirectoriesAndFiles * directoriesToMake
directories to make during the job
Definition: OSOption.h:1084
ObjectiveOption()
Default constructor.
Definition: OSOption.cpp:945
bool IsEqual(InitDualVarValue *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:11910
the InitObjBound class.
Definition: OSOption.h:2343
int idx
index of the variable
Definition: OSOption.h:1616
bool addPathPair(std::string fromPath, std::string toPath, bool makeCopy)
A function to add a &lt;pathPair&gt; element.
Definition: OSOption.cpp:4890
bool setInitObjValuesSparse(int numberOfObj, InitObjValue **obj)
Definition: OSOption.cpp:8927
double * getInitObjValuesDense()
Get the initial values associated with the objectives in dense form.
Definition: OSOption.cpp:3411
bool setAnotherInitBasisStatus(int type, int idx, int status)
Set the basis status for another variable, objective or constraint/slack.
Definition: OSOption.cpp:8595
PathPairs * inputDirectoriesToMove
input directories to move or copy
Definition: OSOption.h:1090
the ConstraintOption class.
Definition: OSOption.h:3263
bool IsEqual(OtherConOption *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:12029
bool setInitObjBoundsDense(int numberOfObj, double *lb, double *ub)
Definition: OSOption.cpp:9036
bool IsEqual(InitDualVariableValues *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:11861
bool deepCopyFrom(ConstraintOption *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:14154
bool setCon(int numberOfCon, InitConValue **con)
A function to set an array of &lt;con&gt; elements.
Definition: OSOption.cpp:6781
SystemOption()
Default constructor.
Definition: OSOption.cpp:215
~MinCPUSpeed()
Class destructor.
Definition: OSOption.cpp:191
the SOSWeights class.
Definition: OSOption.h:1775
std::string value
the value of the option
Definition: OSOption.h:3352
int numberOfVar
number of children
Definition: OSOption.h:1223
~JobOption()
Class destructor.
Definition: OSOption.cpp:400
void fint fint * k
bool setInstanceLocationType(std::string locationType)
Set the instance location type.
Definition: OSOption.cpp:7591
bool deepCopyFrom(InitObjectiveBounds *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:14059
int * getObjectiveInitialBasisStatusDense(int numberOfObjectives)
Get the initial basis status for all objectives in dense form.
Definition: OSOption.cpp:3796
the InitialBasisStatus class.
Definition: OSOption.h:1540
double * getInitDualVarUpperBoundsDense()
Get the initial dual variables associated with the upper bounds in dense form.
Definition: OSOption.cpp:4226
const double OSDBL_MAX
Definition: OSParameters.h:93
the SolverOptions class.
Definition: OSOption.h:3418
bool deepCopyFrom(InitVariableValues *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:13782
bool setPath(int numberOfPaths, std::string *path)
A function to set an array of &lt;path&gt; elements.
Definition: OSOption.cpp:4752
OtherOptions * otherOptions
the list of other service options
Definition: OSOption.h:618
int getNumberOfEl(int status)
Get the number of indices for a particular status.
Definition: OSGeneral.cpp:995
the ServiceOption class.
Definition: OSOption.h:610
std::string getServiceName()
Get the service name.
Definition: OSOption.cpp:1427
the JobDependencies class.
Definition: OSOption.h:709
bool addOther(std::string name, std::string value, std::string description)
A function to add an &lt;other&gt; element.
Definition: OSOption.cpp:4633
InitVariableValuesString()
Default constructor.
Definition: OSOption.cpp:500
~OtherOption()
Class destructor.
Definition: OSOption.cpp:76
double value
initial value
Definition: OSOption.h:2193
PathPair ** getInputFilesToMove()
Get the array of input files to move.
Definition: OSOption.cpp:2608
bool setSOS(int numberOfSOS, SOSWeights **sos)
A function to set an array of &lt;sos&gt; elements.
Definition: OSOption.cpp:5804
PathPair ** getOutputDirectoriesToMove()
Get the array of output directories to move.
Definition: OSOption.cpp:2644
bool setInputFilesToMove(int numberOfPathPairs, PathPair **pathPair)
Definition: OSOption.cpp:8200
std::string unit
the unit in which storage capacity is measured
Definition: OSGeneral.h:759
bool setNumberOfOtherConstraintOptions(int numberOfOther)
Definition: OSOption.cpp:9336
bool setSolverOptions(int numberOfOptions, SolverOption **solverOption)
A function to set an array of solver options.
Definition: OSOption.cpp:7424
bool setNumberOfObjectives(int numberOfObjectives)
Definition: OSOption.cpp:8368
std::string enumType
type of the values in the enumeration array
Definition: OSOption.h:2615
bool deepCopyFrom(CPUSpeed *that)
A function to make a deep copy of an instance of this class.
Definition: OSGeneral.cpp:1532
OtherOption ** getOtherSystemOptions()
Get the array of other options associated with the &lt;system&gt; element.
Definition: OSOption.cpp:2344
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:13145
int numberOfProcesses
the number of &lt;process&gt; children
Definition: OSOption.h:998
int getNumberOfInitObjBounds()
Get the number of initial objective bounds.
Definition: OSOption.cpp:2147
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12879
bool setAnotherInitVarValueString(int idx, std::string value)
Definition: OSOption.cpp:8533
double lbDualValue
initial lower bound
Definition: OSOption.h:2935
SolverOptions * solverOptions
other solver options
Definition: OSOption.h:3518
int getNumberOfSOSVarBranchingWeights(int iSOS)
Get the number of variables for which branching weights are provided in a particular SOS...
Definition: OSOption.cpp:2106
bool addPath(std::string path)
A function to add a &lt;path&gt; element.
Definition: OSOption.cpp:4787
the JobOption class.
Definition: OSOption.h:1064
bool setJobID(int numberOfJobIDs, std::string *jobID)
A function to set an array of &lt;jobID&gt; elements.
Definition: OSOption.cpp:4677
bool setOtherVariableOptions(int numberOfVar, OtherVariableOption **var)
Definition: OSOption.cpp:8887
bool addIdx(int status, int idx)
Add one index to a particular status.
Definition: OSGeneral.cpp:905
std::string value
value of the option
Definition: OSOption.h:1938
static int
Definition: OSdtoa.cpp:2173
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:13185
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSGeneral.cpp:1604
bool setInitDualValues(int numberOfCon, int *idx, double *lbValue, double *ubValue, std::string *name)
Definition: OSOption.cpp:9258
~OtherOptions()
Class destructor.
Definition: OSOption.cpp:93
OtherOption ** getOtherJobOptions()
Get the array of other options associated with the &lt;job&gt; element.
Definition: OSOption.cpp:2370
bool setNumberOfOtherVariableOptions(int numberOfOther)
Definition: OSOption.cpp:8742
the ObjectiveOption class.
Definition: OSOption.h:2681
std::string * item
the list of items of the option
Definition: OSOption.h:3370
bool deepCopyFrom(PathPair *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:13698
OtherOptionOrResultEnumeration ** enumeration
Definition: OSOption.h:2027
double * getIntegerVariableBranchingWeightsDense()
Get the integer branching weights in dense form.
Definition: OSOption.cpp:3190
OtherObjectiveOption * getOtherObjectiveOption(int optionNumber)
Get one particular &lt;other&gt; objective option from the array of options.
Definition: OSOption.cpp:3934
InitVarValueString ** var
initial value for each variable
Definition: OSOption.h:1387
the InitVariableValuesString class.
Definition: OSOption.h:1379
the CPUNumber class.
Definition: OSGeneral.h:871
~SystemOption()
Class destructor.
Definition: OSOption.cpp:227
bool IsEqual(MinDiskSpace *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:10169
bool IsEqual(SystemOption *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:9729
std::string getMaxTimeUnit()
Get the time unit.
Definition: OSOption.cpp:1647
InitConValue ** con
initial value for each constraint
Definition: OSOption.h:2830
bool setAnOtherSystemOption(std::string name, std::string value, std::string description)
Definition: OSOption.cpp:7911
bool setNumberOfSolverOptions(int numberOfOptions)
Definition: OSOption.cpp:9448
BranchingWeight ** getIntegerVariableBranchingWeightsSparse()
Get the integer branching weights in sparse form.
Definition: OSOption.cpp:3164
int getNumberOfInputFilesToMove()
Get the number of input files to move.
Definition: OSOption.cpp:1945
bool deepCopyFrom(GeneralOption *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:13353
bool deepCopyFrom(OSOption *that)
A function to make a deep copy of an OSOption object.
Definition: OSOption.cpp:13308
DirectoriesAndFiles * filesToMake
files to make during the job
Definition: OSOption.h:1087
int idx
variable index
Definition: OSOption.h:1325
bool setAnotherFileToMake(std::string path)
Definition: OSOption.cpp:8131
bool setIntegerVariableBranchingWeightsSparse(int numberOfVar, BranchingWeight **var)
Definition: OSOption.cpp:8647
std::string lbValue
lower bound on the value
Definition: OSOption.h:2524
~SOSWeights()
Class destructor.
Definition: OSOption.cpp:627
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:13166
bool IsEqual(OSOption *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:9614
the MinDiskSpace class.
Definition: OSOption.h:369
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:13270
OtherOption()
Default constructor.
Definition: OSOption.cpp:66
OtherOptions * otherOptions
the list of other system options
Definition: OSOption.h:562
PathPairs * outputDirectoriesToMove
output directories to move or copy
Definition: OSOption.h:1099
int numberOfObj
number of &lt;obj&gt; children
Definition: OSOption.h:2246
CPUSpeed * minCPUSpeed
the minimum CPU speed required
Definition: OSOption.h:556
std::string getFileCreator()
Get the name of the person who created the file.
Definition: OSOption.cpp:1393
~InitialBasisStatus()
Class destructor.
Definition: OSOption.cpp:553
bool setPathPairs(int object, std::string *from, std::string *to, bool *makeCopy, int numberOfPathPairs)
setPathPairs set a number of path pairs into the OSOption object
Definition: OSOption.cpp:8140
BasisStatus * initialBasisStatus
initial basis status for the objectives
Definition: OSOption.h:2695
std::string description
description of the option
Definition: OSOption.h:3182
std::string getUserName()
Get the user name.
Definition: OSOption.cpp:1506
VariableOption * variables
the options for the variables
Definition: OSOption.h:3509
bool deepCopyFrom(VariableOption *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:13730
OtherVarOption ** var
array of option values
Definition: OSOption.h:2018
OtherVarOption()
Default constructor.
Definition: OSOption.cpp:672
Processes * processesToKill
processes to kill upon completion
Definition: OSOption.h:1108
OtherOptions()
Default constructor.
Definition: OSOption.cpp:84
std::string value
value of the option
Definition: OSOption.h:2588
std::string name
the name of the option
Definition: OSOption.h:157
InitVariableValuesString * initialVariableValuesString
initial values for string-valued variables
Definition: OSOption.h:2107
~OtherVarOption()
Class destructor.
Definition: OSOption.cpp:684
SOSWeights ** getSOSVariableBranchingWeightsSparse()
Get the SOS branching weights in sparse form.
Definition: OSOption.cpp:3289
bool addObj(int idx, double value)
A function to add a &lt;obj&gt; element.
Definition: OSOption.cpp:6252
std::string license
the license information
Definition: OSOption.h:308
bool setServiceType(std::string serviceType)
set() options in the &lt;service&gt; element
Definition: OSOption.cpp:7925
bool deepCopyFrom(OtherOptions *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:13597
the PathPair class.
Definition: OSOption.h:851
bool addVar(int idx, std::string value)
A function to add a element.
Definition: OSOption.cpp:5467
OtherOption ** getOtherGeneralOptions()
Get the array of other options associated with the &lt;general&gt; element.
Definition: OSOption.cpp:2331
InitVarValueString()
Default constructor.
Definition: OSOption.cpp:482
double value
the CPU speed (expressed in multiples of unit)
Definition: OSGeneral.h:823
bool setIntegerVariableBranchingWeightsDense(int numberOfVar, double *value)
Definition: OSOption.cpp:8677
std::string source
used when the file or problem appeared in the literature (could be in BiBTeX format or similar) ...
Definition: OSGeneral.h:45
ContactOption * contact
the contact method
Definition: OSOption.h:317
bool deepCopyFrom(TimeSpan *that)
A function to make a deep copy of an instance of this class.
Definition: OSGeneral.cpp:1704
OtherConOption ** con
array of option values
Definition: OSOption.h:3185
bool setAnotherProcessToKill(std::string process)
Definition: OSOption.cpp:8322
PathPair ** pathPair
the list of directory and file paths
Definition: OSOption.h:918
int getNumberOfInitVarValuesString()
Get the number of initial variable strings.
Definition: OSOption.cpp:2069
TimeSpan * maxTime
the maximum time allowed
Definition: OSOption.h:1069
bool deepCopyFrom(ContactOption *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:13587
SOSWeights ** sos
branching weights for the SOS
Definition: OSOption.h:1861
the SolverOption class.
Definition: OSOption.h:3344
bool addVar(int idx, std::string value, std::string lbValue, std::string ubValue)
A function to add a element.
Definition: OSOption.cpp:5948
std::string type
the type of the option value (integer, double, boolean, string)
Definition: OSOption.h:3361
bool IsEqual(InitVarValueString *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:10848
bool setOtherServiceOptions(int numberOfOptions, OtherOption **other)
Definition: OSOption.cpp:7945
int getNumberOfProcessesToKill()
Get the number of processes to kill.
Definition: OSOption.cpp:2005
~InitVariableValuesString()
Class destructor.
Definition: OSOption.cpp:509
int getNumberOfSolverOptions()
Get the number of solver options.
Definition: OSOption.cpp:2207
bool deepCopyFrom(InitVarValueString *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:13837
the InitDualVarValue class.
Definition: OSOption.h:2924
InitObjectiveValues()
Default constructor.
Definition: OSOption.cpp:803
bool setOtherOptionOrResultEnumeration(std::string value, std::string description, int *i, int ni)
Set the indices for a particular level in an enumeration.
Definition: OSGeneral.cpp:621
double ubValue
initial upper bound
Definition: OSOption.h:2357
int getNumberOfFilesToDelete()
Get the number of files to delete.
Definition: OSOption.cpp:1981
~InitDualVarValue()
Class destructor.
Definition: OSOption.cpp:1039
bool addJobID(std::string jobID)
A function to add an &lt;jobID&gt; element.
Definition: OSOption.cpp:4712
std::string value
value of the option
Definition: OSOption.h:3170
bool IsEqual(InitVarValue *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:10751
int getMinCPUNumber()
Get the minimum required number of CPUs.
Definition: OSOption.cpp:1814
InitDualVarValue ** con
initial dual values for each constraint
Definition: OSOption.h:2995
bool OSIsEqual(double x, double y)
Definition: OSGeneral.h:985
JobDependencies()
Default constructor.
Definition: OSOption.cpp:264
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12271
OtherObjectiveOption ** other
other information about the objectives
Definition: OSOption.h:2698
bool setMinCPUSpeed(std::string unit, std::string description, double value)
Set the minimum CPU speed required for the current job.
Definition: OSOption.cpp:7835
bool setOptionStr(std::string optionName, std::string optionValue)
Definition: OSOption.cpp:9520
int getNumberOfOtherSystemOptions()
Get the number of &lt;other&gt; options in the &lt;system&gt; element.
Definition: OSOption.cpp:1837
std::string type
type of the option value (integer, double, boolean, string)
Definition: OSOption.h:2597
int numberOfSOS
number of &lt;sos&gt; children
Definition: OSOption.h:1858
bool IsEqual(OtherObjOption *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:11660
OtherConstraintOption()
Default constructor.
Definition: OSOption.cpp:1095
bool IsEqual(OtherConstraintOption *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:11959
std::string solverToInvoke
the solver to invoke
Definition: OSOption.h:305
PathPairs * inputFilesToMove
input files to move or copy
Definition: OSOption.h:1093
std::string objType
type of the values in the obj array
Definition: OSOption.h:2606
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12698
InitVarValue ** getInitVarValuesSparse()
Get the initial values associated with the variables in sparse form.
Definition: OSOption.cpp:2719
ContactOption()
Default constructor.
Definition: OSOption.cpp:49
std::string ubValue
lower bound on the value
Definition: OSOption.h:1944
SOSWeights()
Default constructor.
Definition: OSOption.cpp:616
InitVarValue()
Default constructor.
Definition: OSOption.cpp:436
int getNumberOfOtherJobOptions()
Get the number of &lt;other&gt; options in the &lt;job&gt; element.
Definition: OSOption.cpp:1861
bool setRandom(double density, bool conformant, int iMin, int iMax)
A function to make a random instance of this class.
Definition: OSGeneral.cpp:1257
~InitObjValue()
Class destructor.
Definition: OSOption.cpp:795
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12719
bool setInitObjValues(int numberOfObj, int *idx, double *value, std::string *name)
Definition: OSOption.cpp:8913
bool addVar(int idx, double value)
A function to add a element.
Definition: OSOption.cpp:5760
bool setAnotherInputDirectoryToMove(std::string fromPath, std::string toPath, bool makeCopy)
Definition: OSOption.cpp:8190
bool deepCopyFrom(OtherObjectiveOption *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:14092
the TimeSpan class.
Definition: OSGeneral.h:924
bool addCon(int idx, double lbDualValue, double ubDualValue)
A function to add a &lt;con&gt; element.
Definition: OSOption.cpp:7099
bool setOtherObjectiveOptionAttributes(int iOther, int numberOfObj, int numberOfEnumerations, std::string name, std::string value, std::string solver, std::string category, std::string type, std::string objType, std::string enumType, std::string description)
Set the attributes for one particular &lt;other&gt; &lt;objective&gt; option.
Definition: OSOption.cpp:9112
int numberOfVar
number of children
Definition: OSOption.h:1676
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12238
InitVariableValues()
Default constructor.
Definition: OSOption.cpp:454
bool setCon(int numberOfCon, InitDualVarValue **con)
A function to set an array of &lt;con&gt; elements.
Definition: OSOption.cpp:6984
double * getInitObjLowerBoundsDense()
Get the initial lower bounds associated with the objectives in dense form.
Definition: OSOption.cpp:3538
int numberOfItems
the number of items (additional pieces of data) of the option
Definition: OSOption.h:3367
std::string getLicense()
Get the license string.
Definition: OSOption.cpp:1495
int numberOfObj
number of &lt;obj&gt; children
Definition: OSOption.h:2579
std::string getRequestedStartTime()
Get the requested starting time.
Definition: OSOption.cpp:1659
bool deepCopyFrom(StorageCapacity *that)
A function to make a deep copy of an instance of this class.
Definition: OSGeneral.cpp:1437
bool addObj(int idx, std::string value, std::string lbValue, std::string ubValue)
A function to add a &lt;obj&gt; element.
Definition: OSOption.cpp:6583
int numberOfJobIDs
the number of entries in the list of job dependencies
Definition: OSOption.h:714
std::string type
type of the option value (integer, double, boolean, string)
Definition: OSOption.h:3179
bool IsEqual(OtherVariableOption *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:11206
bool setJobID(std::string jobID)
Set the job ID.
Definition: OSOption.cpp:7613
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12679
bool setObj(int numberOfObj, InitObjValue **obj)
A function to set an array of &lt;obj&gt; elements.
Definition: OSOption.cpp:6141
InitVarValueString ** getInitVarValuesStringSparse()
Get the initial value strings associated with the variables in sparse form.
Definition: OSOption.cpp:2849
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12941
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12802
OptimizationOption * optimization
optimizationOption holds the fifth child of the OSOption specified by the OSoL Schema.
Definition: OSOption.h:3596
int numberOfOtherConstraintOptions
number of &lt;other&gt; child elements
Definition: OSOption.h:3268
std::string name
optional variable name
Definition: OSOption.h:2351
int numberOfEnumerations
number of &lt;enumeration&gt; child elements
Definition: OSOption.h:2582
std::string value
the value of the &lt;instanceLocation&gt; element
Definition: OSOption.h:47
GeneralOption * general
generalOption holds the first child of the OSOption specified by the OSoL Schema. ...
Definition: OSOption.h:3580
bool setProcessesToKill(int numberOfProcesses, std::string *processes)
Definition: OSOption.cpp:8310
~InitConstraintValues()
Class destructor.
Definition: OSOption.cpp:1009
IntegerVariableBranchingWeights * integerVariableBranchingWeights
branching weights for integer variables
Definition: OSOption.h:2113
the OtherVariableOption class.
Definition: OSOption.h:1989
std::string transportType
the contact mechanism
Definition: OSOption.h:101
bool setOtherObjectiveOptionObj(int otherOptionNumber, int objNumber, int idx, std::string name, std::string value, std::string lbValue, std::string ubValue)
Set one &lt;obj&gt; element associated with an &lt;other&gt; option in the &lt;objectives&gt; element.
Definition: OSOption.cpp:9069
the InitDualVariableValues class.
Definition: OSOption.h:2987
std::string lbValue
lower bound on the value
Definition: OSOption.h:1941
InitConValue()
Default constructor.
Definition: OSOption.cpp:982
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12658
~PathPairs()
Class destructor.
Definition: OSOption.cpp:336
bool deepCopyFrom(ObjectiveOption *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:13987
bool IsEqual(TimeSpan *that)
A function to check for the equality of two objects.
Definition: OSGeneral.cpp:1635
std::string value
the value of the option
Definition: OSOption.h:160
bool setDirectoriesToMake(int numberOfPaths, std::string *paths)
Definition: OSOption.cpp:8097
bool setInitVarValuesSparse(int numberOfVar, InitVarValue **var)
Definition: OSOption.cpp:8399
std::string description
description of the option
Definition: OSOption.h:2600
bool deepCopyFrom(SolverOption *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:14342
bool setInitConValuesDense(int numberOfCon, double *value)
Definition: OSOption.cpp:9224
bool setAnotherDirectoryToMake(std::string path)
Definition: OSOption.cpp:8109
bool setInitConValuesSparse(int numberOfCon, InitConValue **con)
Definition: OSOption.cpp:9194
std::string ubValue
upper bound of the option
Definition: OSOption.h:3108
bool setVar(int numberOfVar, InitVarValueString **var)
A function to set an array of elements.
Definition: OSOption.cpp:5222
int getNumberOfOtherVariableOptions()
Get the number of other variable options.
Definition: OSOption.cpp:2122
bool setMinCPUNumber(int number, std::string description)
Set the minimum number of CPU cores required for the current job.
Definition: OSOption.cpp:7882
The GeneralOption Class.
Definition: OSOption.h:284
bool setOtherConstraintOptions(int numberOfOptions, OtherConstraintOption **other)
Definition: OSOption.cpp:9421
std::string name
optional variable name
Definition: OSOption.h:2517
~OptimizationOption()
Class destructor.
Definition: OSOption.cpp:1246
bool setInstanceLocation(std::string instanceLocation)
Set the instance location.
Definition: OSOption.cpp:7567
the InitObjValue class.
Definition: OSOption.h:2182
int * m_mdInitBasisStatusDense
m_mdInitBasisStatusDense holds the initial basis status in dense form
Definition: OSOption.h:3635
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12754
double getMinCPUSpeed()
Get the minimum required CPU speed.
Definition: OSOption.cpp:1763
MinDiskSpace()
Default constructor.
Definition: OSOption.cpp:145
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12482
int idx
constraint index
Definition: OSOption.h:2768
bool setContactTransportType(std::string transportType)
Set the transport type for contact.
Definition: OSOption.cpp:7677
std::string * getFilesToDelete()
Get the array of files to delete.
Definition: OSOption.cpp:2662
bool setAnOtherConstraintOption(OtherConstraintOption *optionValue)
Definition: OSOption.cpp:9438
bool IsEqual(JobDependencies *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:10361
int getNumberOfInputDirectoriesToMove()
Get the number of input directories to move.
Definition: OSOption.cpp:1933
bool addCon(int idx, double value)
A function to add a &lt;con&gt; element.
Definition: OSOption.cpp:6897
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12816
bool IsEqual(SOSVariableBranchingWeights *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:11041
bool IsEqual(StorageCapacity *that)
A function to check for the equality of two objects.
Definition: OSGeneral.cpp:1366
double getMinMemorySize()
Get the minimum required memory.
Definition: OSOption.cpp:1751
std::string unit
the unit in which disk space is measured
Definition: OSOption.h:374
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12557
the InitVarValueString class.
Definition: OSOption.h:1320
ObjectiveOption * objectives
the options for the objectives
Definition: OSOption.h:3512
bool IsEqual(ConstraintOption *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:11709
int numberOfOtherOptions
the number of other options
Definition: OSOption.h:216
bool deepCopyFrom(InitVarValue *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:13804
BasisStatus * initialBasisStatus
initial basis status for the slack variables
Definition: OSOption.h:3277
bool setOtherConstraintOptionAttributes(int iOther, int numberOfCon, int numberOfEnumerations, std::string name, std::string value, std::string solver, std::string category, std::string type, std::string conType, std::string enumType, std::string description)
Set the attributes for one particular &lt;other&gt; &lt;constraint&gt; option.
Definition: OSOption.cpp:9356
~IntegerVariableBranchingWeights()
Class destructor.
Definition: OSOption.cpp:598
std::string getMinCPUSpeedDescription()
Get the CPU speed description.
Definition: OSOption.cpp:1612
std::vector< OtherObjectiveOption * > getOtherObjectiveOptions(std::string solver_name)
Get the array of other objective options.
Definition: OSOption.cpp:3905
SolverOption ** solverOption
the list of solver options
Definition: OSOption.h:3426
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12305
int getNumberOfIntegerVariableBranchingWeights()
Get the number of variables for which integer branching weights are provided.
Definition: OSOption.cpp:2082
bool deepCopyFrom(OtherConOption *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:14307
double value
initial value
Definition: OSOption.h:2774
bool setAnotherOutputFileToMove(std::string fromPath, std::string toPath, bool makeCopy)
Definition: OSOption.cpp:8234
bool setObj(int numberOfObj, OtherObjOption **obj)
A function to set an array of &lt;obj&gt; elements.
Definition: OSOption.cpp:6544
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12463
InitObjectiveBounds * initialObjectiveBounds
initial bounds for the objectives
Definition: OSOption.h:2692
bool IsEqual(ContactOption *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:10024
int idx
constraint index
Definition: OSOption.h:2929
bool setVar(int numberOfVar, BranchingWeight **var)
A function to set an array of elements.
Definition: OSOption.cpp:5514
bool setRequiredFiles(int numberOfPaths, std::string *paths)
Definition: OSOption.cpp:8075
BranchingWeight ** var
branching weight for each variable
Definition: OSOption.h:1679
bool setNumberOfOtherObjectiveOptions(int numberOfOther)
Definition: OSOption.cpp:9092
OtherObjOption ** obj
array of option values
Definition: OSOption.h:2603
std::string * getDirectoriesToDelete()
Get the array of directories to delete.
Definition: OSOption.cpp:2680
int getNumberOfInitObjValues()
Get the number of initial objective values.
Definition: OSOption.cpp:2134
InitObjBound ** obj
initial bounds for each objective
Definition: OSOption.h:2413
InitBasStatus()
Default constructor.
Definition: OSOption.cpp:527
int getNumberOfFilesToMake()
Get the number of files to make.
Definition: OSOption.cpp:1921
bool IsEqual(InstanceLocationOption *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:9978
the InstanceLocationOption class.
Definition: OSOption.h:39
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12609
bool setMinCPUSpeedUnit(std::string unit)
Definition: OSOption.cpp:7850
std::string ubValue
lower bound on the value
Definition: OSOption.h:2527
MinCPUNumber()
Default constructor.
Definition: OSOption.cpp:198
the ContactOption class.
Definition: OSOption.h:96
std::string getFileSource()
Get the source of the file or problem.
Definition: OSOption.cpp:1371
bool addCon(int idx, std::string value, std::string lbValue, std::string ubValue)
A function to add a &lt;con&gt; element.
Definition: OSOption.cpp:7225
std::string getFileName()
Get the name of the file.
Definition: OSOption.cpp:1360
int getNumberOfOtherServiceOptions()
Get the number of &lt;other&gt; options in the &lt;service&gt; element.
Definition: OSOption.cpp:1849
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12733
bool setInitDualVarValuesSparse(int numberOfCon, InitDualVarValue **con)
Definition: OSOption.cpp:9272
std::string description
the description of the option
Definition: OSOption.h:3364
bool setFilesToDelete(int numberOfPaths, std::string *paths)
Definition: OSOption.cpp:8266
~JobDependencies()
Class destructor.
Definition: OSOption.cpp:273
bool setRandom(double density, bool conformant, int iMin, int iMax)
A function to make a random instance of this class.
Definition: OSGeneral.cpp:686
bool setOptionInt(std::string optionName, int optionValue)
Definition: OSOption.cpp:9583
used for throwing exceptions.
Definition: OSErrorClass.h:31
the OtherConOption class.
Definition: OSOption.h:3091
~BranchingWeight()
Class destructor.
Definition: OSOption.cpp:581
bool setInstanceName(std::string instanceName)
Set the instance name.
Definition: OSOption.cpp:7559
int getNumberOfDirectoriesToDelete()
Get the number of directories to delete.
Definition: OSOption.cpp:1993
void fint * n
bool deepCopyFrom(SystemOption *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:13389
OtherConstraintOption ** getAllOtherConstraintOptions()
Get all &lt;other&gt; constraint options.
Definition: OSOption.cpp:4461
std::string getMinDiskSpaceUnit()
Get the disk space unit.
Definition: OSOption.cpp:1552
int idx
variable index
Definition: OSOption.h:2514
bool deepCopyFrom(OtherConstraintOption *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:14259
bool setMaxTimeUnit(std::string unit)
Definition: OSOption.cpp:8000
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSOption.cpp:12518
bool IsEqual(MinCPUSpeed *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:10266
OtherConstraintOption * getOtherConstraintOption(int optionNumber)
Get one particular &lt;other&gt; constraint option from the array of options.
Definition: OSOption.cpp:4483
double value
the minimum CPU speed required
Definition: OSOption.h:470
the InitObjectiveValues class.
Definition: OSOption.h:2241
bool setOther(int numberOfOptions, OtherOption **other)
A function to set an array of &lt;other&gt; elements.
Definition: OSOption.cpp:4599
InitObjValue ** getInitObjValuesSparse()
Get the initial values associated with the objectives in sparse form.
Definition: OSOption.cpp:3386
double * m_mdInitDualVarUpperBoundsDense
m_mdInitDualVarUpperBoundsDense holds initial dual values for the upper bound of the constraints in d...
Definition: OSOption.h:3672
OtherVariableOption * getOtherVariableOption(int optionNumber)
Get one particular &lt;other&gt; variable option from the array of options.
Definition: OSOption.cpp:3363
bool setInitVarValuesStringDense(int numberOfVar, std::string *value)
Definition: OSOption.cpp:8510
~InitConValue()
Class destructor.
Definition: OSOption.cpp:992
bool setAnotherInitObjBound(int idx, double lbValue, double ubValue)
Definition: OSOption.cpp:9058
~ServiceOption()
Class destructor.
Definition: OSOption.cpp:254
the OtherOptions class.
Definition: OSOption.h:211
bool IsEqual(GeneralOption *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:9661
std::string * process
the list of processes
Definition: OSOption.h:1001
OtherOptions * otherOptions
list of other job options
Definition: OSOption.h:1111
std::string getPassword()
Get the password.
Definition: OSOption.cpp:1517
bool deepCopyFrom(InitConstraintValues *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:14194
int * el
Definition: OSGeneral.h:484
bool setOtherVariableOptionVar(int otherOptionNumber, int varNumber, int idx, std::string name, std::string value, std::string lbValue, std::string ubValue)
Set one element associated with an &lt;other&gt; option in the &lt;variables&gt; element.
Definition: OSOption.cpp:8863
a data structure to represent an LP basis on both input and output
Definition: OSGeneral.h:645
std::string unit
the unit in which memory size is measured
Definition: OSOption.h:419
bool addVar(int idx, std::string value)
A function to add a element.
Definition: OSOption.cpp:5343
the StorageCapacity class.
Definition: OSGeneral.h:754
bool deepCopyFrom(ServiceOption *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:13428
int getNumberOfInitialBasisElements(int type, int status)
Get the number of initial basis elements for a particular variable type and basis status...
Definition: OSOption.cpp:3073
~InitBasStatus()
Class destructor.
Definition: OSOption.cpp:536
std::string unit
the unit in which time is measured
Definition: OSGeneral.h:929
the Processes class.
Definition: OSOption.h:993
bool setOtherSystemOptions(int numberOfOptions, OtherOption **other)
Definition: OSOption.cpp:7893
double value
the number of units of storage capacity
Definition: OSGeneral.h:765
OtherConstraintOption ** other
other information about the constraints
Definition: OSOption.h:3280
the BranchingWeight class.
Definition: OSOption.h:1611
bool setOutputDirectoriesToMove(int numberOfPathPairs, PathPair **pathPair)
Definition: OSOption.cpp:8244
JobDependencies * dependencies
the dependency set
Definition: OSOption.h:1075
InitObjBound ** getInitObjBoundsSparse()
Get the initial bounds associated with the objectives in sparse form.
Definition: OSOption.cpp:3513
InitVariableValues * initialVariableValues
initial values for the variables
Definition: OSOption.h:2104
DirectoriesAndFiles * requiredFiles
files required to run the job
Definition: OSOption.h:1081
bool setContact(std::string contact)
Set the contact information.
Definition: OSOption.cpp:7653
~InitObjectiveBounds()
Class destructor.
Definition: OSOption.cpp:859
bool setAnotherRequiredDirectory(std::string path)
Definition: OSOption.cpp:8065
bool IsEqual(InitVariableValues *that)
A function to check for the equality of two objects.
Definition: OSOption.cpp:10702
bool setInitVarValues(int numberOfVar, int *idx, double *value, std::string *name)
Definition: OSOption.cpp:8385
bool setRandom(double density, bool conformant)
A function to make a random instance of this class.
Definition: OSGeneral.cpp:1683
bool setPassword(std::string password)
Set the password.
Definition: OSOption.cpp:7645
std::string getInstanceLocation()
Get the instance location.
Definition: OSOption.cpp:1449
std::string enumType
type of the values in the enumeration array
Definition: OSOption.h:2030
std::string licence
licensing information if applicable
Definition: OSGeneral.h:60
bool deepCopyFrom(InitDualVariableValues *that)
A function to make a deep copy of an instance of this class.
Definition: OSOption.cpp:14226
std::vector< OtherVariableOption * > getOtherVariableOptions(std::string solver_name)
Get the &lt;other&gt; variable options associated with a particular solver.
Definition: OSOption.cpp:3315