WileESpaghetti / intellij-rabbitmq-management

Manage RabbitMQ Servers from inside JetBrains IDEs
MIT License
0 stars 0 forks source link

Use new API for PesistentStateComponents #42

Closed WileESpaghetti closed 4 years ago

WileESpaghetti commented 4 years ago

Current implementation is using the Legacy API (JDOMExternalizable) to persist settings. We need to switch to the methods mentioned in https://www.jetbrains.org/intellij/sdk/docs/basics/persisting_state_of_components.html

WileESpaghetti commented 4 years ago

Turns out we are not using the legacy API and are still using a supported method to save state

If the state that you need to serialize doesn’t map cleanly to a JavaBean, you can use org.jdom.Element as the state class. In that case, you can use the getState() method to build an XML element with an arbitrary structure, which will then be saved directly in the state XML file