summaryrefslogtreecommitdiffstats
path: root/ecomp-sdk/epsdk-analytics
diff options
context:
space:
mode:
authorIndrijeet kumar <indriku1@in.ibm.com>2020-05-28 01:26:37 +0530
committerIndrijeet Kumar <indriku1@in.ibm.com>2020-05-28 04:43:34 +0000
commitd8899341485869f367590e7eaab65046e44c1b8e (patch)
tree0277db594559da41b7383f72a6dfba729e8b0ee1 /ecomp-sdk/epsdk-analytics
parent273ccf87b2609ed82fe681e2211fc402f799307f (diff)
Removed unwanted codes from five components
Removed unwanted codes from five components Issue-ID: PORTAL-813 Change-Id: Ib9728a885770bcd1466a94820e37467f765d4c08 Signed-off-by: Indrijeet Kumar <indriku1@in.ibm.com>
Diffstat (limited to 'ecomp-sdk/epsdk-analytics')
-rw-r--r--ecomp-sdk/epsdk-analytics/src/main/java/org/onap/portalsdk/analytics/gmap/map/ColorProperties.java26
-rw-r--r--ecomp-sdk/epsdk-analytics/src/main/java/org/onap/portalsdk/analytics/gmap/map/GMapProperties.java2
-rw-r--r--ecomp-sdk/epsdk-analytics/src/main/java/org/onap/portalsdk/analytics/gmap/map/MapConstant.java3
-rw-r--r--ecomp-sdk/epsdk-analytics/src/main/java/org/onap/portalsdk/analytics/gmap/map/NovaMap.java4
-rw-r--r--ecomp-sdk/epsdk-analytics/src/main/java/org/onap/portalsdk/analytics/gmap/map/layer/SwingLayer.java27
5 files changed, 5 insertions, 57 deletions
diff --git a/ecomp-sdk/epsdk-analytics/src/main/java/org/onap/portalsdk/analytics/gmap/map/ColorProperties.java b/ecomp-sdk/epsdk-analytics/src/main/java/org/onap/portalsdk/analytics/gmap/map/ColorProperties.java
index 6e1d7e24..225fa9ea 100644
--- a/ecomp-sdk/epsdk-analytics/src/main/java/org/onap/portalsdk/analytics/gmap/map/ColorProperties.java
+++ b/ecomp-sdk/epsdk-analytics/src/main/java/org/onap/portalsdk/analytics/gmap/map/ColorProperties.java
@@ -55,38 +55,12 @@ public class ColorProperties {
}
public void setColor(String type, String color) {
- //colorProperties.put(type + "_COLOR", color);
String[] rgb = color.split(",");
colorProperties.put(type + "_COLOR",
new Color(Integer.parseInt(rgb[0]), Integer.parseInt(rgb[1]),
Integer.parseInt(rgb[2])));
}
-// public void setColor(String type, int number, String color) {
-// Object object = colorProperties.get(type + ":" + number + "_COLOR");
-//
-// if (object != null) {
-// Color oldColor = (Color) object;
-//
-// if (!color.equals(oldColor.getRed() + "," + oldColor.getGreen() + "," + oldColor.getBlue())) {
-// String[] rgb = color.split(",");
-// colorProperties.put(type + ":" + number + "_COLOR",
-// new Color(Integer.parseInt(rgb[0]), Integer.parseInt(rgb[1]),
-// Integer.parseInt(rgb[2])));
-// }
-// }
-// else {
-// String[] rgb = color.split(",");
-// colorProperties.put(type + ":" + number + "_COLOR",
-// new Color(Integer.parseInt(rgb[0]), Integer.parseInt(rgb[1]),
-// Integer.parseInt(rgb[2])));
-// }
-// }
-
-// public Color getColor(String type, int number) {
-// return (Color) colorProperties.get(type + ":" + number + "_COLOR");
-// }
-
public Color getColor(String type) {
return (Color) colorProperties.get(type + "_COLOR");
}
diff --git a/ecomp-sdk/epsdk-analytics/src/main/java/org/onap/portalsdk/analytics/gmap/map/GMapProperties.java b/ecomp-sdk/epsdk-analytics/src/main/java/org/onap/portalsdk/analytics/gmap/map/GMapProperties.java
index 6954f635..ba2a41be 100644
--- a/ecomp-sdk/epsdk-analytics/src/main/java/org/onap/portalsdk/analytics/gmap/map/GMapProperties.java
+++ b/ecomp-sdk/epsdk-analytics/src/main/java/org/onap/portalsdk/analytics/gmap/map/GMapProperties.java
@@ -40,7 +40,7 @@ package org.onap.portalsdk.analytics.gmap.map;
import org.onap.portalsdk.analytics.system.Globals;
public class GMapProperties {
-
+
public static String getProjectFolder() {
return Globals.getProjectFolder();
}
diff --git a/ecomp-sdk/epsdk-analytics/src/main/java/org/onap/portalsdk/analytics/gmap/map/MapConstant.java b/ecomp-sdk/epsdk-analytics/src/main/java/org/onap/portalsdk/analytics/gmap/map/MapConstant.java
index bcbdb8e2..ccd1e2f2 100644
--- a/ecomp-sdk/epsdk-analytics/src/main/java/org/onap/portalsdk/analytics/gmap/map/MapConstant.java
+++ b/ecomp-sdk/epsdk-analytics/src/main/java/org/onap/portalsdk/analytics/gmap/map/MapConstant.java
@@ -38,7 +38,8 @@
package org.onap.portalsdk.analytics.gmap.map;
public class MapConstant {
- public static final String CURSOR = "CURSOR";
+
+ public static final String CURSOR = "CURSOR";
public static final String FILLED_TRIANGLE = "FILLED TRIANGLE";
public static final String FILLED_SQUARE = "FILLED SQUARE";
public static final String FILLED_CIRCLE = "FILLED CIRCLE";
diff --git a/ecomp-sdk/epsdk-analytics/src/main/java/org/onap/portalsdk/analytics/gmap/map/NovaMap.java b/ecomp-sdk/epsdk-analytics/src/main/java/org/onap/portalsdk/analytics/gmap/map/NovaMap.java
index 6473bc6f..794acead 100644
--- a/ecomp-sdk/epsdk-analytics/src/main/java/org/onap/portalsdk/analytics/gmap/map/NovaMap.java
+++ b/ecomp-sdk/epsdk-analytics/src/main/java/org/onap/portalsdk/analytics/gmap/map/NovaMap.java
@@ -166,9 +166,6 @@ public class NovaMap {
;
}
- // && (1200*meter2pixel[zoom]) > Wmeter
- // && (700*meter2pixel[zoom]) > Hmeter;
-
return zoom + MapConstant.ZOOM_MIN - 1;
}
@@ -411,7 +408,6 @@ public class NovaMap {
}
ArrayList imageArr = new ArrayList();
- // if(showLegend) layer.paintLegend(g2Legend);
g2d.dispose();
if (showLegend && g2Legend != null)
diff --git a/ecomp-sdk/epsdk-analytics/src/main/java/org/onap/portalsdk/analytics/gmap/map/layer/SwingLayer.java b/ecomp-sdk/epsdk-analytics/src/main/java/org/onap/portalsdk/analytics/gmap/map/layer/SwingLayer.java
index ae6237ca..6473c8d0 100644
--- a/ecomp-sdk/epsdk-analytics/src/main/java/org/onap/portalsdk/analytics/gmap/map/layer/SwingLayer.java
+++ b/ecomp-sdk/epsdk-analytics/src/main/java/org/onap/portalsdk/analytics/gmap/map/layer/SwingLayer.java
@@ -108,7 +108,6 @@ public class SwingLayer {
System.out.println("swing layer interrupted");
return false;
}
- //System.out.println("%%%%%%%getImage. no of T1%%%%%%" + nodeInfo.getAttribute("x_sequence"));
point = map.getPixelPos(nodeInfo.geoCoordinate.latitude, nodeInfo.geoCoordinate.longitude);
@@ -175,30 +174,19 @@ public class SwingLayer {
g2d.setColor(Color.BLACK);
g2d.drawString("M", shape.x + width2 / 2, shape.y);
}
-
-// if (map.containsShowLabelList(nodeInfo.getNodeType())) {
-// g2d.setColor(Color.BLACK);
-// FontMetrics metrics = g2d.getFontMetrics();
-// int x = shape.x - metrics.stringWidth(nodeInfo.getID()) / 2;
-// int y = shape.y + width2 * 4 / 3;
-// g2d.drawString(nodeInfo.getID(), x, y);
-// }
}
String legendName = "";
int baseY = 0;
- baseY = (20*showListArr.length) + 20;//+5;
+ baseY = (20*showListArr.length) + 20;
int baseX = 0;
if(map.isShowLegend()) {
for (int i = showListArr.length-1; i>=0; i--) {
legendName = (String)showListArr[i];
- //for(int i = 0; i < showListArr.length; i++ ) {
if(i == showListArr.length-1){
textWidth = (textWidth<="Legend".length())?"Legend".length():textWidth;
g2Legend.setColor(Color.WHITE);
- //g2d.draw(new Rectangle2D.Double((int) bounds.getMaxX()*0.1, (int) bounds.getMaxY()*0.75*showListArr.length, (int) bounds.getMaxX()*0.75, (int) bounds.getMaxY()*0.75));
- g2Legend.fill3DRect((int)(0), (int)(0), (int) bounds.getWidth() , (int)(baseY) , true); // (int)(bounds.getMaxX()*0.9)- (int)(bounds.getMaxX()*0.25)
- //if(i == 0){
+ g2Legend.fill3DRect((int)(0), (int)(0), (int) bounds.getWidth() , (int)(baseY) , true);
g2Legend.setColor(Color.BLACK);
g2Legend.setFont(NovaMap.HEADER_FONT);
g2Legend.drawString("Legend", (int) (10), 10);
@@ -214,15 +202,6 @@ public class SwingLayer {
}
}
-/* g2d.drawString("0", (int) bounds.getMaxX()/2+20 + width+10, 0);
- g2d.drawString("50", (int) bounds.getMaxX()/2+20 + width+10, 50);
- g2d.drawString("100", (int) bounds.getMaxX()/2+20 + width+10, 100);
- g2d.drawString("200", (int) bounds.getMaxX()/2+20 + width+10, 200);
- g2d.drawString("400", (int) bounds.getMaxX()/2+20 + width+10, 400);
- g2d.drawString("600", (int) bounds.getMaxX()/2+20 + width+10, 600);
-*/
-// g2d.setFont(NovaMap.TEXT_FONT);
-// g2d.setColor(Color.BLACK);
if(nvl(map.getDataLoaded()).trim().length() > 0) {
g2d.setColor(Color.WHITE);
g2d.fill3DRect(new Double(bounds.getMinX()).intValue(), new Double(bounds.getMaxY()).intValue()-30, (int) bounds.getWidth() , (int)(30) , true); // (int)(bounds.getMaxX()*0.9)- (int)(bounds.getMaxX()*0.25)
@@ -230,8 +209,6 @@ public class SwingLayer {
g2d.setFont(NovaMap.HEADER_FONT);
g2d.drawString(Globals.getUserDefinedMessageForMemoryLimitReached() + " "+ map.getDataLoaded()+ " were downloaded to Map.", new Double(bounds.getMinX()).intValue()+80, new Double(bounds.getMaxY()).intValue()-15);
}
-
- //g2d.drawString("Hello", new Double(bounds.getMinX()).intValue()+20, new Double(bounds.getMaxY()).intValue()-50);
FontMetrics metrics = g2d.getFontMetrics();
for (int i = 0; i < visibleLabel.size(); i++) {