Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTobias Schwarz2012-10-24 11:20:39 +0000
committerTobias Schwarz2012-10-25 06:27:02 +0000
commit07b893a84d8d258bf895a2c93beac0a3d819f6c4 (patch)
tree3b094619b585f65eb2a48ee78ff656b2e210d5ec /target_explorer
parent95175a61047d316f958cc26979ed1363a1fd7dad (diff)
downloadorg.eclipse.tcf-07b893a84d8d258bf895a2c93beac0a3d819f6c4.tar.gz
org.eclipse.tcf-07b893a84d8d258bf895a2c93beac0a3d819f6c4.tar.xz
org.eclipse.tcf-07b893a84d8d258bf895a2c93beac0a3d819f6c4.zip
[Target Explorer] unify variable delegate and configure it in the
contribution directly
Diffstat (limited to 'target_explorer')
-rw-r--r--target_explorer/plugins/org.eclipse.tcf.te.runtime.persistence/src/org/eclipse/tcf/te/runtime/persistence/delegates/GsonMapPersistenceDelegate.java7
1 files changed, 5 insertions, 2 deletions
diff --git a/target_explorer/plugins/org.eclipse.tcf.te.runtime.persistence/src/org/eclipse/tcf/te/runtime/persistence/delegates/GsonMapPersistenceDelegate.java b/target_explorer/plugins/org.eclipse.tcf.te.runtime.persistence/src/org/eclipse/tcf/te/runtime/persistence/delegates/GsonMapPersistenceDelegate.java
index a9a99c064..8427fcdee 100644
--- a/target_explorer/plugins/org.eclipse.tcf.te.runtime.persistence/src/org/eclipse/tcf/te/runtime/persistence/delegates/GsonMapPersistenceDelegate.java
+++ b/target_explorer/plugins/org.eclipse.tcf.te.runtime.persistence/src/org/eclipse/tcf/te/runtime/persistence/delegates/GsonMapPersistenceDelegate.java
@@ -193,8 +193,11 @@ public class GsonMapPersistenceDelegate extends ExecutableExtension implements I
data = gson.fromJson((String)container, Map.class);
}
- if (data != null && data.containsKey(VARIABLES)) {
- Map<String,String> variables = (Map<String,String>)data.remove(VARIABLES);
+ if (data != null) {
+ Map<String,String> variables = new HashMap<String, String>();
+ if (data.containsKey(VARIABLES)) {
+ variables = (Map<String,String>)data.remove(VARIABLES);
+ }
IVariableDelegate[] delegates = PersistenceManager.getInstance().getVariableDelegates(this);
for (IVariableDelegate delegate : delegates) {
data = delegate.putVariables(data, variables);

Back to the top