?? constraint.java
字號:
package com.power.pipeengine.Constraint;
import com.power.util.Message.*;
import com.power.pipeengine.*;
import java.util.ResourceBundle;
import com.power.lpsolver.LPSolve.*;
/**
*
* <p>Title: PIPE Engine</p>
* <p>Description: Global Planning Optimization Engine</p>
* <p>Copyright: Copyright (c) 2002</p>
* <p>Company: Paraster, Inc.</p>
* @author Wei Tan
* @version 1.0
*/
/**
* Constraint is the super class of all constraint types.
*/
public class Constraint
{
static ResourceBundle res = ResourceBundle.getBundle("com.power.pipeengine.Res",
EngineConfig.getInstance().getLocale() );
private String _constraintType = "";
/**
* Sole class constructor.
*/
public Constraint() {
}
/**
* Sets the constraint type to the type specified in paraster.
* @param aType the type to set for this constraint.
*/
protected void setConstraintType( String aType ) {
_constraintType = aType;
}
/**
* Publishes message right before building the constraints.
*/
public void publishMessage() {
String msg = res.getString("Engine1200") + _constraintType + ".\n";
MessageArea.getInstance().addMessage( msg );
}
public void addMPSElem(com.power.lpsolver.LPSolve.Constraint con, int colIdx, Element elem) {
com.power.lpsolver.LPSolve.Variable var =
Model.getInstance().getModelVariables().getVariable( colIdx );
var.addMPSElem( con, elem );
}
}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -