本文整理了Java中com.powsybl.iidm.network.Network.getLineStream()
方法的一些代码示例,展示了Network.getLineStream()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Network.getLineStream()
方法的具体详情如下:
包路径:com.powsybl.iidm.network.Network
类名称:Network
方法名:getLineStream
[英]Get all AC lines.
[中]接通所有的交流线路。
代码示例来源:origin: com.powsybl/powsybl-iidm-reducer
public final void reduce(Network network) {
List<Line> lines = network.getLineStream()
.filter(l -> !test(l))
.collect(Collectors.toList());
代码示例来源:origin: itesla/ipst
private static void dumpLinesDictionary(Network network, EurostagDictionary dictionary, Path dir, EurostagEchExportConfig exportConfig) throws IOException {
try (BufferedWriter os = Files.newBufferedWriter(dir.resolve("dict_lines.csv"), StandardCharsets.UTF_8)) {
for (Identifiable obj : Identifiables.sort(Iterables.concat(
network.getLineStream().filter(line -> !(exportConfig.isExportMainCCOnly() && !EchUtil.isInMainCc(line, exportConfig.isNoSwitch()))).collect(Collectors.toList()),
network.getTwoWindingsTransformerStream().filter(twt -> !(exportConfig.isExportMainCCOnly() && !EchUtil.isInMainCc(twt, exportConfig.isNoSwitch()))).collect(Collectors.toList()),
network.getDanglingLineStream().filter(dl -> !(exportConfig.isExportMainCCOnly() && !EchUtil.isInMainCc(dl, exportConfig.isNoSwitch()))).collect(Collectors.toList())
))) {
os.write(obj.getId() + ";" + dictionary.getEsgId(obj.getId()));
os.newLine();
}
for (ThreeWindingsTransformer twt : Identifiables.sort(network.getThreeWindingsTransformers())) {
throw new AssertionError("TODO");
}
}
}
代码示例来源:origin: com.powsybl/powsybl-loadflow-results-completion
LOGGER.info("LoadFlowParameters={}", lfParameters);
network.getLineStream().forEach(line -> {
BranchData lineData = new BranchData(line,
parameters.getEpsilonX(),
内容来源于网络,如有侵权,请联系作者删除!