introduce struct to hold flags in cpp init code; rename classes

This commit is contained in:
Laurent Perron
2021-03-24 09:54:39 +01:00
parent f9f4ab4d5f
commit 6a562b0c29
6 changed files with 54 additions and 20 deletions

View File

@@ -12,6 +12,7 @@
// limitations under the License.
using System;
using Google.OrTools.Init;
using Google.OrTools.LinearSolver;
public class CsIntegerProgramming
@@ -100,7 +101,11 @@ public class CsIntegerProgramming
static void Main()
{
Google.OrTools.Init.Init.InitCppLogging("csintegerprogramming.cs", true, false);
CppBridge.InitLogging("csintegerprogramming.cs");
CppFlags flags = new CppFlags();
flags.logtostderr = true;
flags.log_prefix = false;
CppBridge.SetFlags(flags);
Console.WriteLine("---- Integer programming example with GLPK ----");
RunIntegerProgrammingExample("GLPK");