com.powsybl.iidm.network.Branch.newCurrentLimits2()方法的使用及代码示例

x33g5p2x  于2022-01-17 转载在 其他  
字(2.3k)|赞(0)|评价(0)|浏览(106)

本文整理了Java中com.powsybl.iidm.network.Branch.newCurrentLimits2()方法的一些代码示例,展示了Branch.newCurrentLimits2()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Branch.newCurrentLimits2()方法的具体详情如下:
包路径:com.powsybl.iidm.network.Branch
类名称:Branch
方法名:newCurrentLimits2

Branch.newCurrentLimits2介绍

暂无

代码示例

代码示例来源:origin: itesla/ipst

violation.getLimit(),
    newLimit);
branch.newCurrentLimits2().setPermanentLimit(newLimit).add();
if (applyToBaseCase && !StateManagerConstants.INITIAL_STATE_ID.equals(stateId)) { // change the limit also to basecase
  network.getStateManager().setWorkingState(StateManagerConstants.INITIAL_STATE_ID);
        violation.getLimit(),
        newLimit);
  branch.newCurrentLimits2().setPermanentLimit(newLimit).add();
  network.getStateManager().setWorkingState(stateId);

代码示例来源:origin: com.powsybl/powsybl-cgmes-conversion

private void convertPatlCurrentTerminal(double value) {
  Connectable<?> connectable = terminal.getConnectable();
  if (connectable instanceof Branch) {
    int terminalNumber = context.terminalMapping().number(terminalId);
    Branch<?> b = (Branch<?>) connectable;
    if (terminalNumber == 1) {
      b.newCurrentLimits1().setPermanentLimit(value).add();
    } else if (terminalNumber == 2) {
      b.newCurrentLimits2().setPermanentLimit(value).add();
    } else {
      notAssigned(b);
    }
  } else if (connectable instanceof DanglingLine) {
    ((DanglingLine) connectable).newCurrentLimits().setPermanentLimit(value).add();
  } else {
    notAssigned(connectable);
  }
}

代码示例来源:origin: com.powsybl/powsybl-cgmes-conversion

private void convertPatlCurrent(double value) {
  // Enhancement: we should be able to use a CurrentLimitsAdder (an owner)
  // to avoid checking the class of the equipment
  // In terminal mapping insert a CurrentLimitsAdder instead of a Branch.side
  if (terminal != null) {
    convertPatlCurrentTerminal(value);
  } else if (branch != null) {
    // We should reject the value if the branch is a PowerTransformer
    if (branch instanceof TwoWindingsTransformer) {
      context.ignored("CurrentLimit", "Defined for Equipment TwoWindingsTransformer. Should be defined for one Terminal of Two");
      notAssigned(branch);
    } else {
      // Set same limit at both sides
      branch.newCurrentLimits1().setPermanentLimit(value).add();
      branch.newCurrentLimits2().setPermanentLimit(value).add();
    }
  } else if (danglingLine != null) {
    danglingLine.newCurrentLimits().setPermanentLimit(value).add();
  } else if (aswitch != null) {
    notAssigned(aswitch);
  } else {
    notAssigned();
  }
}

相关文章