Skip to content

Migration guide v3.5.0

Florian Dupuy edited this page Jul 28, 2020 · 3 revisions

Migrate to IIDM/XIIDM 1.3

At this release, IIDM has been changed to version 1.3. For more information about the new features, please read the documentation page about IIDM/IIDM-XML 1.3 evolutions.

API

If you are using a custom implementation of IIDM API (different from the one available in powsybl-iidm-impl), please be sure to update your implementation in order not to throw UnsupportedOperationException when a new method is used.

Serialization

If you are using a XIIDM converter from powsybl-core v3.5.0 and above to write IIDM network files in version 1.3, you should use a XIIDM converter from powsybl-core v3.5.0 to read them as well without issues.

Please note that it is possible to read and write XIIDM files in previous IIDM-XML versions.

In order to write XIIDM files in previous versions (e.g. the version 1.0), you need to use the following configuration property:

import-export-parameters-default-value:
  iidm.export.xml.version: "1.0"

or use the Java object ExportOptions in your parameters with a suitable set version:

... // do something
ExportOptions options = new ExportOptions().setVersion("1.0");
NetworkXml.write(network, options, path);
... // do something

⚠️ Writing XIIDM files in previous versions will only be possible if the network you want to serialize has no new features or has only new features that can be interpreted in the previous versions.

Reading XIIDM files in previous versions does not require any particular configuration.

Rename SetPoint to Setpoint

The methods get/setVoltageSetPoint and get/setReactiveSetPoint of the StaticVarCompensator interface are deprecated and replace by get/setVoltageSetpoint and get/setReactiveSetpoint

AbstractMultiVariantConnectableExtension

AbstractMultiVariantConnectableExtension is now deprecated, AbstractMultiVariantIdentifiableExtension should be used instead.

Besides, this generic class is now parameterized with T extends Connectable<T> instead of the T extends Connectable used previously. If you defined an inheriting class which extended AbstractMultiVariantConnectableExtension<T>, the class T now needs to extend Connectable<T> - or Identifiable<T> if you use AbstractMultiVariantIdentifiableExtension as recommended.

Indeed, note that similarly, AbstractMultiVariantIdentifiableExtension is parameterized with T extends Identifiable<T>, and that AbstractMultiVariantConnectableExtension<T> extends AbstractMultiVariantIdentifiableExtension<T>.

Clone this wiki locally