Unclonnable property - ElkReflect [message #1802038] |
Thu, 31 January 2019 08:21 ![Go to next message Go to next message](png/down.png) |
Baptiste Colin![Friend of Eclipse Friend](png/friends_decorator8d53.png) Messages: 5 Registered: January 2019 |
Junior Member |
|
|
Hi everybody,
When trying to layout or convert a graph to JSON format, I get the following error :
2019-01-31 10:02:53,032 [AWT-EventQueue-0] ERROR GENERAL - Unhandled exception - Couldn't clone property 'org.eclipse.elk.junctionPoints'. Make sure it's type is registered with the ElkReflect utility class.
java.lang.IllegalStateException: Couldn't clone property 'org.eclipse.elk.junctionPoints'. Make sure it's type is registered with the ElkReflect utility class.
at org.eclipse.elk.graph.properties.Property.getDefault(Property.java:140)
The error above happened when trying to convert the graph to a JSON. The same message occured, but with "org.eclipse.elk.nodeLabels.padding" instead of "org.eclipse.elk.junctionPoints", when trying to layout the graph with LayeredLayoutProvider.
This doesn't happen when I'm operating over a simple graph (5 nodes, 6 edges, some ports), but happens on a more complex graph (built by iterating over a SysML model).
How should I proceed so that "types are registered with the ElkReflect utility class", as the error message says ? Is it a dependency problem or does it have to something to do with the graph construction process ?
I'm only using basic ELK functions for constructing my graph (ElkGraphFactory.createElkNode, ElkGraphFactory.createSElkPort, ElkGraphUtil.createSimpleEdge).
Thanks in advance
|
|
|
|
|
Re: Unclonnable property - ElkReflect [message #1802104 is a reply to message #1802102] |
Fri, 01 February 2019 08:54 ![Go to previous message Go to previous message](png/up.png) ![Go to next message Go to next message](png/down.png) |
|
You need to initialize the layout metadata service with the algorithm you'd like to use:
LayoutMetaDataService.getInstance().registerLayoutMetaDataProviders(
new ForceMetaDataProvider(),
new LayeredMetaDataProvider(),
new MrTreeMetaDataProvider(),
new RadialMetaDataProvider(),
new StressMetaDataProvider(),
new PolyominoOptions(),
new DisCoMetaDataProvider(),
new SporeMetaDataProvider()
)
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.02553 seconds