From e6404d0d1ce814a310d6f0d3cda649c7cd02b7f8 Mon Sep 17 00:00:00 2001 From: Niklas Rentz Date: Thu, 14 Mar 2024 17:34:30 +0100 Subject: [PATCH] kgraph: skip parsing unparsable layout options --- .../cs/kieler/klighd/kgraph/util/KGraphDataUtil.java | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/plugins/de.cau.cs.kieler.klighd.kgraph/src/de/cau/cs/kieler/klighd/kgraph/util/KGraphDataUtil.java b/plugins/de.cau.cs.kieler.klighd.kgraph/src/de/cau/cs/kieler/klighd/kgraph/util/KGraphDataUtil.java index 9fb16c27b..3e7127e3e 100644 --- a/plugins/de.cau.cs.kieler.klighd.kgraph/src/de/cau/cs/kieler/klighd/kgraph/util/KGraphDataUtil.java +++ b/plugins/de.cau.cs.kieler.klighd.kgraph/src/de/cau/cs/kieler/klighd/kgraph/util/KGraphDataUtil.java @@ -299,9 +299,13 @@ public static void loadDataElement(final LayoutMetaDataService dataService, // if we have a valid layout option, parse its value. if (layoutOptionData != null) { - Object layoutOptionValue = layoutOptionData.parseValue(value); - if (layoutOptionValue != null) { - propertyHolder.setProperty(layoutOptionData, layoutOptionValue); + try { + Object layoutOptionValue = layoutOptionData.parseValue(value); + if (layoutOptionValue != null) { + propertyHolder.setProperty(layoutOptionData, layoutOptionValue); + } + } catch (IllegalStateException e) { + // Some options cannot be parsed, skip these. } } else {