org.simantics.layer0;bundle-version="1.0.0"
Bundle-RequiredExecutionEnvironment: JavaSE-1.6
Bundle-ActivationPolicy: lazy
-Export-Package: org.simantics.interop.issues
+Export-Package: org.simantics.interop.issues,
+ org.simantics.interop.stubs
INTEROP = <http://www.simantics.org/Interop-1.0> : L0.Ontology\r
L0.HasResourceClass "org.simantics.interop.stubs.InteropResource"\r
@L0.new\r
- \r
-//INTEROP.InteropFeature : PROJ.Feature\r
-// L0.HasDescription "Interop feature."\r
\r
\r
-INTEROP.ImportLibrary <T L0.Library
\ No newline at end of file
+INTEROP.ImportLibrary <T L0.Library\r
+\r
+INTEROP.HasSource <R L0.IsWeaklyRelatedTo\r
+ L0.InverseOf INTEROP.HasDestination <R L0.IsWeaklyRelatedTo\r
Display.getDefault().asyncExec(new Runnable() {\r
@Override\r
public void run() {\r
- for (IssueListener l : listeners) {\r
- l.updated(AbstractIssue.this);\r
+ synchronized (listeners) {\r
+ for (IssueListener l : listeners) {\r
+ l.updated(AbstractIssue.this);\r
+ } \r
}\r
+ \r
}\r
});\r
}\r
for (IssueListener l : list) {\r
l.disposed(AbstractIssue.this);\r
}\r
+ listeners.clear();\r
}\r
});\r
}\r
\r
@Override\r
public void addListener(IssueListener listener) {\r
- listeners.add(listener);\r
+ synchronized(listeners) {\r
+ listeners.add(listener);\r
+ }\r
}\r
\r
@Override\r
public void removeListener(IssueListener listener) {\r
- listeners.remove(listener);\r
+ synchronized(listeners) {\r
+ listeners.remove(listener);\r
+ }\r
}\r
\r
@Override\r
-/*******************************************************************************\r
- * Copyright (c) 2007, 2010 Association for Decentralized Information Management\r
- * in Industry THTH ry.\r
- * All rights reserved. This program and the accompanying materials\r
- * are made available under the terms of the Eclipse Public License v1.0\r
- * which accompanies this distribution, and is available at\r
- * http://www.eclipse.org/legal/epl-v10.html\r
- *\r
- * Contributors:\r
- * VTT Technical Research Centre of Finland - initial API and implementation\r
- *******************************************************************************/\r
package org.simantics.interop.stubs;\r
\r
import org.simantics.db.Resource;\r
\r
public class InteropResource {\r
\r
+ public final Resource HasDestination;\r
+ public final Resource HasSource;\r
public final Resource ImportLibrary;\r
\r
public static class URIs {\r
+ public static final String HasDestination = "http://www.simantics.org/Interop-1.0/HasDestination";\r
+ public static final String HasSource = "http://www.simantics.org/Interop-1.0/HasSource";\r
public static final String ImportLibrary = "http://www.simantics.org/Interop-1.0/ImportLibrary";\r
}\r
\r
}\r
\r
public InteropResource(ReadGraph graph) {\r
+ HasDestination = getResourceOrNull(graph, URIs.HasDestination);\r
+ HasSource = getResourceOrNull(graph, URIs.HasSource);\r
ImportLibrary = getResourceOrNull(graph, URIs.ImportLibrary);\r
}\r
\r