public static void LogException(String sourceClass, String sourceMethod, Exception exc) { LogException(sourceClass, sourceMethod, exc, Level.INFO, false); }
public static void LogException(String sourceClass, String sourceMethod, Exception exc, Boolean showMessageBox) { LogException(sourceClass, sourceMethod, exc, Level.INFO, showMessageBox); }
public static void LogException(String sourceClass, String sourceMethod, Exception exc, Level lvl) { LogException(sourceClass, sourceMethod, exc, lvl, false); }
public Boolean hasRenderer(String rendererID) { try { if (spRenderers != null && spRenderers.containsKey(rendererID)) return true; else return false; } catch (Exception exc) { ErrorLogger.LogException("SinglePointRendererService", "hasRenderer", exc); } return false; }
public Boolean hasRenderer(String rendererID) { try { if (spRenderers != null && spRenderers.containsKey(rendererID)) return true; else return false; } catch (Exception exc) { ErrorLogger.LogException("SinglePointRendererService", "hasRenderer", exc); } return false; }
protected static ArrayList<Point2D> POINT2toPoint2D(ArrayList<POINT2> pts) { ArrayList<Point2D> pts2d = new ArrayList(); try { for (int j = 0; j < pts.size(); j++) { pts2d.add(new Point2D.Double(pts.get(j).x, pts.get(j).y)); } } catch (Exception exc) { ErrorLogger.LogException(_className, "POINT2toPoint2D", new RendererException("Failed inside POINT2toPoint2D", exc)); } return pts2d; }
/** * @deprecated @param tg * @param fillTG */ protected static void addCircularRangeFanFillShapesFromTG(ArrayList<Shape2> tgShapes, ArrayList<Shape2> fillShapes) { try { tgShapes.addAll(0, fillShapes); } catch (Exception exc) { ErrorLogger.LogException(_className, "addCircularRangeFanFillShapesFromTG", new RendererException("Failed inside addCircularRangeFanFillShapesFromTG", exc)); } }
protected static ArrayList<Point2D> POINT2toPoint2D(ArrayList<POINT2> pts) { ArrayList<Point2D> pts2d = new ArrayList(); try { for (int j = 0; j < pts.size(); j++) { pts2d.add(new Point2D.Double(pts.get(j).x, pts.get(j).y)); } } catch (Exception exc) { ErrorLogger.LogException(_className, "POINT2toPoint2D", new RendererException("Failed inside POINT2toPoint2D", exc)); } return pts2d; }
/** * @deprecated @param tg * @param fillTG */ protected static void addCircularRangeFanFillShapesFromTG(ArrayList<Shape2> tgShapes, ArrayList<Shape2> fillShapes) { try { tgShapes.addAll(0, fillShapes); } catch (Exception exc) { ErrorLogger.LogException(_className, "addCircularRangeFanFillShapesFromTG", new RendererException("Failed inside addCircularRangeFanFillShapesFromTG", exc)); } }
public static void WriteFile(String str) { try { BufferedWriter bufferedWriter = new BufferedWriter(new FileWriter("Test.txt")); bufferedWriter.write(str); //bufferedWriter.newLine(); //bufferedWriter.write(pointType); bufferedWriter.close(); bufferedWriter = null; } catch (Exception exc) { ErrorLogger.LogException(_className, "WriteFile", new RendererException("Failed inside WriteFile", exc)); } }
public UnitFontLookupInfo getLookupInfo(String SymbolID) { try { String code = SymbolUtilities.getBasicSymbolIDStrict(SymbolID); UnitFontLookupInfo data = hashMap.get(code); return data; } catch(Exception exc) { ErrorLogger.LogException("UnitFontLookupC", "getLookupInfo()", exc, Level.WARNING); return null; } }
private SinglePointRendererService() { try { // ErrorLogger.Entering("SinglePointRendererService", // "SinglePointRendererService"); // AddRenderersToPath(); loader = ServiceLoader.load(ArmyC2.C2SD.RendererPluginInterface.ISinglePointRenderer.class); // LoadSPRendererServices(); // ErrorLogger.Exiting("SinglePointRendererService", // "SinglePointRendererService"); } catch (Exception exc) { ErrorLogger.LogException("SinglePointRendererService", "SinglePointRendererService", exc); ErrorLogger.LogMessage(exc.getMessage(), true); } }
public void AddRenderersToPathByFile(File file) { try { if (file.exists()) { if (file.getName().endsWith("jar") == true) { // System.out.println(file.toString()); addURL(file.toURI().toURL()); } } //loader.reload(); //LoadSPRendererServices(); } catch (Exception exc) { ErrorLogger.LogException("SinglePointRendererService", "AddRenderersToPathByDirectory", exc); } }
public static void WriteFile(String str) { try { BufferedWriter bufferedWriter = new BufferedWriter(new FileWriter("Test.txt")); bufferedWriter.write(str); //bufferedWriter.newLine(); //bufferedWriter.write(pointType); bufferedWriter.close(); bufferedWriter = null; } catch (Exception exc) { ErrorLogger.LogException(_className ,"WriteFile", new RendererException("Failed inside WriteFile", exc)); } }
protected static ArrayList<POINT2> Point2DtoPOINT2(ArrayList<Point2D> pts2d) { ArrayList<POINT2> pts = new ArrayList(); try { for (int j = 0; j < pts2d.size(); j++) { pts.add(new POINT2(pts2d.get(j).getX(), pts2d.get(j).getY())); } } catch (Exception exc) { ErrorLogger.LogException(_className, "Point2DToPOINT2", new RendererException("Failed inside Point2DToPOINT2", exc)); } return pts; }
protected static ArrayList<POINT2> Point2DtoPOINT2(ArrayList<Point2D> pts2d) { ArrayList<POINT2> pts = new ArrayList(); try { for (int j = 0; j < pts2d.size(); j++) { pts.add(new POINT2(pts2d.get(j).getX(), pts2d.get(j).getY())); } } catch (Exception exc) { ErrorLogger.LogException(_className, "Point2DToPOINT2", new RendererException("Failed inside Point2DToPOINT2", exc)); } return pts; }
/** * Attemps to Load a specfic file as a plugin * Call refreshPlugins() after you've loaded all the plugins you want * the service to make available. * @param file */ public void loadPluginsFromFile(File file) { try { SinglePointRendererService.getInstance().AddRenderersToPathByFile(file); // SinglePointRendererService.getInstance().LoadSPRendererServices(); } catch (Exception exc) { ErrorLogger.LogException("SECRenderer", "loadDefaultPlugins", exc); } }
/** * Scans a directory and loads any plugins located there. * Call refreshPlugins() after you've loaded all the plugins you want * the service to make available. * @param directory */ public void loadPluginsFromDirectory(File directory) { try { SinglePointRendererService.getInstance().AddRenderersToPathByDirectory(directory); //SinglePointRendererService.getInstance().LoadSPRendererServices(); } catch (Exception exc) { ErrorLogger.LogException("SECRenderer", "loadDefaultPlugins", exc); } }
/** * Will attempt to download and load a plugin given a specific url * Call refreshPlugins() after you've loaded all the plugins you want * the service to make available. * @param url */ public void loadPluginsFromUrl(String url) { try { SinglePointRendererService.getInstance().AddRenderersToPath(url); // SinglePointRendererService.getInstance().LoadSPRendererServices(); } catch (Exception exc) { ErrorLogger.LogException("SECRenderer", "loadDefaultPlugins", exc); } }
/** * Attemps to Load a specfic file as a plugin * Call refreshPlugins() after you've loaded all the plugins you want * the service to make available. * @param file */ public void loadPluginsFromFile(File file) { try { SinglePointRendererService.getInstance().AddRenderersToPathByFile(file); // SinglePointRendererService.getInstance().LoadSPRendererServices(); } catch (Exception exc) { ErrorLogger.LogException("SECRenderer", "loadDefaultPlugins", exc); } }