Google OR-Tools
v9.11
a fast and portable software suite for combinatorial optimization
Loading...
Searching...
No Matches
DisjunctiveConstraint.java
Go to the documentation of this file.
1
/* ----------------------------------------------------------------------------
2
* This file was automatically generated by SWIG (https://www.swig.org).
3
* Version 4.2.1
4
*
5
* Do not make changes to this file unless you know what you are doing - modify
6
* the SWIG interface file instead.
7
* ----------------------------------------------------------------------------- */
8
9
package
com.google.ortools.constraintsolver;
10
11
// Used to wrap IndexEvaluator2
12
// see https://docs.oracle.com/javase/8/docs/api/java/util/function/LongBinaryOperator.html
13
import
java.util.function.LongBinaryOperator;
14
15
public
class
DisjunctiveConstraint
extends
Constraint
{
16
private
transient
long
swigCPtr;
17
18
protected
DisjunctiveConstraint
(
long
cPtr,
boolean
cMemoryOwn) {
19
super(mainJNI.DisjunctiveConstraint_SWIGUpcast(cPtr), cMemoryOwn);
20
swigCPtr = cPtr;
21
}
22
23
protected
static
long
getCPtr
(
DisjunctiveConstraint
obj) {
24
return
(obj ==
null
) ? 0 : obj.swigCPtr;
25
}
26
27
protected
static
long
swigRelease
(
DisjunctiveConstraint
obj) {
28
long
ptr = 0;
29
if
(obj !=
null
) {
30
if
(!obj.
swigCMemOwn
)
31
throw
new
RuntimeException(
"Cannot release ownership as memory is not owned"
);
32
ptr = obj.swigCPtr;
33
obj.swigCMemOwn =
false
;
34
obj.
delete
();
35
}
36
return
ptr;
37
}
38
39
@SuppressWarnings({
"deprecation"
,
"removal"
})
40
protected
void
finalize
() {
41
delete
();
42
}
43
44
public
synchronized
void
delete
() {
45
if
(swigCPtr != 0) {
46
if
(
swigCMemOwn
) {
47
swigCMemOwn
=
false
;
48
mainJNI.delete_DisjunctiveConstraint(swigCPtr);
49
}
50
swigCPtr = 0;
51
}
52
super.delete();
53
}
54
58
public
SequenceVar
makeSequenceVar
() {
59
long
cPtr = mainJNI.DisjunctiveConstraint_makeSequenceVar(swigCPtr,
this
);
60
return
(cPtr == 0) ? null :
new
SequenceVar
(cPtr,
false
);
61
}
62
69
public
void
setTransitionTime
(LongBinaryOperator transition_time) {
70
mainJNI.DisjunctiveConstraint_setTransitionTime(swigCPtr,
this
, transition_time);
71
}
72
73
public
long
transitionTime
(
int
before_index,
int
after_index) {
74
return
mainJNI.DisjunctiveConstraint_transitionTime(swigCPtr,
this
, before_index, after_index);
75
}
76
77
}
com.google.ortools.constraintsolver.BaseObject.swigCMemOwn
transient boolean swigCMemOwn
Definition
BaseObject.java:18
com.google.ortools.constraintsolver.Constraint
Definition
Constraint.java:19
com.google.ortools.constraintsolver.DisjunctiveConstraint
Definition
DisjunctiveConstraint.java:15
com.google.ortools.constraintsolver.DisjunctiveConstraint.getCPtr
static long getCPtr(DisjunctiveConstraint obj)
Definition
DisjunctiveConstraint.java:23
com.google.ortools.constraintsolver.DisjunctiveConstraint.setTransitionTime
void setTransitionTime(LongBinaryOperator transition_time)
Definition
DisjunctiveConstraint.java:69
com.google.ortools.constraintsolver.DisjunctiveConstraint.transitionTime
long transitionTime(int before_index, int after_index)
Definition
DisjunctiveConstraint.java:73
com.google.ortools.constraintsolver.DisjunctiveConstraint.makeSequenceVar
SequenceVar makeSequenceVar()
Definition
DisjunctiveConstraint.java:58
com.google.ortools.constraintsolver.DisjunctiveConstraint.delete
synchronized void delete()
Definition
DisjunctiveConstraint.java:44
com.google.ortools.constraintsolver.DisjunctiveConstraint.swigRelease
static long swigRelease(DisjunctiveConstraint obj)
Definition
DisjunctiveConstraint.java:27
com.google.ortools.constraintsolver.DisjunctiveConstraint.DisjunctiveConstraint
DisjunctiveConstraint(long cPtr, boolean cMemoryOwn)
Definition
DisjunctiveConstraint.java:18
com.google.ortools.constraintsolver.DisjunctiveConstraint.finalize
void finalize()
Definition
DisjunctiveConstraint.java:40
com.google.ortools.constraintsolver.SequenceVar
Definition
SequenceVar.java:19
build
java
ortools-java
src
main
java
com
google
ortools
constraintsolver
DisjunctiveConstraint.java
Generated by
1.12.0