Package com.google.ortools.init
Class CppBridge
- java.lang.Object
-
- com.google.ortools.init.CppBridge
-
public class CppBridge extends java.lang.ObjectThis class performs various C++ initialization.
It is meant to be used once at the start of a program.
-
-
Field Summary
Fields Modifier and Type Field Description protected booleanswigCMemOwn
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddelete()protected voidfinalize()protected static longgetCPtr(CppBridge obj)static voidinitLogging(java.lang.String usage)Initialize the C++ logging layer.
This must be called once before any other library from OR-Tools are used.static booleanlogGurobiSharedLibrary(java.lang.String full_library_path)Load the gurobi shared library.
This is necessary if the library is installed in a non canonical
directory, or if for any reason, it is not found.
You need to pass the full path, including the shared library file.
It returns true if the library was found and correctly loaded.static voidsetFlags(CppFlags flags)Sets all the C++ flags contained in the CppFlags structure.static voidshutdownLogging()Shutdown the C++ logging layer.
This can be called to shutdown the C++ logging layer from OR-Tools.
It should only be called once.
Deprecated: this is a no-op.protected static longswigRelease(CppBridge obj)
-
-
-
Method Detail
-
getCPtr
protected static long getCPtr(CppBridge obj)
-
swigRelease
protected static long swigRelease(CppBridge obj)
-
finalize
protected void finalize()
- Overrides:
finalizein classjava.lang.Object
-
delete
public void delete()
-
initLogging
public static void initLogging(java.lang.String usage)
Initialize the C++ logging layer.
This must be called once before any other library from OR-Tools are used.
-
shutdownLogging
public static void shutdownLogging()
Shutdown the C++ logging layer.
This can be called to shutdown the C++ logging layer from OR-Tools.
It should only be called once.
Deprecated: this is a no-op.
-
setFlags
public static void setFlags(CppFlags flags)
Sets all the C++ flags contained in the CppFlags structure.
-
logGurobiSharedLibrary
public static boolean logGurobiSharedLibrary(java.lang.String full_library_path)
Load the gurobi shared library.
This is necessary if the library is installed in a non canonical
directory, or if for any reason, it is not found.
You need to pass the full path, including the shared library file.
It returns true if the library was found and correctly loaded.
-
-