+ @PropertySetter(value = "SVG")
+ public void setSVG(String value) {
+ for (INode nn : this.getNodes())
+ if (nn instanceof SVGNode)
+ ((SVGNode)nn).setData(value);
+ }
+
+
+ @PropertySetter(value = "size")
+ public void setSize(Double size) {
+ boolean changed = false;
+ if (size != null) {
+ changed = size != this.nodeSize;
+ this.nodeSize = size;
+ } else {
+ changed = this.nodeSize != 1.0;
+ this.nodeSize = 1.0;
+ }
+ if (changed)
+ updateBounds();
+ }
+
+ @PropertySetter(value = "dynamicColor")
+ public void setDynamicColor(Color color) {
+ this.dynamicColor = color;
+ }
+
+ @PropertySetter(value = "eventColor")
+ public void setEventColor(Color colorr) {
+ this.eventColor = colorr;
+ }
+
+ @PropertySetter(value = "hidden")
+ public void setHidden(Boolean value) {
+ this.hidden = value;
+ }
+
+ public void setStaticInformation(Optional<String> staticInformation) {
+ DistrictNetworkStaticInfoNode child = getOrCreateNode(DistrictNetworkStaticInfoNode.NODE_KEY, DistrictNetworkStaticInfoNode.class);
+ Point2D calculatePoint2D = DistrictNetworkNodeUtils.calculatePoint2D(vertex.getPoint(), null);
+ child.setLocation(calculatePoint2D, new Point2D.Double(1.0, 0.0));
+ if (staticInformation.isPresent()) {
+ child.setInfo(staticInformation.get());
+ } else {
+ child.setInfo(null);
+ }
+ }
+
+ public void setInSimulation(Optional<Boolean> isInSimulation) {
+ if (!isInSimulation.isPresent()) {
+ removeNode(NotInSimulationNode.NODE_NAME);
+ } else {
+ NotInSimulationNode child = getOrCreateNode(NotInSimulationNode.NODE_NAME, NotInSimulationNode.class);
+ child.setZIndex(1000);
+ child.setIsInSimulation(isInSimulation.get());
+ }
+ }
+
+ public void setConnectionLinePoints(List<Point2D> points) {
+ if (points == null) {
+ removeNode(ConnectionLineNode.NODE_NAME);
+ } else {
+ ConnectionLineNode child = getOrCreateNode(ConnectionLineNode.NODE_NAME, ConnectionLineNode.class);
+ child.setZIndex(0);
+ child.setStrokeWidth(2.f);
+ child.setPoints(points);
+ }
+ }
+