本文整理汇总了Java中org.cpsolver.ifs.solver.Solver.getExtensions方法的典型用法代码示例。如果您正苦于以下问题:Java Solver.getExtensions方法的具体用法?Java Solver.getExtensions怎么用?Java Solver.getExtensions使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.cpsolver.ifs.solver.Solver
的用法示例。
在下文中一共展示了Solver.getExtensions方法的12个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: init
import org.cpsolver.ifs.solver.Solver; //导入方法依赖的package包/类
@Override
public boolean init(Solver<Lecture, Placement> solver) {
super.init(solver);
for (Extension<Lecture, Placement> extension : solver.getExtensions()) {
if (ConflictStatistics.class.isInstance(extension))
iStat = (ConflictStatistics<Lecture, Placement>) extension;
}
solver.currentSolution().addSolutionListener(this);
return true;
}
示例2: init
import org.cpsolver.ifs.solver.Solver; //导入方法依赖的package包/类
@Override
public void init(Solver<Lecture, Placement> solver) {
for (Extension<Lecture, Placement> extension : solver.getExtensions()) {
if (MacPropagation.class.isInstance(extension))
iProp = (MacPropagation<Lecture, Placement>) extension;
}
}
示例3: init
import org.cpsolver.ifs.solver.Solver; //导入方法依赖的package包/类
@Override
public boolean init(Solver<V, T> solver) {
if (iResetInterval > 0) {
for (Extension<V, T> ex : solver.getExtensions()) {
if (ConflictStatistics.class.isInstance(ex)) {
iCBS = (ConflictStatistics<V, T>) ex;
break;
}
}
}
return super.init(solver);
}
示例4: init
import org.cpsolver.ifs.solver.Solver; //导入方法依赖的package包/类
/**
* Initialization -- methods
* {@link org.cpsolver.ifs.heuristics.VariableSelection#init(Solver)} and
* {@link org.cpsolver.ifs.heuristics.ValueSelection#init(Solver)} are
* called.
*/
@Override
public void init(Solver<V, T> solver) {
getValueSelection().init(solver);
getVariableSelection().init(solver);
iSolver = solver;
for (Extension<V, T> ext: solver.getExtensions())
if (ext instanceof ConflictStatistics)
iStat = (ConflictStatistics<V, T>)ext;
}
示例5: init
import org.cpsolver.ifs.solver.Solver; //导入方法依赖的package包/类
/** Solver initialization */
@Override
public void init(Solver<V, T> solver) {
super.init(solver);
for (Extension<V, T> extension : solver.getExtensions()) {
if (ConflictStatistics.class.isInstance(extension))
iStat = (ConflictStatistics<V, T>) extension;
}
}
示例6: init
import org.cpsolver.ifs.solver.Solver; //导入方法依赖的package包/类
/** Initialization */
@Override
public void init(Solver<V, T> solver) {
for (Extension<V, T> extension : solver.getExtensions()) {
if (ConflictStatistics.class.isInstance(extension))
iStat = (ConflictStatistics<V, T>) extension;
if (MacPropagation.class.isInstance(extension))
iProp = (MacPropagation<V, T>) extension;
if (ViolatedInitials.class.isInstance(extension))
iViolatedInitials = (ViolatedInitials<V, T>) extension;
}
}
示例7: init
import org.cpsolver.ifs.solver.Solver; //导入方法依赖的package包/类
/** Initialization */
@Override
public void init(Solver<V, T> solver) {
for (Extension<V, T> extension : solver.getExtensions()) {
if (MacPropagation.class.isInstance(extension))
iProp = (MacPropagation<V, T>) extension;
}
}
示例8: init
import org.cpsolver.ifs.solver.Solver; //导入方法依赖的package包/类
/**
* Heuristics initialization
*
* @see VariableSelection#init(Solver)
*/
@Override
public void init(Solver<V, T> solver) {
for (Extension<V, T> extension : solver.getExtensions()) {
if (extension instanceof DbtPropagation<?, ?>) {
iProp = (DbtPropagation<V, T>) extension;
}
}
}
示例9: init
import org.cpsolver.ifs.solver.Solver; //导入方法依赖的package包/类
/**
* Heuristics initialization
*
* @see ValueSelection#init(Solver)
*/
@Override
public void init(Solver<V, T> solver) {
for (Extension<V, T> extension : solver.getExtensions()) {
if (DbtPropagation.class.isInstance(extension)) {
iProp = (DbtPropagation<V, T>) extension;
}
if (ViolatedInitials.class.isInstance(extension)) {
iViolatedInitials = (ViolatedInitials<V, T>) extension;
}
}
}
示例10: init
import org.cpsolver.ifs.solver.Solver; //导入方法依赖的package包/类
/** Initialization */
@Override
public void init(Solver<V, T> solver) {
for (Extension<V, T> extension : solver.getExtensions()) {
if (ViolatedInitials.class.isInstance(extension))
iViolatedInitials = (ViolatedInitials<V, T>) extension;
}
}
示例11: init
import org.cpsolver.ifs.solver.Solver; //导入方法依赖的package包/类
/** Initialization */
@Override
public void init(Solver<Exam, ExamPlacement> solver) {
super.init(solver);
for (Extension<Exam, ExamPlacement> extension : solver.getExtensions()) {
if (ConflictStatistics.class.isInstance(extension))
iStat = (ConflictStatistics<Exam, ExamPlacement>) extension;
}
}
示例12: init
import org.cpsolver.ifs.solver.Solver; //导入方法依赖的package包/类
/** Initialization */
@Override
public void init(Solver<Request, Enrollment> solver) {
for (Extension<Request, Enrollment> extension : solver.getExtensions()) {
if (ConflictStatistics.class.isInstance(extension))
iStat = (ConflictStatistics<Request, Enrollment>) extension;
if (MacPropagation.class.isInstance(extension))
iProp = (MacPropagation<Request, Enrollment>) extension;
if (ViolatedInitials.class.isInstance(extension))
iViolatedInitials = (ViolatedInitials<Request, Enrollment>) extension;
}
}