powsybl-core
powsybl-core copied to clipboard
[Actions] Hook for JSON serialization of custom actions and conditions
- Do you want to request a feature or report a bug?
Feature.
- What is the current behavior?
Third party libraries could provide their own type of actions and conditions, and a simulator that would simulate them.
However, the JSON serialization provided by powsybl will not be able to handle them, making it impossible to used, for example, the security analysis tool (itools security-analysis).
- What is the expected behavior?
Third party users should be able to provide serialization definition for their actions/conditions.
This will involve defining a service interface, which will be in charge of providing the serializers and the deserializers for the new types.
Note: We could allow the definition of multiple actions and conditions serialization in only one object, this could allow third party libraries to centralize their plugin in only one service implementation, instead of multiple small ones.
- What is the motivation / use case for changing the behavior?
Being able to extend the JSON format for operator strategies with custom actions and conditions.