refs #6958
Change-Id: I55cd490238b75fede3e0b90dcf720cb28c23433f
public void init() {
try {
public void init() {
try {
- ITileProvider provider = new OSMTileProvider(new WebService("http://localhost:8080/osm-bright/"), TILE_PIXEL_SIZE);
+ ITileProvider provider = new OSMTileProvider(new WebService("http://localhost:8080/mapbox-studio-osm-bright.tm2/"), TILE_PIXEL_SIZE);
// Try to load eclipse specific implementation of TileJobQueue, if it doesn't exist, fall back to pojo implementation
try {
// Try to load eclipse specific implementation of TileJobQueue, if it doesn't exist, fall back to pojo implementation
try {
DN.Connection <T DIA.Connection
DN.Connection <T DIA.Connection
+DN.Diagram.MappedDiagram <R L0.IsWeaklyRelatedTo
+DN.MappedComponent <R L0.IsWeaklyRelatedTo
+
DN.Diagram <T DIA.Diagram
DN.AddLayerToDNDiagramTemplate <T L0.Template
DN.Diagram <T DIA.Diagram
DN.AddLayerToDNDiagramTemplate <T L0.Template
public final Resource Composite;
public final Resource Connection;
public final Resource Diagram;
public final Resource Composite;
public final Resource Connection;
public final Resource Diagram;
+ public final Resource Diagram_MappedDiagram;
public final Resource EPSG_4326;
public final Resource Edge;
public final Resource EdgeDefaultMapping;
public final Resource EPSG_4326;
public final Resource Edge;
public final Resource EdgeDefaultMapping;
public final Resource Images_ConfigurationFolder;
public final Resource InLayer;
public final Resource Layer;
public final Resource Images_ConfigurationFolder;
public final Resource InLayer;
public final Resource Layer;
+ public final Resource MappedComponent;
public final Resource Mapping;
public final Resource MappingParameterType;
public final Resource Mapping_Base;
public final Resource Mapping;
public final Resource MappingParameterType;
public final Resource Mapping_Base;
public static final String Composite = "http://www.simantics.org/DistrictNetwork-1.0/Composite";
public static final String Connection = "http://www.simantics.org/DistrictNetwork-1.0/Connection";
public static final String Diagram = "http://www.simantics.org/DistrictNetwork-1.0/Diagram";
public static final String Composite = "http://www.simantics.org/DistrictNetwork-1.0/Composite";
public static final String Connection = "http://www.simantics.org/DistrictNetwork-1.0/Connection";
public static final String Diagram = "http://www.simantics.org/DistrictNetwork-1.0/Diagram";
+ public static final String Diagram_MappedDiagram = "http://www.simantics.org/DistrictNetwork-1.0/Diagram/MappedDiagram";
public static final String EPSG_4326 = "http://www.simantics.org/DistrictNetwork-1.0/EPSG_4326";
public static final String Edge = "http://www.simantics.org/DistrictNetwork-1.0/Edge";
public static final String EdgeDefaultMapping = "http://www.simantics.org/DistrictNetwork-1.0/EdgeDefaultMapping";
public static final String EPSG_4326 = "http://www.simantics.org/DistrictNetwork-1.0/EPSG_4326";
public static final String Edge = "http://www.simantics.org/DistrictNetwork-1.0/Edge";
public static final String EdgeDefaultMapping = "http://www.simantics.org/DistrictNetwork-1.0/EdgeDefaultMapping";
public static final String Images_ConfigurationFolder = "http://www.simantics.org/DistrictNetwork-1.0/Images/ConfigurationFolder";
public static final String InLayer = "http://www.simantics.org/DistrictNetwork-1.0/InLayer";
public static final String Layer = "http://www.simantics.org/DistrictNetwork-1.0/Layer";
public static final String Images_ConfigurationFolder = "http://www.simantics.org/DistrictNetwork-1.0/Images/ConfigurationFolder";
public static final String InLayer = "http://www.simantics.org/DistrictNetwork-1.0/InLayer";
public static final String Layer = "http://www.simantics.org/DistrictNetwork-1.0/Layer";
+ public static final String MappedComponent = "http://www.simantics.org/DistrictNetwork-1.0/MappedComponent";
public static final String Mapping = "http://www.simantics.org/DistrictNetwork-1.0/Mapping";
public static final String MappingParameterType = "http://www.simantics.org/DistrictNetwork-1.0/MappingParameterType";
public static final String Mapping_Base = "http://www.simantics.org/DistrictNetwork-1.0/Mapping/Base";
public static final String Mapping = "http://www.simantics.org/DistrictNetwork-1.0/Mapping";
public static final String MappingParameterType = "http://www.simantics.org/DistrictNetwork-1.0/MappingParameterType";
public static final String Mapping_Base = "http://www.simantics.org/DistrictNetwork-1.0/Mapping/Base";
Composite = getResourceOrNull(graph, URIs.Composite);
Connection = getResourceOrNull(graph, URIs.Connection);
Diagram = getResourceOrNull(graph, URIs.Diagram);
Composite = getResourceOrNull(graph, URIs.Composite);
Connection = getResourceOrNull(graph, URIs.Connection);
Diagram = getResourceOrNull(graph, URIs.Diagram);
+ Diagram_MappedDiagram = getResourceOrNull(graph, URIs.Diagram_MappedDiagram);
EPSG_4326 = getResourceOrNull(graph, URIs.EPSG_4326);
Edge = getResourceOrNull(graph, URIs.Edge);
EdgeDefaultMapping = getResourceOrNull(graph, URIs.EdgeDefaultMapping);
EPSG_4326 = getResourceOrNull(graph, URIs.EPSG_4326);
Edge = getResourceOrNull(graph, URIs.Edge);
EdgeDefaultMapping = getResourceOrNull(graph, URIs.EdgeDefaultMapping);
Images_ConfigurationFolder = getResourceOrNull(graph, URIs.Images_ConfigurationFolder);
InLayer = getResourceOrNull(graph, URIs.InLayer);
Layer = getResourceOrNull(graph, URIs.Layer);
Images_ConfigurationFolder = getResourceOrNull(graph, URIs.Images_ConfigurationFolder);
InLayer = getResourceOrNull(graph, URIs.InLayer);
Layer = getResourceOrNull(graph, URIs.Layer);
+ MappedComponent = getResourceOrNull(graph, URIs.MappedComponent);
Mapping = getResourceOrNull(graph, URIs.Mapping);
MappingParameterType = getResourceOrNull(graph, URIs.MappingParameterType);
Mapping_Base = getResourceOrNull(graph, URIs.Mapping_Base);
Mapping = getResourceOrNull(graph, URIs.Mapping);
MappingParameterType = getResourceOrNull(graph, URIs.MappingParameterType);
Mapping_Base = getResourceOrNull(graph, URIs.Mapping_Base);
<fragments xsi:type="fragment:StringModelFragment" xmi:id="_Rf7koN16Eea73Pr1j_7O0Q" featurename="trimContributions" parentElementId="xpath:/">
<elements xsi:type="menu:TrimContribution" xmi:id="_c57iwN16Eea73Pr1j_7O0Q" elementId="org.simantics.district.network.ui.trimcontribution.0" parentId="org.eclipse.ui.main.toolbar">
<children xsi:type="menu:ToolBar" xmi:id="_vdgLoN16Eea73Pr1j_7O0Q" elementId="org.simantics.district.network.ui.toolbar.0">
<fragments xsi:type="fragment:StringModelFragment" xmi:id="_Rf7koN16Eea73Pr1j_7O0Q" featurename="trimContributions" parentElementId="xpath:/">
<elements xsi:type="menu:TrimContribution" xmi:id="_c57iwN16Eea73Pr1j_7O0Q" elementId="org.simantics.district.network.ui.trimcontribution.0" parentId="org.eclipse.ui.main.toolbar">
<children xsi:type="menu:ToolBar" xmi:id="_vdgLoN16Eea73Pr1j_7O0Q" elementId="org.simantics.district.network.ui.toolbar.0">
- <children xsi:type="menu:HandledToolItem" xmi:id="_v99NUN16Eea73Pr1j_7O0Q" elementId="org.simantics.district.network.ui.handledtoolitem.domapping" label="Do mapping" tooltip="testtsts" command="_zhiBwN16Eea73Pr1j_7O0Q"/>
+ <children xsi:type="menu:HandledToolItem" xmi:id="_v99NUN16Eea73Pr1j_7O0Q" elementId="org.simantics.district.network.ui.handledtoolitem.domapping" label="Map network ontology" iconURI="platform:/plugin/org.simantics.district.network.ui/icons/map_go.png" tooltip="Map network ontology to simulator specific model" command="_zhiBwN16Eea73Pr1j_7O0Q"/>
</children>
</elements>
</fragments>
</children>
</elements>
</fragments>
import org.simantics.db.Session;
import org.simantics.db.WriteGraph;
import org.simantics.db.common.request.IndexRoot;
import org.simantics.db.Session;
import org.simantics.db.WriteGraph;
import org.simantics.db.common.request.IndexRoot;
+import org.simantics.db.common.request.ObjectsWithType;
import org.simantics.db.common.request.ReadRequest;
import org.simantics.db.common.request.WriteRequest;
import org.simantics.db.exception.DatabaseException;
import org.simantics.db.common.request.ReadRequest;
import org.simantics.db.common.request.WriteRequest;
import org.simantics.db.exception.DatabaseException;
import org.simantics.db.layer0.variable.Variable;
import org.simantics.db.layer0.variable.Variables.Role;
import org.simantics.db.procedure.Procedure;
import org.simantics.db.layer0.variable.Variable;
import org.simantics.db.layer0.variable.Variables.Role;
import org.simantics.db.procedure.Procedure;
+import org.simantics.diagram.stubs.DiagramResource;
import org.simantics.district.network.ontology.DistrictNetworkResource;
import org.simantics.layer0.Layer0;
import org.simantics.modeling.ModelingResources;
import org.simantics.district.network.ontology.DistrictNetworkResource;
import org.simantics.layer0.Layer0;
import org.simantics.modeling.ModelingResources;
}
protected Map<String, Resource> getComposites(ReadGraph graph, Resource element) throws DatabaseException {
}
protected Map<String, Resource> getComposites(ReadGraph graph, Resource element) throws DatabaseException {
Resource indexRoot = graph.sync(new IndexRoot(element));
Resource indexRoot = graph.sync(new IndexRoot(element));
- List<Resource> composites = ModelingUtils.searchByType(graph, indexRoot, StructuralResource2.getInstance(graph).Composite);
- List<Resource> nonDistrictComposites = composites.stream().filter(comp -> {
+ List<Resource> diagrams = ModelingUtils.searchByType(graph, indexRoot, DiagramResource.getInstance(graph).Diagram);
+
+ List<Resource> nonDistrictComposites = composites.values().stream().filter(comp -> {
try {
return !graph.isInstanceOf(comp, DistrictNetworkResource.getInstance(graph).Composite);
} catch (ServiceException e1) {
try {
return !graph.isInstanceOf(comp, DistrictNetworkResource.getInstance(graph).Composite);
} catch (ServiceException e1) {
String name = graph.getRelatedValue2(mapping, L0.HasName);
result.put(name, mapping);
} catch (DatabaseException e) {
String name = graph.getRelatedValue2(mapping, L0.HasName);
result.put(name, mapping);
} catch (DatabaseException e) {
+ LOGGER.error("Could not read name of " + mapping, e);
version="0.0.0"
unpack="false"/>
version="0.0.0"
unpack="false"/>
+ <plugin
+ id="org.simantics.maps.server.ui"
+ download-size="0"
+ install-size="0"
+ version="0.0.0"
+ unpack="false"/>
+