Re: [JPP-Devel] SVN: [5237] core/trunk/src

2016-12-02 Thread edgar . soldin
On 01.12.2016 22:44, jump-pilot-...@lists.sourceforge.net wrote:
> Revision: 5237
>   http://sourceforge.net/p/jump-pilot/code/5237
> Author:   michaudm
> Date: 2016-12-01 21:44:25 + (Thu, 01 Dec 2016)
> Log Message:
> ---
> Revert visibility of some methods to public as they are used in some external 
> plugins

jupp, bad idea reverting method/attrib visibility. only way to "do" it, is to 
mark it deprecated and establish a different _clean_ way.

just reverting because it does not seem to be needed is a no go by now, as we 
do not know which external code might access it.

stay careful;) ..ede

--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel


[JPP-Devel] SVN: [5237] core/trunk/src

2016-12-01 Thread jump-pilot-svn
Revision: 5237
  http://sourceforge.net/p/jump-pilot/code/5237
Author:   michaudm
Date: 2016-12-01 21:44:25 + (Thu, 01 Dec 2016)
Log Message:
---
Revert visibility of some methods to public as they are used in some external 
plugins

Modified Paths:
--
core/trunk/src/com/vividsolutions/jump/io/GMLInputTemplate.java

core/trunk/src/com/vividsolutions/jump/workbench/datasource/InstallStandardDataSourceQueryChoosersPlugIn.java
core/trunk/src/org/openjump/core/ui/plugin/tools/PlanarGraphPlugIn.java

Modified: core/trunk/src/com/vividsolutions/jump/io/GMLInputTemplate.java
===
--- core/trunk/src/com/vividsolutions/jump/io/GMLInputTemplate.java 
2016-11-30 17:09:19 UTC (rev 5236)
+++ core/trunk/src/com/vividsolutions/jump/io/GMLInputTemplate.java 
2016-12-01 21:44:25 UTC (rev 5237)
@@ -102,7 +102,7 @@
  * Returns the column name for the 'index'th column.
  *@param index 0=first
  */
-String columnName(int index) throws ParseException {
+public String columnName(int index) throws ParseException {
 if (loaded) {
 return columnDefinitions.get(index).columnName;
 } else {
@@ -114,7 +114,7 @@
 /**
  * Converts this GMLInputTemplate to a feature schema.
  */
-FeatureSchema toFeatureSchema() throws ParseException {
+public FeatureSchema toFeatureSchema() throws ParseException {
 if (!(loaded)) {
 throw new ParseException(
 "requested toFeatureSchema w/o loading the template");
@@ -135,7 +135,7 @@
  * Function to help the GMLParser - is this tag name the Geometry Element 
tag name?
  *@param tag an XML tag name
  **/
-boolean isGeometryElement(String tag) {
+public boolean isGeometryElement(String tag) {
 int t;
 String s;
 
@@ -273,7 +273,7 @@
  * @param tagBody value of the XML tag body
  * @param xmlAtts key/values of the XML tag's attributes
  */
-Object getColumnValue(int index, String tagBody, Attributes xmlAtts)
+public Object getColumnValue(int index, String tagBody, Attributes xmlAtts)
 throws ParseException {
 String val;
 ColumnDescription cd;

Modified: 
core/trunk/src/com/vividsolutions/jump/workbench/datasource/InstallStandardDataSourceQueryChoosersPlugIn.java
===
--- 
core/trunk/src/com/vividsolutions/jump/workbench/datasource/InstallStandardDataSourceQueryChoosersPlugIn.java
   2016-11-30 17:09:19 UTC (rev 5236)
+++ 
core/trunk/src/com/vividsolutions/jump/workbench/datasource/InstallStandardDataSourceQueryChoosersPlugIn.java
   2016-12-01 21:44:25 UTC (rev 5237)
@@ -180,7 +180,8 @@
 StandardReaderWriterFileDataSource.GeoJSON.class);
   }
 
-  static void addCompressedFileFilter(final String description, JFileChooser 
chooser) {
+  // Should be public (used in some external plugins)
+  public static void addCompressedFileFilter(final String description, 
JFileChooser chooser) {
 chooser
 .addChoosableFileFilter(GUIUtil.createFileFilter(
 
I18N.get("datasource.InstallStandardDataSourceQueryChoosersPlugIn.compressed")

Modified: 
core/trunk/src/org/openjump/core/ui/plugin/tools/PlanarGraphPlugIn.java
===
--- core/trunk/src/org/openjump/core/ui/plugin/tools/PlanarGraphPlugIn.java 
2016-11-30 17:09:19 UTC (rev 5236)
+++ core/trunk/src/org/openjump/core/ui/plugin/tools/PlanarGraphPlugIn.java 
2016-12-01 21:44:25 UTC (rev 5237)
@@ -259,7 +259,8 @@
 // 
 // Create edge layer
 // 
-private FeatureCollection createEdgeLayer(FeatureCollection fc,
+// public (used in external plugin) TODO such public method should not be 
directly in the PlugIn
+public FeatureCollection createEdgeLayer(FeatureCollection fc,
 boolean nodeb, boolean faceb, boolean relations) {
 // Schema edge
 FeatureSchema fsEdge = new FeatureSchema();
@@ -307,7 +308,8 @@
 // 
 // Create node layer
 // 
-private FeatureCollection createNodeLayer(FeatureCollection fcEdge, 
boolean relations) {
+// public (used in external plugin) TODO such public method should not be 
directly in the PlugIn
+public FeatureCollection createNodeLayer(FeatureCollection fcEdge, boolean 
relations) {
 FeatureSchema fsNode = new FeatureSchema();
 fsNode.addAttribute("GEOMETRY", AttributeType.GEOMETRY);
 fsNode.addAttribute("ID", AttributeType.INTEGER);
@@ -345,7 +347,8 @@
 // 
 // Create face layer
 // 
-