Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/buildNumber.properties
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/buildNumber.properties	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/buildNumber.properties	(revision 950)
@@ -0,0 +1,2 @@
+#Sun Jul 09 19:00:06 CEST 2023
+buildNumber=176

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/test/resources
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/test/java
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/test
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath


Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/assembly/gvsig-plugin-package.xml
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/assembly/gvsig-plugin-package.xml	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/assembly/gvsig-plugin-package.xml	(revision 950)
@@ -0,0 +1,52 @@
+<!-- gvSIG. Desktop Geographic Information System. Copyright (C) 2007-2013 gvSIG
+  Association. This program is free software; you can redistribute it and/or modify
+  it under the terms of the GNU General Public License as published by the Free Software
+  Foundation; either version 3 of the License, or (at your option) any later version.
+  This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
+  without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
+  PURPOSE. See the GNU General Public License for more details. You should have received
+  a copy of the GNU General Public License along with this program; if not, write to
+  the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
+  USA. For any additional information, do not hesitate to contact us at info AT gvsig.com,
+  or visit our website www.gvsig.com. -->
+<assembly>
+  <id>gvsig-plugin-package</id>
+  <formats>
+    <format>zip</format>
+  </formats>
+  <baseDirectory>${project.artifactId}</baseDirectory>
+  <includeBaseDirectory>true</includeBaseDirectory>
+  <files>
+    <file>
+      <source>target/${project.artifactId}-${project.version}.jar</source>
+      <outputDirectory>lib</outputDirectory>
+    </file>
+    <file>
+      <source>target/package.info</source>
+    </file>
+  </files>
+
+  <fileSets>
+    <fileSet>
+      <directory>src/main/resources-plugin</directory>
+      <outputDirectory>.</outputDirectory>
+    </fileSet>
+  </fileSets>
+
+
+  <dependencySets>
+    <dependencySet>
+      <useProjectArtifact>false</useProjectArtifact>
+      <useTransitiveDependencies>false</useTransitiveDependencies>
+      <outputDirectory>lib</outputDirectory>
+      <includes>
+        <include>org.gvsig:org.gvsig.lrs.lib.api</include>
+        <include>org.gvsig:org.gvsig.lrs.lib.impl</include>
+        <include>org.gvsig:org.gvsig.lrs.swing.api</include>
+        <include>org.gvsig:org.gvsig.lrs.swing.impl</include>
+      </includes>
+    </dependencySet>
+  </dependencySets>
+
+</assembly>
+

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/assembly
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath


Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig/lrs/app/createroute/CreateRouteExtension.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig/lrs/app/createroute/CreateRouteExtension.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig/lrs/app/createroute/CreateRouteExtension.java	(revision 950)
@@ -0,0 +1,244 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.app.createroute;
+
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+
+import javax.swing.JOptionPane;
+
+import org.apache.commons.lang3.StringUtils;
+import org.bouncycastle.util.Store;
+import org.cresques.cts.IProjection;
+import org.gvsig.andami.IconThemeHelper;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.app.ApplicationLocator;
+import org.gvsig.app.ApplicationManager;
+import org.gvsig.app.project.documents.view.ViewDocument;
+import org.gvsig.app.project.documents.view.gui.IView;
+import org.gvsig.fmap.dal.DALLocator;
+import org.gvsig.fmap.dal.DataManager;
+import org.gvsig.fmap.dal.DataStore;
+import org.gvsig.fmap.dal.DataStoreParameters;
+import org.gvsig.fmap.dal.exception.InitializeException;
+import org.gvsig.fmap.dal.exception.ProviderNotRegisteredException;
+import org.gvsig.fmap.dal.exception.ReadException;
+import org.gvsig.fmap.dal.exception.ValidateDataParametersException;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.store.shp.SHPNewStoreParameters;
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.geom.type.GeometryType;
+import org.gvsig.fmap.mapcontext.MapContextLocator;
+import org.gvsig.fmap.mapcontext.MapContextManager;
+import org.gvsig.fmap.mapcontext.exceptions.LoadLayerException;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.lrs.lib.api.LrsAlgorithm;
+import org.gvsig.lrs.lib.api.LrsAlgorithmsLocator;
+import org.gvsig.lrs.lib.api.LrsAlgorithmsManager;
+import org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams;
+import org.gvsig.lrs.lib.api.exceptions.LrsGettingParametersException;
+import org.gvsig.lrs.lib.api.exceptions.LrsNeededParameterException;
+import org.gvsig.lrs.swing.api.JLrsAlgorithmParams;
+import org.gvsig.lrs.swing.api.JLrsProgressDialog;
+import org.gvsig.lrs.swing.api.LrsAlgorithmsSwingLocator;
+import org.gvsig.lrs.swing.api.LrsAlgorithmsSwingManager;
+import org.gvsig.lrs.swing.impl.JLrsCreateRouteParamsController;
+import org.gvsig.lrs.swing.impl.JLrsUtils;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.i18n.I18nManager;
+import org.gvsig.tools.swing.api.ToolsSwingLocator;
+import org.gvsig.tools.swing.api.windowmanager.WindowManager;
+import org.gvsig.tools.task.SimpleTaskStatus;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+
+/**
+ * @author fdiaz
+ *
+ */
+public class CreateRouteExtension extends Extension {
+
+    private static final Logger logger = LoggerFactory.getLogger(CreateRouteExtension.class);
+
+    /* (non-Javadoc)
+     * @see org.gvsig.andami.plugins.IExtension#execute(java.lang.String)
+     */
+    public void execute(String actionCommand) {
+        if (StringUtils.equalsIgnoreCase(actionCommand, "create-routes")) {
+            IView view = getActiveView();
+            FLayers layers = view.getMapControl().getMapContext().getLayers();
+
+            final WindowManager winManager = ToolsSwingLocator.getWindowManager();
+
+            final LrsAlgorithmsSwingManager manager = LrsAlgorithmsSwingLocator.getLrsAlgorithmsSwingManager();
+
+            final I18nManager i18nManager = ToolsLocator.getI18nManager();
+
+            JLrsCreateRouteParamsController panel;
+            try {
+                panel = (JLrsCreateRouteParamsController)manager.createJLrsCreateRouteAlgorithmParameters(layers, null);
+            } catch (LrsNeededParameterException e2) {
+                logger.error("Error creating panel", e2);
+                JOptionPane.showMessageDialog(
+                    null,
+                    new StringBuilder().append(i18nManager.getTranslation("error_creating_panel"))
+                        .append(":").append(e2.getLocalizedMessage()),
+                    i18nManager.getTranslation("error"), JOptionPane.ERROR_MESSAGE);
+                return;
+            }
+            panel.setVisibleAceptCancel(true);
+            panel.addActionListener(new ActionListener() {
+
+                public void actionPerformed(ActionEvent e) {
+                    JLrsAlgorithmParams panel = (JLrsAlgorithmParams) e.getSource();
+                    if (panel.isCanceled()) {
+                        return;
+                    }
+                    LrsCreateRouteAlgorithmParams params = null;
+                    try {
+                        params = (LrsCreateRouteAlgorithmParams)panel.getParams();
+                    } catch (LrsGettingParametersException e1) {
+                        logger.error("Error getting parameters", e1);
+                        JOptionPane.showMessageDialog(
+                            null,
+                            new StringBuilder().append(i18nManager.getTranslation("error_getting_parameters"))
+                                .append(":").append(e1.getLocalizedMessage()),
+                            i18nManager.getTranslation("error"), JOptionPane.ERROR_MESSAGE);
+                        return;
+                    } catch (LrsNeededParameterException e1) {
+                        logger.warn("Error getting parameters", e1);
+                        JOptionPane.showMessageDialog(
+                            null,
+                            i18nManager.getTranslation(e1.getMessage()),
+                            i18nManager.getTranslation("warning"), JOptionPane.WARNING_MESSAGE);
+                        return;
+                    }
+                    LrsAlgorithmsManager algorithmsManager = LrsAlgorithmsLocator.getLrsAlgorithmsManager();
+                    final LrsAlgorithm algorithm = algorithmsManager.createLrsAlgorithm(params);
+                    final SHPNewStoreParameters shpParams=(SHPNewStoreParameters)params.getNewFeatureStoreParameters();
+
+                    final SimpleTaskStatus taskStatus =
+                        ToolsLocator.getTaskStatusManager().createDefaultSimpleTaskStatus(i18nManager.getTranslation("progress"));
+
+                    final JLrsProgressDialog progressDialog = manager.createJLrsProgressDialog(taskStatus);
+
+                    winManager.showWindow(progressDialog.asJComponent(), i18nManager.getTranslation("create_routes"),
+                        WindowManager.MODE.WINDOW);
+
+                    Thread task = new Thread(new Runnable() {
+
+                        public void run() {
+                            try {
+                                algorithm.execute(taskStatus);
+                                int resultLoadLayer =JOptionPane.showConfirmDialog(
+                                    null,
+                                    i18nManager.getTranslation("load_layer_question"),
+                                    i18nManager.getTranslation("load_layer_question_title"), JOptionPane.YES_NO_OPTION);
+                                if (resultLoadLayer==JOptionPane.YES_OPTION){
+                                    loadLayer(shpParams);
+                                }
+                            } catch (Exception e) {
+                                logger.error("Error creating routes", e);
+                                String message = e.getMessage();
+                                if (e.getCause() != null) {
+                                    message = e.getCause().getMessage();
+                                }
+                                JOptionPane.showMessageDialog(
+                                    progressDialog.asJComponent(),
+                                    message,
+                                    i18nManager.getTranslation("create_routes"),
+                                    JOptionPane.ERROR_MESSAGE
+                                );
+                            }
+                        }
+                    });
+                    task.start();
+                }
+            });
+            winManager.showWindow(panel.asJComponent(), i18nManager.getTranslation("create_routes"),
+                WindowManager.MODE.WINDOW);
+        }
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.andami.plugins.IExtension#initialize()
+     */
+    public void initialize() {
+        registerIcons();
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.andami.plugins.IExtension#isEnabled()
+     */
+    public boolean isEnabled() {
+        IView view = getActiveView();
+        if (view!=null){
+            FLayers layers = view.getMapControl().getMapContext().getLayers();
+            return JLrsUtils.validateOneCurveLyrOneNonGeomField(layers);
+        }else return false;
+
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.andami.plugins.IExtension#isVisible()
+     */
+    public boolean isVisible() {
+        ApplicationManager application = ApplicationLocator.getManager();
+
+        return application.getActiveComponent(ViewDocument.class) != null;
+    }
+
+    private void registerIcons() {
+        IconThemeHelper.registerIcon("lrs", "pk_red", this);
+        IconThemeHelper.registerIcon("lrs", "pk_m", this);
+    }
+
+
+    private IView getActiveView() {
+        ApplicationManager application = ApplicationLocator.getManager();
+        IView view = (IView) application.getActiveComponent(ViewDocument.class);
+        return view;
+    }
+
+    private void loadLayer(SHPNewStoreParameters shpParams){
+        if (shpParams!=null ){
+            String name=shpParams.getFile().getName();
+            if (name.contains(".shp")){
+                name=name.substring(0,name.lastIndexOf(".shp"));
+            }
+            MapContextManager mapContextManager =MapContextLocator.getMapContextManager();
+
+            FLyrVect newLayer=null;
+            try {
+                newLayer = (FLyrVect) mapContextManager.createLayer(name,shpParams);
+            } catch (LoadLayerException e) {
+                logger.warn("Couldn't load layer",e);
+            }
+            getActiveView().getMapControl().getMapContext().getLayers().addLayer(newLayer);
+        }
+    }
+
+}

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig/lrs/app/createroute
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath


Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig/lrs/app/calibrateroute/CalibrateRouteExtension.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig/lrs/app/calibrateroute/CalibrateRouteExtension.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig/lrs/app/calibrateroute/CalibrateRouteExtension.java	(revision 950)
@@ -0,0 +1,250 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.app.calibrateroute;
+
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+
+import javax.swing.JOptionPane;
+
+import org.apache.commons.lang3.StringUtils;
+import org.gvsig.andami.IconThemeHelper;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.PluginsLocator;
+import org.gvsig.andami.PluginsManager;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.app.ApplicationLocator;
+import org.gvsig.app.ApplicationManager;
+import org.gvsig.app.project.documents.view.ViewDocument;
+import org.gvsig.app.project.documents.view.gui.IView;
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.dal.feature.EditableFeature;
+import org.gvsig.fmap.dal.feature.Feature;
+import org.gvsig.fmap.dal.feature.FeatureSelection;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.store.shp.SHPNewStoreParameters;
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.mapcontext.MapContextLocator;
+import org.gvsig.fmap.mapcontext.MapContextManager;
+import org.gvsig.fmap.mapcontext.exceptions.LoadLayerException;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.lrs.lib.api.LrsAlgorithm;
+import org.gvsig.lrs.lib.api.LrsAlgorithmsLocator;
+import org.gvsig.lrs.lib.api.LrsAlgorithmsManager;
+import org.gvsig.lrs.lib.api.LrsCalibrateRouteAlgorithmParams;
+import org.gvsig.lrs.lib.api.MeasuresCalculator;
+import org.gvsig.lrs.lib.api.exceptions.LrsGettingParametersException;
+import org.gvsig.lrs.lib.api.exceptions.LrsNeededParameterException;
+import org.gvsig.lrs.swing.api.JLrsAlgorithmParams;
+import org.gvsig.lrs.swing.api.JLrsLastUsedValues;
+import org.gvsig.lrs.swing.api.JLrsProgressDialog;
+import org.gvsig.lrs.swing.api.LrsAlgorithmsSwingLocator;
+import org.gvsig.lrs.swing.api.LrsAlgorithmsSwingManager;
+import org.gvsig.lrs.swing.impl.JLrsCalibrateRouteParamsController;
+import org.gvsig.lrs.swing.impl.JLrsUtils;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.dispose.DisposableIterator;
+import org.gvsig.tools.dynobject.DynObject;
+import org.gvsig.tools.i18n.I18nManager;
+import org.gvsig.tools.swing.api.ToolsSwingLocator;
+import org.gvsig.tools.swing.api.windowmanager.Dialog;
+import org.gvsig.tools.swing.api.windowmanager.WindowManager;
+import org.gvsig.tools.swing.api.windowmanager.WindowManager_v2;
+import org.gvsig.tools.task.SimpleTaskStatus;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+
+/**
+ * @author fdiaz
+ *
+ */
+public class CalibrateRouteExtension extends Extension {
+
+	private static final Logger logger = LoggerFactory.getLogger(CalibrateRouteExtension.class);
+
+	/* (non-Javadoc)
+	 * @see org.gvsig.andami.plugins.IExtension#execute(java.lang.String)
+	 */
+	public void execute(String actionCommand) {
+		if (StringUtils.equalsIgnoreCase(actionCommand, "calibrate-routes")) {
+			IView view = getActiveView();
+			FLayers layers = view.getMapControl().getMapContext().getLayers();
+
+			final WindowManager winManager = ToolsSwingLocator.getWindowManager();
+
+			final LrsAlgorithmsSwingManager manager = LrsAlgorithmsSwingLocator.getLrsAlgorithmsSwingManager();
+
+			final I18nManager i18nManager = ToolsLocator.getI18nManager();
+
+			JLrsCalibrateRouteParamsController panel;
+			try {
+				panel = (JLrsCalibrateRouteParamsController)manager.createJLrsCalibrateRouteAlgorithmParameters(layers, null);
+			} catch (LrsNeededParameterException e2) {
+				logger.error("Error creating panel", e2);
+				JOptionPane.showMessageDialog(
+						null,
+						new StringBuilder().append(i18nManager.getTranslation("error_creating_panel"))
+						.append(":").append(e2.getLocalizedMessage()),
+						i18nManager.getTranslation("error"), JOptionPane.ERROR_MESSAGE);
+				return;
+			}
+			panel.setVisibleAceptCancel(true);
+			panel.addActionListener(new ActionListener() {
+
+				public void actionPerformed(ActionEvent e) {
+					JLrsAlgorithmParams panel = (JLrsAlgorithmParams) e.getSource();
+					if (panel.isCanceled()) {
+						return;
+					}
+					LrsCalibrateRouteAlgorithmParams params = null;
+					try {
+						params = (LrsCalibrateRouteAlgorithmParams)panel.getParams();
+					} catch (LrsGettingParametersException e1) {
+						logger.error("Error getting parameters", e1);
+						JOptionPane.showMessageDialog(
+								null,
+								new StringBuilder().append(i18nManager.getTranslation("error_getting_parameters"))
+								.append(":").append(e1.getLocalizedMessage()),
+								i18nManager.getTranslation("error"), JOptionPane.ERROR_MESSAGE);
+						return;
+					} catch (LrsNeededParameterException e1) {
+						logger.warn("Error getting parameters", e1);
+						JOptionPane.showMessageDialog(
+								null,
+								i18nManager.getTranslation(e1.getMessage()),
+								i18nManager.getTranslation("warning"), JOptionPane.WARNING_MESSAGE);
+						return;
+					}
+					LrsAlgorithmsManager algorithmsManager = LrsAlgorithmsLocator.getLrsAlgorithmsManager();
+					final LrsAlgorithm algorithm = algorithmsManager.createLrsAlgorithm(params);
+					final SHPNewStoreParameters shpParams=(SHPNewStoreParameters)params.getNewFeatureStoreParameters();
+
+					final SimpleTaskStatus taskStatus =
+							ToolsLocator.getTaskStatusManager().createDefaultSimpleTaskStatus(i18nManager.getTranslation("progress"));
+
+					final JLrsProgressDialog progressDialog = manager.createJLrsProgressDialog(taskStatus);
+
+					winManager.showWindow(progressDialog.asJComponent(), i18nManager.getTranslation("calibrate_routes"),
+							WindowManager.MODE.WINDOW);
+
+					Thread task = new Thread(new Runnable() {
+
+						public void run() {
+							try {
+								algorithm.execute(taskStatus);
+								int resultLoadLayer =JOptionPane.showConfirmDialog(
+										null,
+										i18nManager.getTranslation("load_layer_question"),
+										i18nManager.getTranslation("load_layer_question_title"), JOptionPane.YES_NO_OPTION);
+								if (resultLoadLayer==JOptionPane.YES_OPTION){
+									loadLayer(shpParams);
+								}
+							} catch (Exception e) {
+								logger.error("Error calibrating route", e);
+								String message = e.getMessage();
+								if (e.getCause() != null) {
+									message = e.getCause().getMessage();
+								}
+								JOptionPane.showMessageDialog(
+										progressDialog.asJComponent(),
+										message,
+										i18nManager.getTranslation("calibrate_routes"),
+										JOptionPane.ERROR_MESSAGE
+										);
+							}
+						}
+					});
+					task.start();
+
+				}
+			});
+			winManager.showWindow(panel.asJComponent(), i18nManager.getTranslation("calibrate_routes"),
+					WindowManager.MODE.WINDOW);
+		}
+
+	}
+
+	/* (non-Javadoc)
+	 * @see org.gvsig.andami.plugins.IExtension#initialize()
+	 */
+	public void initialize() {
+		registerIcons();
+	}
+
+	/* (non-Javadoc)
+	 * @see org.gvsig.andami.plugins.IExtension#isEnabled()
+	 */
+	public boolean isEnabled() {
+        IView view = getActiveView();
+        //FLyrVect activeLayer = getActiveLayer(view);
+        if (view!=null){
+            ViewDocument viewDocument = view.getViewDocument();
+            FLayers layers = viewDocument.getMapContext().getLayers();
+            return JLrsUtils.validatedMCurveAndPointLayer(layers);
+        }
+
+        return false;
+
+	}
+
+	/* (non-Javadoc)
+	 * @see org.gvsig.andami.plugins.IExtension#isVisible()
+	 */
+	public boolean isVisible() {
+		ApplicationManager application = ApplicationLocator.getManager();
+
+		return application.getActiveComponent(ViewDocument.class) != null;
+	}
+
+	private void registerIcons() {
+		IconThemeHelper.registerIcon("lrs", "pk_blue", this);
+	}
+
+
+	private IView getActiveView() {
+		ApplicationManager application = ApplicationLocator.getManager();
+		IView view = (IView) application.getActiveComponent(ViewDocument.class);
+		return view;
+	}
+
+	private void loadLayer(SHPNewStoreParameters shpParams){
+		if (shpParams!=null ){
+			String name=shpParams.getFile().getName();
+			if (name.contains(".shp")){
+				name=name.substring(0,name.lastIndexOf(".shp"));
+			}
+			MapContextManager mapContextManager =MapContextLocator.getMapContextManager();
+
+			FLyrVect newLayer=null;
+			try {
+				newLayer = (FLyrVect) mapContextManager.createLayer(name,shpParams);
+			} catch (LoadLayerException e) {
+				logger.warn("Couldn't load layer",e);
+			}
+			getActiveView().getMapControl().getMapContext().getLayers().addLayer(newLayer);
+		}
+	}
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig/lrs/app/calibrateroute/MeasureCalculatorRouteExtension.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig/lrs/app/calibrateroute/MeasureCalculatorRouteExtension.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig/lrs/app/calibrateroute/MeasureCalculatorRouteExtension.java	(revision 950)
@@ -0,0 +1,194 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.app.calibrateroute;
+
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+
+import org.apache.commons.lang3.StringUtils;
+import org.gvsig.andami.IconThemeHelper;
+import org.gvsig.andami.PluginServices;
+import org.gvsig.andami.PluginsLocator;
+import org.gvsig.andami.PluginsManager;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.app.ApplicationLocator;
+import org.gvsig.app.ApplicationManager;
+import org.gvsig.app.project.documents.view.ViewDocument;
+import org.gvsig.app.project.documents.view.gui.IView;
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.dal.feature.EditableFeature;
+import org.gvsig.fmap.dal.feature.Feature;
+import org.gvsig.fmap.dal.feature.FeatureSelection;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.lrs.lib.api.LrsAlgorithmsLocator;
+import org.gvsig.lrs.lib.api.LrsAlgorithmsManager;
+import org.gvsig.lrs.lib.api.MeasuresCalculator;
+import org.gvsig.lrs.lib.api.exceptions.LrsNeededParameterException;
+import org.gvsig.lrs.swing.api.JLrsAlgorithmParams;
+import org.gvsig.lrs.swing.api.JLrsLastUsedValues;
+import org.gvsig.lrs.swing.api.LrsAlgorithmsSwingLocator;
+import org.gvsig.lrs.swing.api.LrsAlgorithmsSwingManager;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.dispose.DisposableIterator;
+import org.gvsig.tools.dynobject.DynObject;
+import org.gvsig.tools.i18n.I18nManager;
+import org.gvsig.tools.swing.api.ToolsSwingLocator;
+import org.gvsig.tools.swing.api.windowmanager.Dialog;
+import org.gvsig.tools.swing.api.windowmanager.WindowManager;
+import org.gvsig.tools.swing.api.windowmanager.WindowManager_v2;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+
+/**
+ * @author jbadia
+ *
+ */
+public class MeasureCalculatorRouteExtension extends Extension {
+
+	private static final Logger logger = LoggerFactory.getLogger(MeasureCalculatorRouteExtension.class);
+
+	/* (non-Javadoc)
+	 * @see org.gvsig.andami.plugins.IExtension#execute(java.lang.String)
+	 */
+	public void execute(String actionCommand) {
+
+		if (StringUtils.equalsIgnoreCase(actionCommand, "calculate-m-routes")) {
+			IView view = getActiveView();
+			FLyrVect layer = view.getMapControl().getMapContext().getLayers().getFirstActiveVectorLayer();
+
+
+			LrsAlgorithmsSwingManager manager = LrsAlgorithmsSwingLocator.getLrsAlgorithmsSwingManager();
+			I18nManager i18nManager = ToolsLocator.getI18nManager();
+
+			PluginsManager pluginsManager = PluginsLocator.getManager();
+			PluginServices plugin = pluginsManager.getPlugin(this);
+			DynObject pluginProperties = plugin.getPluginProperties();
+
+
+
+			JLrsAlgorithmParams panel;
+			try {
+				JLrsLastUsedValues params = manager.getJLrsLastUsedValues(pluginProperties);
+				panel = manager.createJLrsCalculateMRoutePanel(layer, params);
+				WindowManager_v2 winManager = (WindowManager_v2) ToolsSwingLocator.getWindowManager();
+
+				final Dialog dialog = winManager.createDialog(panel.asJComponent(), 
+						i18nManager.getTranslation("m-coordinate-selector"), "", WindowManager_v2.BUTTONS_OK_CANCEL);      
+				dialog.addActionListener(new ActionListener() {
+					public void actionPerformed(ActionEvent e) {
+						if( dialog.getAction()==WindowManager_v2.BUTTON_OK) {
+							LrsAlgorithmsManager lrsAlgMng = LrsAlgorithmsLocator.getLrsAlgorithmsManager();
+							LrsAlgorithmsSwingManager lrsAlgSwingMng = LrsAlgorithmsSwingLocator.getLrsAlgorithmsSwingManager();
+
+							JLrsLastUsedValues prms = lrsAlgSwingMng.getJLrsLastUsedValues();
+							if(prms != null && !StringUtils.isBlank(prms.getPkInicial()) && !StringUtils.isBlank(prms.getPkFinal())){
+
+								FLyrVect lyrVect = (FLyrVect) getActiveView().getMapControl().getMapContext().getLayers().getFirstActiveVectorLayer();
+								FeatureStore featStore = lyrVect.getFeatureStore();
+								try {
+									featStore.edit(FeatureStore.MODE_FULLEDIT);
+
+									FeatureSelection selection = featStore.getFeatureSelection();
+									DisposableIterator it = selection.fastIterator();
+									while(it.hasNext()){
+										Feature feat = (Feature) it.next();
+										EditableFeature editfeat = feat.getEditable();
+
+										MeasuresCalculator mcalc = lrsAlgMng.createMeasuresCalculator(editfeat.getDefaultGeometry(), false);
+										mcalc.setFirstMeasure(editfeat.getDouble(prms.getPkInicial()));
+										mcalc.setLastMeasure(editfeat.getDouble(prms.getPkFinal()));
+										mcalc.calculate();
+										Geometry mgeom = mcalc.getResult();
+
+										editfeat.setDefaultGeometry(mgeom);
+										editfeat.validate(EditableFeature.CHECK_RULES_AT_FINISH);
+										featStore.update(editfeat);
+									}
+
+									featStore.finishEditing();
+								} catch (DataException e1) {
+									logger.debug("Error creating the M coordinate: ", e1);
+								}
+							}else{
+
+							}
+
+						}
+					}
+				});
+				dialog.show(WindowManager.MODE.WINDOW);
+			} catch (LrsNeededParameterException e1) {
+				// TODO Auto-generated catch block
+				e1.printStackTrace();
+			}
+
+		}
+	}
+
+	/* (non-Javadoc)
+	 * @see org.gvsig.andami.plugins.IExtension#initialize()
+	 */
+	public void initialize() {
+		registerIcons();
+	}
+
+	/* (non-Javadoc)
+	 * @see org.gvsig.andami.plugins.IExtension#isEnabled()
+	 */
+	public boolean isEnabled() {
+        IView view = getActiveView();
+        if (view!=null){
+            ViewDocument viewDocument = view.getViewDocument();
+            FLayer[] layers = viewDocument.getMapContext().getLayers().getActives();
+            return layers.length > 0;
+        }
+
+        return false;
+
+	}
+
+	/* (non-Javadoc)
+	 * @see org.gvsig.andami.plugins.IExtension#isVisible()
+	 */
+	public boolean isVisible() {
+		ApplicationManager application = ApplicationLocator.getManager();
+		return application.getActiveComponent(ViewDocument.class) != null;
+	}
+
+	private void registerIcons() {
+		IconThemeHelper.registerIcon("lrs", "pk_blue", this);
+	}
+
+
+	private IView getActiveView() {
+		ApplicationManager application = ApplicationLocator.getManager();
+		IView view = (IView) application.getActiveComponent(ViewDocument.class);
+		return view;
+	}
+
+
+}

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig/lrs/app/calibrateroute/MeasureCalculatorRouteExtension.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain


Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig/lrs/app/calibrateroute
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath


Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig/lrs/app/showmeasures/ShowMeasuresExtension.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig/lrs/app/showmeasures/ShowMeasuresExtension.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig/lrs/app/showmeasures/ShowMeasuresExtension.java	(revision 950)
@@ -0,0 +1,533 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.app.showmeasures;
+
+import java.awt.Color;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.awt.event.ComponentEvent;
+import java.awt.event.ComponentListener;
+import java.text.DecimalFormat;
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import javax.swing.JOptionPane;
+
+import org.apache.commons.lang3.StringUtils;
+import org.cresques.cts.ICoordTrans;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import org.gvsig.andami.IconThemeHelper;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.app.ApplicationLocator;
+import org.gvsig.app.ApplicationManager;
+import org.gvsig.app.project.documents.view.ViewDocument;
+import org.gvsig.app.project.documents.view.gui.IView;
+import org.gvsig.fmap.dal.DataSet;
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.dal.feature.Feature;
+import org.gvsig.fmap.dal.feature.FeatureSelection;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.geom.GeometryLocator;
+import org.gvsig.fmap.geom.GeometryManager;
+import org.gvsig.fmap.geom.aggregate.MultiLine;
+import org.gvsig.fmap.geom.exception.CreateGeometryException;
+import org.gvsig.fmap.geom.primitive.Line;
+import org.gvsig.fmap.geom.primitive.Point;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.MapContextLocator;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.fmap.mapcontext.layers.vectorial.GraphicLayer;
+import org.gvsig.fmap.mapcontext.rendering.symbols.ISymbol;
+import org.gvsig.fmap.mapcontext.rendering.symbols.SymbolManager;
+import org.gvsig.gui.beans.ProgressDialog;
+import org.gvsig.lrs.lib.api.LrsAlgorithm;
+import org.gvsig.lrs.lib.api.LrsAlgorithmsLocator;
+import org.gvsig.lrs.lib.api.LrsAlgorithmsManager;
+import org.gvsig.lrs.lib.api.LrsShowMeasuresAlgorithmParams;
+import static org.gvsig.lrs.lib.api.LrsShowMeasuresAlgorithmParams.LRS_SHOWMEASURES_KILOMETER;
+import static org.gvsig.lrs.lib.api.LrsShowMeasuresAlgorithmParams.LRS_SHOWMEASURES_METER;
+import org.gvsig.lrs.lib.api.exceptions.LrsGettingParametersException;
+import org.gvsig.lrs.lib.api.exceptions.LrsNeededParameterException;
+import org.gvsig.lrs.swing.api.JLrsAlgorithmParams;
+import org.gvsig.lrs.swing.api.JLrsProgressDialog;
+import org.gvsig.lrs.swing.api.LrsAlgorithmsSwingLocator;
+import org.gvsig.lrs.swing.api.LrsAlgorithmsSwingManager;
+import org.gvsig.lrs.swing.impl.JLrsShowMeasuresParamsController;
+import org.gvsig.lrs.swing.impl.JLrsUtils;
+import org.gvsig.symbology.SymbologyLocator;
+import org.gvsig.symbology.SymbologyManager;
+import org.gvsig.symbology.fmap.mapcontext.rendering.symbol.text.ISimpleTextSymbol;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.dispose.DisposableIterator;
+import org.gvsig.tools.i18n.I18nManager;
+import org.gvsig.tools.locator.LocatorException;
+import org.gvsig.tools.swing.api.ToolsSwingLocator;
+import org.gvsig.tools.swing.api.windowmanager.WindowManager;
+import org.gvsig.tools.task.SimpleTaskStatus;
+
+/**
+ * @author dmartinez
+ *
+ */
+public class ShowMeasuresExtension extends Extension implements ComponentListener {
+
+    private static final Logger logger = LoggerFactory.getLogger(ShowMeasuresExtension.class);
+
+    public static final String SHOW_MEASURES_GRAPHICS_ID = "ShowMeasures";
+
+    private JLrsShowMeasuresParamsController panel;
+
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see org.gvsig.andami.plugins.IExtension#execute(java.lang.String)
+     */
+    public void execute(String actionCommand) {
+        if (StringUtils.equalsIgnoreCase(actionCommand, "show-measures")) {
+            IView view = getActiveView();
+            final MapContext mapContext = view.getMapControl().getMapContext();
+            final GraphicLayer graphics = mapContext.getGraphicsLayer();
+
+            final FLyrVect activeLayer = getActiveLayer(view);
+
+            final WindowManager winManager = ToolsSwingLocator.getWindowManager();
+
+            final LrsAlgorithmsSwingManager manager = LrsAlgorithmsSwingLocator.getLrsAlgorithmsSwingManager();
+
+            final I18nManager i18nManager = ToolsLocator.getI18nManager();
+
+            try {
+                panel =
+                    (JLrsShowMeasuresParamsController) manager.createJLrsShowMeasuresAlgorithmParameters(activeLayer,
+                        null);
+                panel.addComponentListener(this);
+            } catch (LrsNeededParameterException e2) {
+                logger.error("Error creating panel", e2);
+                JOptionPane.showMessageDialog(
+                    null,
+                    new StringBuilder().append(i18nManager.getTranslation("error_creating_panel")).append(":")
+                        .append(e2.getLocalizedMessage()), i18nManager.getTranslation("error"),
+                    JOptionPane.ERROR_MESSAGE);
+                return;
+            }
+            panel.setVisibleAceptCancel(true);
+            panel.addActionListener(new ActionListener() {
+
+                public void actionPerformed(ActionEvent e) {
+                    JLrsAlgorithmParams panel = (JLrsAlgorithmParams) e.getSource();
+                    if (panel.isCanceled()) {
+                        return;
+                    }
+                    LrsShowMeasuresAlgorithmParams params = null;
+                    try {
+                        params = (LrsShowMeasuresAlgorithmParams) panel.getParams();
+                    } catch (LrsGettingParametersException e1) {
+                        logger.error("Error getting parameters", e1);
+                        JOptionPane.showMessageDialog(
+                            null,
+                            new StringBuilder().append(i18nManager.getTranslation("error_getting_parameters"))
+                                .append(":").append(e1.getLocalizedMessage()), i18nManager.getTranslation("error"),
+                            JOptionPane.ERROR_MESSAGE);
+                        return;
+                    } catch (LrsNeededParameterException e1) {
+                        logger.warn("Error getting parameters", e1);
+                        JOptionPane.showMessageDialog(null, i18nManager.getTranslation(e1.getMessage()),
+                            i18nManager.getTranslation("warning"), JOptionPane.WARNING_MESSAGE);
+                        return;
+                    }
+                    final SimpleTaskStatus taskStatus =
+                        ToolsLocator.getTaskStatusManager().createDefaultSimpleTaskStatus(
+                            i18nManager.getTranslation("progress"));
+
+                    final JLrsProgressDialog progressDialog = manager.createJLrsProgressDialog(taskStatus);
+
+                    winManager.showWindow(progressDialog.asJComponent(), i18nManager.getTranslation("show_measures"),
+                        WindowManager.MODE.WINDOW);
+
+                    final double distance = params.getDistance();
+                    final int units = params.getUnits();
+
+                    Thread task = new Thread(new Runnable() {
+
+                        public void run() {
+                            try {
+                                showMeasures(graphics, activeLayer, distance, units, taskStatus);
+                                mapContext.invalidate();
+                                if(!taskStatus.isRunning() && progressDialog.asJComponent().isVisible()){
+                                    progressDialog.asJComponent().setVisible(false);
+                                }
+                            } catch (Exception e) {
+                                logger.error("Error showing measures", e);
+                                String message = e.getMessage();
+                                if (e.getCause() != null) {
+                                    message = e.getCause().getMessage();
+                                }
+                                JOptionPane.showMessageDialog(progressDialog.asJComponent(), message,
+                                    i18nManager.getTranslation("show_measures"), JOptionPane.ERROR_MESSAGE);
+                            }
+                        }
+                    });
+                    task.start();
+
+                }
+            });
+            winManager.showWindow(panel.asJComponent(), i18nManager.getTranslation("show_measures"),
+                WindowManager.MODE.WINDOW);
+        }
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see org.gvsig.andami.plugins.IExtension#initialize()
+     */
+    public void initialize() {
+        registerIcons();
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see org.gvsig.andami.plugins.IExtension#isEnabled()
+     */
+    public boolean isEnabled() {
+        IView view = getActiveView();
+        FLyrVect activeLayer = getActiveLayer(view);
+        if (panel == null && activeLayer != null) {
+            return JLrsUtils.hasMLayersWithSelectedFeatures(activeLayer);
+        }
+        return false;
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see org.gvsig.andami.plugins.IExtension#isVisible()
+     */
+    public boolean isVisible() {
+        ApplicationManager application = ApplicationLocator.getManager();
+
+        return application.getActiveComponent(ViewDocument.class) != null;
+    }
+
+    private void registerIcons() {
+        IconThemeHelper.registerIcon("lrs", "pk_green", this);
+    }
+
+    /*
+     * Shows measurements along the selected features in a layer with a fixed spacing
+     *
+     */
+    private void showMeasures(GraphicLayer graphics, FLyrVect layer, double distance, int units, SimpleTaskStatus taskStatus)
+        throws DataException, CreateGeometryException, LocatorException {
+        FeatureStore featureStore = layer.getFeatureStore();
+        FeatureSelection selection = featureStore.getFeatureSelection();
+        if (selection != null && !selection.isEmpty()) {
+            long range = getRange(selection);
+            taskStatus.setRangeOfValues(0, range);
+            long curValue = 0;
+            taskStatus.setCurValue(curValue);
+            DisposableIterator it = selection.fastIterator();
+            ICoordTrans ct = layer.getCoordTrans();
+            while (it.hasNext()) {
+                Feature feature = (Feature) it.next();
+                Geometry geometry = feature.getDefaultGeometry();
+                if (geometry instanceof Line) {
+                    curValue = showLineMeasures(graphics, curValue, (Line) geometry, distance, units, ct);
+                    taskStatus.setCurValue(curValue);
+                } else if (geometry instanceof MultiLine) {
+                    MultiLine multiLine = (MultiLine) geometry;
+                    int primitives = multiLine.getPrimitivesNumber();
+                    for (int i = 0; i < primitives; i++) {
+                        curValue = showLineMeasures(graphics, curValue, (Line) multiLine.getPrimitiveAt(i), distance, units, ct);
+                        taskStatus.setCurValue(curValue);
+                    }
+                }
+            }
+            it.dispose();
+        }
+        taskStatus.terminate();
+    }
+
+    /**
+     * Shows measurements along a line with a fixed spacing
+     *
+     * @param curValue
+     * @param ct2
+     * @param taskStatus
+     * @param geometry
+     * @return
+     * @throws LocatorException
+     * @throws CreateGeometryException
+     */
+    private long showLineMeasures(GraphicLayer graphics, long curValue, Line line, Double distance, int units, ICoordTrans ct) throws CreateGeometryException, LocatorException {
+        long value = curValue;
+        for (int i = 0; i < line.getNumVertices() - 1; i++) {
+            value++;
+            Point vertex = (Point) line.getVertex(i);
+            double m0 = vertex.getCoordinateAt(vertex.getDimension() - 1);
+
+            double div = m0 / distance;
+            if (isMultiple(m0, distance)) {
+                showMeasure(graphics, vertex, m0, units, ct);
+            }
+            Point nextVertex = line.getVertex(i + 1);
+            double m1 = nextVertex.getCoordinateAt(vertex.getDimension() - 1);
+            List<Double> multiples = calculateMultiplesBetweenTwoValues(distance, m0, m1);
+            for (Iterator iterator = multiples.iterator(); iterator.hasNext();) {
+                Double m = (Double) iterator.next();
+                Point point = getPointWithMBetweenTwoVertex(m, vertex, nextVertex);
+                showMeasure(graphics, point, m, units, ct);
+            }
+        }
+        value++;
+        return value;
+    }
+
+    /**
+     * Show the m in the point p on the graphicLayer
+     *
+     * @param m
+     * @param ct
+     */
+    private void showMeasure(GraphicLayer graphics, Point p, double m, int units, ICoordTrans ct) {
+
+        GeometryManager geomManager = GeometryLocator.getGeometryManager();
+        SymbolManager symbolManager = MapContextLocator.getSymbolManager();
+
+        ISymbol markerSymbol = symbolManager.createSymbol(Geometry.TYPES.POINT, Color.RED);
+        ISimpleTextSymbol textSymbol = getTextSymbol();
+        DecimalFormat formato = new DecimalFormat("0.000");
+        double theMeasure = m;
+        if(units == LRS_SHOWMEASURES_METER){
+            theMeasure = m/1000;
+        }
+        
+        String text = formato.format(theMeasure);
+        if(units == LRS_SHOWMEASURES_METER || units == LRS_SHOWMEASURES_KILOMETER){
+            text = text.replace(",", " + ");
+        }
+
+        textSymbol.setText(text);
+        int idMarkerSymbol = graphics.addSymbol(markerSymbol);
+        int idTextSymbol = graphics.addSymbol(textSymbol);
+        Point clonedPoint = (Point) p.cloneGeometry();
+        clonedPoint.reProject(ct);
+        graphics.addGraphic(SHOW_MEASURES_GRAPHICS_ID, clonedPoint, idTextSymbol);
+        graphics.addGraphic(SHOW_MEASURES_GRAPHICS_ID, clonedPoint, idMarkerSymbol);
+    }
+
+    /*
+     * Creates a text symbol to be used in showMeasure
+     */
+    private ISimpleTextSymbol getTextSymbol(){
+        SymbologyManager symbologyManager = SymbologyLocator.getSymbologyManager();
+        ISimpleTextSymbol textSymbol = symbologyManager.createSimpleTextSymbol();
+        textSymbol.setFontSize(10);
+        return textSymbol;
+    }
+
+    /**
+     * Dados dos puntos con coordenada M, calcula el punto correspondiente a la m dada.
+     *
+     * @param m
+     * @param vertex
+     * @param nextVertex
+     * @return
+     * @throws LocatorException
+     * @throws CreateGeometryException
+     */
+    private Point getPointWithMBetweenTwoVertex(Double m, Point vertex, Point nextVertex) throws CreateGeometryException, LocatorException {
+        Point point = (Point)GeometryLocator.getGeometryManager().create(Geometry.TYPES.POINT, Geometry.SUBTYPES.GEOM2D);
+        point.setX(
+            getCoordinateBetweenTwoValues(
+                m,
+                vertex.getCoordinateAt(vertex.getDimension()-1),
+                nextVertex.getCoordinateAt(vertex.getDimension()-1),
+                vertex.getX(),
+                nextVertex.getX()));
+        point.setY(
+            getCoordinateBetweenTwoValues(
+                m,
+                vertex.getCoordinateAt(vertex.getDimension()-1),
+                nextVertex.getCoordinateAt(vertex.getDimension()-1),
+                vertex.getY(),
+                nextVertex.getY()));
+
+        return point;
+    }
+
+    /**
+     * Dados los valores en una dimensión de dos puntos y sus "m" correspondientes,
+     * calcula el valor en esa dimensión correspondiente a la "m" dada.
+     *
+     * @param m
+     * @param m1
+     * @param m2
+     * @param v1
+     * @param v2
+     * @return
+     */
+    private double getCoordinateBetweenTwoValues(double m, double m1, double m2, double v1, double v2) {
+        if (v1==v2){
+            return Double.POSITIVE_INFINITY;
+        }
+         return ((v2-v1)*(m-m1)/(m2-m1))+v1;
+    }
+
+    /**
+     * Calcula los múltiplos de "distance" que existen entre los valores "value0" y "value1"
+     *
+     * @param distance
+     * @param value0
+     * @param value1
+     * @return
+     */
+    private List<Double> calculateMultiplesBetweenTwoValues(Double distance, double value0, double value1) {
+        List<Double> result = new ArrayList<Double>();
+
+        double v0;
+        double v1;
+        if(value0<=value1){
+            v0 = value0;
+            v1 = value1;
+        } else {
+            v0 = value1;
+            v1 = value0;
+        }
+
+        int factor1 = (int) Math.ceil(v0/distance);
+        int factor2 = (int) Math.floor(v1/distance);
+            for (int factor = factor1; factor <= factor2; factor++) {
+                double m = factor * distance;
+                if(m>=v0 && m<=v1){
+                    result.add(m);
+                }
+            }
+        return result;
+    }
+
+
+    /**
+     * Calcula si el valor del parámetro n es múltiplo del valor del parámetro d
+     * @param n
+     * @param d
+     */
+    private boolean isMultiple(double n, double d) {
+        double div = n / d;
+        return ((div - (int) div) < 0.000001);
+    }
+
+    /**
+     * @param selection
+     * @throws DataException
+     */
+    private long getRange(FeatureSelection selection) throws DataException {
+        long range = 0;
+        DisposableIterator it = selection.fastIterator();
+        while (it.hasNext()) {
+            Feature feature = (Feature) it.next();
+            Geometry geometry = feature.getDefaultGeometry();
+            if (geometry instanceof Line) {
+                range += ((Line) geometry).getNumVertices();
+            } else if (geometry instanceof MultiLine) {
+                MultiLine multiLine = (MultiLine) geometry;
+                int primitives = multiLine.getPrimitivesNumber();
+                for (int i = 0; i < primitives; i++) {
+                    range += ((Line) multiLine.getPrimitiveAt(i)).getNumVertices();
+                }
+            }
+        }
+        it.dispose();
+        return range;
+    }
+
+    private IView getActiveView() {
+        ApplicationManager application = ApplicationLocator.getManager();
+        IView view = (IView) application.getActiveComponent(ViewDocument.class);
+        return view;
+    }
+
+    private FLyrVect getActiveLayer(IView vista) {
+        if (vista != null) {
+            ViewDocument viewDocument = vista.getViewDocument();
+            FLayer[] actives = viewDocument.getMapContext().getLayers().getActives();
+
+            if ((actives.length == 1) && (actives[0] instanceof FLyrVect)) {
+                return (FLyrVect) actives[0];
+            }
+        }
+        return null;
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see java.awt.event.ComponentListener#componentResized(java.awt.event.
+     * ComponentEvent)
+     */
+    public void componentResized(ComponentEvent e) {
+        // TODO Auto-generated method stub
+
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see
+     * java.awt.event.ComponentListener#componentMoved(java.awt.event.ComponentEvent
+     * )
+     */
+    public void componentMoved(ComponentEvent e) {
+        // TODO Auto-generated method stub
+
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see
+     * java.awt.event.ComponentListener#componentShown(java.awt.event.ComponentEvent
+     * )
+     */
+    public void componentShown(ComponentEvent e) {
+        // TODO Auto-generated method stub
+
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see java.awt.event.ComponentListener#componentHidden(java.awt.event.
+     * ComponentEvent)
+     */
+    public void componentHidden(ComponentEvent e) {
+        panel = null;
+    }
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig/lrs/app/showmeasures/WiperMeasuresExtension.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig/lrs/app/showmeasures/WiperMeasuresExtension.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig/lrs/app/showmeasures/WiperMeasuresExtension.java	(revision 950)
@@ -0,0 +1,124 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.app.showmeasures;
+
+import org.apache.commons.lang3.StringUtils;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import org.gvsig.andami.IconThemeHelper;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.app.ApplicationLocator;
+import org.gvsig.app.ApplicationManager;
+import org.gvsig.app.project.documents.view.ViewDocument;
+import org.gvsig.app.project.documents.view.gui.IView;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.fmap.mapcontext.layers.vectorial.GraphicLayer;
+import org.gvsig.lrs.swing.impl.JLrsShowMeasuresParamsController;
+
+/**
+ * @author dmartinez
+ *
+ */
+public class WiperMeasuresExtension extends Extension {
+
+    private static final Logger logger = LoggerFactory.getLogger(WiperMeasuresExtension.class);
+
+    private JLrsShowMeasuresParamsController panel;
+
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see org.gvsig.andami.plugins.IExtension#execute(java.lang.String)
+     */
+    public void execute(String actionCommand) {
+        if (StringUtils.equalsIgnoreCase(actionCommand, "wiper-measures")) {
+            IView view = getActiveView();
+            final MapContext mapContext = view.getMapControl().getMapContext();
+            final GraphicLayer graphics = mapContext.getGraphicsLayer();
+
+            graphics.removeGraphics(ShowMeasuresExtension.SHOW_MEASURES_GRAPHICS_ID);
+            mapContext.invalidate();
+
+        }
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see org.gvsig.andami.plugins.IExtension#initialize()
+     */
+    public void initialize() {
+        registerIcons();
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see org.gvsig.andami.plugins.IExtension#isEnabled()
+     */
+    public boolean isEnabled() {
+        IView view = getActiveView();
+        FLyrVect activeLayer = getActiveLayer(view);
+        if (panel == null && activeLayer != null) {
+            return true;
+        }
+        return false;
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see org.gvsig.andami.plugins.IExtension#isVisible()
+     */
+    public boolean isVisible() {
+        ApplicationManager application = ApplicationLocator.getManager();
+
+        return application.getActiveComponent(ViewDocument.class) != null;
+    }
+
+    private void registerIcons() {
+        IconThemeHelper.registerIcon("lrs", "wiper", this);
+    }
+
+    private IView getActiveView() {
+        ApplicationManager application = ApplicationLocator.getManager();
+        IView view = (IView) application.getActiveComponent(ViewDocument.class);
+        return view;
+    }
+
+    private FLyrVect getActiveLayer(IView vista) {
+        if (vista != null) {
+            ViewDocument viewDocument = vista.getViewDocument();
+            FLayer[] actives = viewDocument.getMapContext().getLayers().getActives();
+
+            if ((actives.length == 1) && (actives[0] instanceof FLyrVect)) {
+                return (FLyrVect) actives[0];
+            }
+        }
+        return null;
+    }
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig/lrs/app/editroutecalibration/EditRouteCalibrationExtension.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig/lrs/app/editroutecalibration/EditRouteCalibrationExtension.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig/lrs/app/editroutecalibration/EditRouteCalibrationExtension.java	(revision 950)
@@ -0,0 +1,341 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.app.editroutecalibration;
+
+import java.awt.Component;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.awt.event.ComponentEvent;
+import java.awt.event.ComponentListener;
+import java.text.MessageFormat;
+import java.util.List;
+import java.util.Map;
+import javax.swing.JOptionPane;
+import org.apache.commons.lang3.StringUtils;
+import org.gvsig.andami.IconThemeHelper;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.app.ApplicationLocator;
+import org.gvsig.app.ApplicationManager;
+import org.gvsig.app.project.documents.view.ViewDocument;
+import org.gvsig.app.project.documents.view.gui.IView;
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.dal.feature.EditableFeature;
+import org.gvsig.fmap.dal.feature.Feature;
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureReference;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.geom.aggregate.MultiLine;
+import org.gvsig.fmap.geom.primitive.Line;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.lrs.lib.api.LrsEditRouteCalibrationAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsEditRouteCalibrationSelectIdRouteAlgorithmParams;
+import org.gvsig.lrs.lib.api.exceptions.LrsGettingParametersException;
+import org.gvsig.lrs.lib.api.exceptions.LrsNeededParameterException;
+import org.gvsig.lrs.swing.api.JLrsAlgorithmParams;
+import org.gvsig.lrs.swing.api.LrsAlgorithmsSwingLocator;
+import org.gvsig.lrs.swing.api.LrsAlgorithmsSwingManager;
+import org.gvsig.lrs.swing.impl.JLrsEditRouteCalibrationController;
+import org.gvsig.lrs.swing.impl.JLrsEditRouteCalibrationSelectIdRouteController;
+import org.gvsig.lrs.swing.impl.JLrsUtils;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.i18n.I18nManager;
+import org.gvsig.tools.swing.api.ToolsSwingLocator;
+import org.gvsig.tools.swing.api.windowmanager.WindowManager;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+
+/**
+ * @author dmartinez
+ *
+ */
+public class EditRouteCalibrationExtension extends Extension implements ComponentListener {
+
+    private static final Logger logger = LoggerFactory.getLogger(EditRouteCalibrationExtension.class);
+
+    private JLrsEditRouteCalibrationSelectIdRouteController panelSelectId;
+
+    private JLrsEditRouteCalibrationController panelController;
+
+    @Override
+    public void execute(String actionCommand) {
+        if (StringUtils.equalsIgnoreCase(actionCommand, "edit-route-calibration")) {
+            IView view = getActiveView();
+            final FLyrVect activeLayer;
+            if (view!=null){
+                activeLayer = getActiveLayer(view);
+            }else{
+                activeLayer = null;
+            }
+
+            final MapContext mapContext = view.getMapControl().getMapContext();
+
+            final WindowManager winManager = ToolsSwingLocator.getWindowManager();
+
+            final LrsAlgorithmsSwingManager manager = LrsAlgorithmsSwingLocator.getLrsAlgorithmsSwingManager();
+
+            final I18nManager i18nManager = ToolsLocator.getI18nManager();
+
+            try {
+                panelSelectId = (JLrsEditRouteCalibrationSelectIdRouteController)manager.createJLrsEditRouteCalibrationSelectIdRouteAlgorithmParameters(activeLayer, null);
+                panelSelectId.addComponentListener(this);
+            } catch (LrsNeededParameterException e2) {
+                logger.error("Error creating panel", e2);
+                JOptionPane.showMessageDialog(
+                    null,
+                    new StringBuilder().append(i18nManager.getTranslation("error_creating_panel"))
+                        .append(":").append(e2.getLocalizedMessage()),
+                    i18nManager.getTranslation("error"), JOptionPane.ERROR_MESSAGE);
+                return;
+            }
+            panelSelectId.setVisibleAceptCancel(true);
+            panelSelectId.addActionListener((ActionEvent e) -> {
+                JLrsAlgorithmParams panel = (JLrsAlgorithmParams) e.getSource();
+                if (panel.isCanceled()) {
+                    return;
+                }
+                LrsEditRouteCalibrationSelectIdRouteAlgorithmParams params = null;
+                try {
+                    params = (LrsEditRouteCalibrationSelectIdRouteAlgorithmParams)panel.getParams();
+                } catch (LrsGettingParametersException e1) {
+                    logger.error("Error getting parameters", e1);
+                    JOptionPane.showMessageDialog(
+                            null,
+                            new StringBuilder().append(i18nManager.getTranslation("error_getting_parameters"))
+                                    .append(":").append(e1.getLocalizedMessage()),
+                            i18nManager.getTranslation("error"), JOptionPane.ERROR_MESSAGE);
+                    return;
+                } catch (LrsNeededParameterException e1) {
+                    logger.warn("Error getting parameters", e1);
+                    JOptionPane.showMessageDialog(
+                            null,
+                            i18nManager.getTranslation(e1.getMessage()),
+                            i18nManager.getTranslation("warning"), JOptionPane.WARNING_MESSAGE);
+                    return;
+                }   try {
+                    panelController = (JLrsEditRouteCalibrationController)manager.createJLrsEditRouteCalibrationAlgorithmParameters(activeLayer, mapContext, params.getIdRouteField(), null);
+                    panelController.addComponentListener(EditRouteCalibrationExtension.this);
+                } catch (Exception e2) {
+                    logger.error("Error creating panel", e2);
+                    JOptionPane.showMessageDialog(
+                            null,
+                            new StringBuilder().append(i18nManager.getTranslation("error_creating_panel"))
+                                    .append(":").append(e2.getLocalizedMessage()),
+                            i18nManager.getTranslation("error"), JOptionPane.ERROR_MESSAGE);
+                    return;
+                }   
+                panelController.setVisibleAceptCancel(true);
+                panelController.addActionListener((ActionEvent e1) -> {
+                    JLrsEditRouteCalibrationController panel1 = (JLrsEditRouteCalibrationController) e1.getSource();
+                    if (panel1.isCanceled()) {
+                        return;
+                    }
+                    if (panel1.hasWarnings()) {
+                        boolean acceptedWarnings = showWarnings(panel1.getWarnings());
+                        if (acceptedWarnings) {
+                            panel1.close();
+                        } else {
+                            return;
+                        }
+                    }
+                    final LrsEditRouteCalibrationAlgorithmParams params1;
+                    try {
+                        params1 = (LrsEditRouteCalibrationAlgorithmParams) panel1.getParams();
+                    } catch (LrsGettingParametersException e2) {
+                        logger.error("Error getting parameters", e2);
+                        JOptionPane.showMessageDialog(null, new StringBuilder().append(i18nManager.getTranslation("error_getting_parameters"))
+                                .append(":").append(e2.getLocalizedMessage()), i18nManager.getTranslation("error"), JOptionPane.ERROR_MESSAGE);
+                        return;
+                    } catch (LrsNeededParameterException e3) {
+                        logger.warn("Error getting parameters", e3);
+                        JOptionPane.showMessageDialog(null, i18nManager.getTranslation(e3.getMessage()), i18nManager.getTranslation("warning"), JOptionPane.WARNING_MESSAGE);
+                        return;
+                    }
+                    if (params1 != null) {
+                        saveLayer(activeLayer, params1);
+                    }
+                    panel1.close();
+                });
+                winManager.showWindow(panelController.asJComponent(), i18nManager.getTranslation("edit_route_calibration"),
+                        WindowManager.MODE.WINDOW);
+            });
+            winManager.showWindow(panelSelectId.asJComponent(), i18nManager.getTranslation("edit_route_calibration"),
+                WindowManager.MODE.WINDOW);
+        }
+    }
+
+    public void initialize() {
+        registerIcons();
+    }
+
+    public boolean isEnabled() {
+        IView view = getActiveView();
+        if (view!=null){
+            FLyrVect activeLayer = getActiveLayer(view);
+            if (panelSelectId == null && panelController == null && activeLayer!=null && activeLayer.isEditing()){
+                return JLrsUtils.isMlayerWithNonGeomField(activeLayer);
+            }
+        }
+        return false;
+    }
+
+    public boolean isVisible() {
+        ApplicationManager application = ApplicationLocator.getManager();
+
+        return application.getActiveComponent(ViewDocument.class) != null;
+    }
+
+    private void registerIcons() {
+        IconThemeHelper.registerIcon("lrs", "pk_cian", this);
+    }
+
+
+    private IView getActiveView() {
+        ApplicationManager application = ApplicationLocator.getManager();
+        IView view = (IView) application.getActiveComponent(ViewDocument.class);
+        return view;
+    }
+
+    private FLyrVect getActiveLayer(IView vista) {
+        if (vista != null) {
+            ViewDocument viewDocument = vista.getViewDocument();
+            FLayer[] actives =
+                viewDocument.getMapContext().getLayers().getActives();
+
+            if ((actives.length == 1) && (actives[0] instanceof FLyrVect)) {
+                return (FLyrVect) actives[0];
+            }
+        }
+        return null;
+    }
+
+    private boolean showWarnings(List<String> warnings){
+        final int MAXWARNINGSSHOWED=15;
+
+        final I18nManager i18nManager = ToolsLocator.getI18nManager();
+        logger.debug("Warnings found accepting edit route panel");
+        StringBuilder messageBuilder= new StringBuilder().append(i18nManager.getTranslation("warnings_in_edit_route"));
+        String newLine=System.getProperty("line.separator");
+        messageBuilder.append(newLine);
+        for (int i=0;(i<=MAXWARNINGSSHOWED&&i<warnings.size());i++){
+            if(i<MAXWARNINGSSHOWED){
+                String warning=warnings.get(i);
+                messageBuilder.append(newLine);
+                messageBuilder.append(warning);
+            }
+            if (i==MAXWARNINGSSHOWED&&warnings.size()>MAXWARNINGSSHOWED){
+                messageBuilder.append(newLine);
+                int warningsNotShowed=warnings.size()-MAXWARNINGSSHOWED;
+                messageBuilder.append(MessageFormat.format(
+                    i18nManager.getTranslation("more_warnings_found"), warningsNotShowed));
+            }
+        }
+        messageBuilder.append(newLine);
+        messageBuilder.append(newLine).append(i18nManager.getTranslation("accept_warnings_question"));
+        int result =JOptionPane.showConfirmDialog(
+            null,
+            messageBuilder,
+            i18nManager.getTranslation("warnings_dialog"), JOptionPane.YES_NO_OPTION);
+        return (result==JOptionPane.YES_OPTION);
+    }
+
+    private void saveLayer(FLyrVect activeLayer,LrsEditRouteCalibrationAlgorithmParams params){
+        FeatureAttributeDescriptor fieldRoute=params.getIdRouteField();
+        String routeName=params.getSelectedRouteName();
+        Map<FeatureReference, List<Double>> modifiedMCoordinates = params.getModifiedMCoordinates();
+        
+
+        FeatureStore featureStore=activeLayer.getFeatureStore();
+        if (!featureStore.isEditing()){
+            throw new IllegalArgumentException();
+        }
+        try {
+            for (Map.Entry<FeatureReference, List<Double>> entry : modifiedMCoordinates.entrySet()) {
+                FeatureReference fref = entry.getKey();
+                List<Double> mCoordinates = entry.getValue();
+                Feature f = fref.getFeature();
+                Geometry geom = f.getDefaultGeometry().cloneGeometry();
+                int k = 0;
+                if (geom.getGeometryType().isTypeOf(Geometry.TYPES.LINE)) {
+                    Line line = (Line) geom;
+                    for (int i = 0; i < line.getNumVertices(); i++) {
+                        line.setCoordinateAt(i, line.getDimension() - 1, mCoordinates.get(k++));
+                    }
+                } else if (geom.getGeometryType().isTypeOf(Geometry.TYPES.MULTILINE)) {
+                    MultiLine multiline = (MultiLine) geom;
+                    for (int i = 0; i < multiline.getPrimitivesNumber(); i++) {
+                        Line line = (Line) multiline.getPrimitiveAt(i);
+                        for (int j = 0; j < line.getNumVertices(); j++) {
+                            line.setCoordinateAt(j, line.getDimension() - 1, mCoordinates.get(k++));
+                        }
+                    }
+                }
+                EditableFeature ef = f.getEditable();
+                ef.setDefaultGeometry(geom);
+                featureStore.update(ef);
+            }
+
+        } catch (DataException e) {
+            logger.error("Error saving modified layer",e);
+        }
+    }
+
+    @Override
+    public void componentResized(ComponentEvent e) {
+        // TODO Auto-generated method stub
+
+    }
+
+    @Override
+    public void componentMoved(ComponentEvent e) {
+        // TODO Auto-generated method stub
+
+    }
+
+    @Override
+    public void componentShown(ComponentEvent e) {
+        // TODO Auto-generated method stub
+
+    }
+
+    @Override
+    public void componentHidden(ComponentEvent e) {
+        Component component = e.getComponent();
+        if (component == panelSelectId) {
+            panelSelectId = null;
+        } else if (component == panelController) {
+            panelController = null;
+        } else {
+            if (panelSelectId != null && panelSelectId.getParent() == component) {
+                panelSelectId = null;
+            } else if (panelController != null && panelController.getParent() == component) {
+                panelController.close();
+                panelController = null;
+
+            }
+        }
+    }
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig/lrs/app/generatedynamicsegmentation/GenerateDynamicSegmentationExtension.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig/lrs/app/generatedynamicsegmentation/GenerateDynamicSegmentationExtension.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig/lrs/app/generatedynamicsegmentation/GenerateDynamicSegmentationExtension.java	(revision 950)
@@ -0,0 +1,260 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.app.generatedynamicsegmentation;
+
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.swing.JOptionPane;
+
+import org.apache.commons.lang3.StringUtils;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import org.gvsig.andami.IconThemeHelper;
+import org.gvsig.andami.plugins.Extension;
+import org.gvsig.app.ApplicationLocator;
+import org.gvsig.app.ApplicationManager;
+import org.gvsig.app.project.documents.Document;
+import org.gvsig.app.project.documents.table.TableDocument;
+import org.gvsig.app.project.documents.table.TableManager;
+import org.gvsig.app.project.documents.view.ViewDocument;
+import org.gvsig.app.project.documents.view.gui.IView;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.store.shp.SHPNewStoreParameters;
+import org.gvsig.fmap.mapcontext.MapContextLocator;
+import org.gvsig.fmap.mapcontext.MapContextManager;
+import org.gvsig.fmap.mapcontext.exceptions.LoadLayerException;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+import org.gvsig.fmap.mapcontext.layers.operations.LayerCollection;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.lrs.lib.api.LrsAlgorithm;
+import org.gvsig.lrs.lib.api.LrsAlgorithmsLocator;
+import org.gvsig.lrs.lib.api.LrsAlgorithmsManager;
+import org.gvsig.lrs.lib.api.LrsGenerateDynamicSegmentationAlgorithmParams;
+import org.gvsig.lrs.lib.api.exceptions.LrsGettingParametersException;
+import org.gvsig.lrs.lib.api.exceptions.LrsNeededParameterException;
+import org.gvsig.lrs.swing.api.JLrsAlgorithmParams;
+import org.gvsig.lrs.swing.api.JLrsProgressDialog;
+import org.gvsig.lrs.swing.api.LrsAlgorithmsSwingLocator;
+import org.gvsig.lrs.swing.api.LrsAlgorithmsSwingManager;
+import org.gvsig.lrs.swing.impl.JLrsGenerateDynamicSegmentationParamsController;
+import org.gvsig.lrs.swing.impl.JLrsUtils;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.i18n.I18nManager;
+import org.gvsig.tools.swing.api.ToolsSwingLocator;
+import org.gvsig.tools.swing.api.windowmanager.WindowManager;
+import org.gvsig.tools.task.SimpleTaskStatus;
+
+
+/**
+ * @author dmartinez
+ *
+ */
+public class GenerateDynamicSegmentationExtension extends Extension {
+
+    private static final Logger logger = LoggerFactory.getLogger(GenerateDynamicSegmentationExtension.class);
+
+    /* (non-Javadoc)
+     * @see org.gvsig.andami.plugins.IExtension#execute(java.lang.String)
+     */
+    public void execute(String actionCommand) {
+        if (StringUtils.equalsIgnoreCase(actionCommand, "generate-dynamic-segmentation")) {
+            IView view = getActiveView();
+            FLayers layers = view.getMapControl().getMapContext().getLayers();
+            List<FeatureStore> tables=getTables();
+
+
+            final WindowManager winManager = ToolsSwingLocator.getWindowManager();
+
+            final LrsAlgorithmsSwingManager manager = LrsAlgorithmsSwingLocator.getLrsAlgorithmsSwingManager();
+
+            final I18nManager i18nManager = ToolsLocator.getI18nManager();
+
+            JLrsGenerateDynamicSegmentationParamsController panel;
+            try {
+                panel = (JLrsGenerateDynamicSegmentationParamsController)manager.createJLrsGenerateDynamicSegmentationAlgorithmParameters(layers,tables, null);
+            } catch (LrsNeededParameterException e2) {
+                logger.error("Error creating panel", e2);
+                JOptionPane.showMessageDialog(
+                    null,
+                    new StringBuilder().append(i18nManager.getTranslation("error_creating_panel"))
+                        .append(":").append(e2.getLocalizedMessage()),
+                    i18nManager.getTranslation("error"), JOptionPane.ERROR_MESSAGE);
+                return;
+            }
+            panel.setVisibleAceptCancel(true);
+            panel.addActionListener(new ActionListener() {
+
+                public void actionPerformed(ActionEvent e) {
+                    JLrsAlgorithmParams panel = (JLrsAlgorithmParams) e.getSource();
+                    if (panel.isCanceled()) {
+                        return;
+                    }
+                    LrsGenerateDynamicSegmentationAlgorithmParams params = null;
+                    try {
+                        params = (LrsGenerateDynamicSegmentationAlgorithmParams)panel.getParams();
+                    } catch (LrsGettingParametersException e1) {
+                        logger.error("Error getting parameters", e1);
+                        JOptionPane.showMessageDialog(
+                            null,
+                            new StringBuilder().append(i18nManager.getTranslation("error_getting_parameters"))
+                                .append(":").append(e1.getLocalizedMessage()),
+                            i18nManager.getTranslation("error"), JOptionPane.ERROR_MESSAGE);
+                        return;
+                    } catch (LrsNeededParameterException e1) {
+                        logger.warn("Error getting parameters", e1);
+                        JOptionPane.showMessageDialog(
+                            null,
+                            i18nManager.getTranslation(e1.getMessage()),
+                            i18nManager.getTranslation("warning"), JOptionPane.WARNING_MESSAGE);
+                        return;
+                    }
+
+                    LrsAlgorithmsManager algorithmsManager = LrsAlgorithmsLocator.getLrsAlgorithmsManager();
+                    final LrsAlgorithm algorithm = algorithmsManager.createLrsAlgorithm(params);
+                    final SHPNewStoreParameters shpParams=(SHPNewStoreParameters)params.getNewFeatureStoreParameters();
+
+                    final SimpleTaskStatus taskStatus =
+                        ToolsLocator.getTaskStatusManager().createDefaultSimpleTaskStatus(i18nManager.getTranslation("progress"));
+
+                    final JLrsProgressDialog progressDialog = manager.createJLrsProgressDialog(taskStatus);
+
+                    winManager.showWindow(progressDialog.asJComponent(), i18nManager.getTranslation("generate_dynamic_segmentation"),
+                        WindowManager.MODE.WINDOW);
+
+                    Thread task = new Thread(new Runnable() {
+
+                        public void run() {
+                            try {
+                                algorithm.execute(taskStatus);
+                                int resultLoadLayer =JOptionPane.showConfirmDialog(
+                                    null,
+                                    i18nManager.getTranslation("load_layer_question"),
+                                    i18nManager.getTranslation("load_layer_question_title"), JOptionPane.YES_NO_OPTION);
+                                if (resultLoadLayer==JOptionPane.YES_OPTION){
+                                    loadLayer(shpParams);
+                                }
+
+                            } catch (Exception e) {
+                                logger.error("Error generating dynamic segmentation ", e);
+                                String message = e.getMessage();
+                                if (e.getCause() != null) {
+                                    message = e.getCause().getMessage();
+                                }
+                                JOptionPane.showMessageDialog(
+                                    progressDialog.asJComponent(),
+                                    message,
+                                    i18nManager.getTranslation("generate_dynamic_segmentation"),
+                                    JOptionPane.ERROR_MESSAGE
+                                );
+                            }
+                        }
+                    });
+                    task.start();
+
+                }
+            });
+            winManager.showWindow(panel.asJComponent(), i18nManager.getTranslation("generate_dynamic_segmentation"),
+                WindowManager.MODE.WINDOW);
+        }
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.andami.plugins.IExtension#initialize()
+     */
+    public void initialize() {
+        registerIcons();
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.andami.plugins.IExtension#isEnabled()
+     */
+    public boolean isEnabled() {
+        IView view = getActiveView();
+        if (view!=null){
+            ViewDocument viewDocument = view.getViewDocument();
+            LayerCollection layers = viewDocument.getMapContext().getLayers();
+            if (JLrsUtils.validateMLayerWithNonGeomField(layers)){
+                List<FeatureStore> tables=getTables();
+                if (tables!=null&&tables.size()>0){
+                    return JLrsUtils.validateStoreWithFieldsAndOneNumeric(tables);
+                }
+            }
+        }
+        return false;
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.andami.plugins.IExtension#isVisible()
+     */
+    public boolean isVisible() {
+        ApplicationManager application = ApplicationLocator.getManager();
+
+        return application.getActiveComponent(ViewDocument.class) != null;
+    }
+
+    private void registerIcons() {
+        IconThemeHelper.registerIcon("lrs", "pk_yellow", this);
+    }
+
+    private List<FeatureStore> getTables(){
+        ApplicationManager application = ApplicationLocator.getManager();
+        List<Document> documents=application.getCurrentProject().getDocuments(TableManager.TYPENAME);
+        List<FeatureStore> tables=new ArrayList<FeatureStore>();
+        if (documents!=null){
+            for (int i = 0; i < documents.size(); i++) {
+                TableDocument tableDocument=(TableDocument)documents.get(i);
+                tables.add(tableDocument.getStore());
+            }
+        }
+        return tables;
+    }
+
+    private IView getActiveView() {
+        ApplicationManager application = ApplicationLocator.getManager();
+        IView view = (IView) application.getActiveComponent(ViewDocument.class);
+        return view;
+    }
+
+    private void loadLayer(SHPNewStoreParameters shpParams){
+        if (shpParams!=null ){
+            String name=shpParams.getFile().getName();
+            if (name.contains(".shp")){
+                name=name.substring(0,name.lastIndexOf(".shp"));
+            }
+            MapContextManager mapContextManager =MapContextLocator.getMapContextManager();
+
+            FLyrVect newLayer=null;
+            try {
+                newLayer = (FLyrVect) mapContextManager.createLayer(name,shpParams);
+            } catch (LoadLayerException e) {
+                logger.warn("Couldn't load layer",e);
+            }
+            getActiveView().getMapControl().getMapContext().getLayers().addLayer(newLayer);
+        }
+    }
+
+}

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig/lrs/app
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig/lrs
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org/gvsig
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java/org
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/java
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath


Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/plugin-persistence.def
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/plugin-persistence.def	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/plugin-persistence.def	(revision 950)
@@ -0,0 +1,17 @@
+<?xml version="1.0"?>
+<!--
+Definitions of plugin persistence org.gvsig.lrs.app.mainplugin
+ -->
+<definitions>
+  <version>1.0.0</version>
+  <classes>
+    <class name="org.gvsig.lrs.app.mainplugin">
+      <extends>
+      	<class name="JLrsCalculateMLastUsedValues"/>
+      </extends>
+      <description>Persistence of the LRS plugin</description>
+      <fields>
+      </fields>
+    </class>
+  </classes>
+</definitions>  
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/i18n/text.properties
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/i18n/text.properties	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/i18n/text.properties	(revision 950)
@@ -0,0 +1,142 @@
+#text.properties
+
+error_creating_panel=Error creando el panel
+
+# CREATE ROUTE
+length=Longitud
+one_field=Un campo
+two_fields=Dos campos
+up_left=Arriba izquierda
+down_left=Abajo izquierda
+up_right=Arriba derecha
+down_right=Abajo derecha
+create_routes=Crear rutas
+source=Origen
+m-coordinate-selector=Selecciona geometrias para calcular su coordenada M
+calculate-m-routes=Calcular coordenada M
+id_route_field=Campo de identificadores de rutas
+pk_selected=Campos con los valores de la coordenada M en los extremos
+pk_inicial=Valor inicial
+pk_final=Valor final
+output_file=Archivo de salida
+measure_source=Origen de mediciones
+from_measure_field=Campo desde o longitud
+to_measure_field=Campo hasta
+coordinates_priority=Prioridad de coordenadas
+measure_factor=Factor de medici\u00f3n
+measure_offset=Compensaci\u00f3n de medici\u00f3n
+ignore_spatial_gaps=Ignorar huecos espaciales
+_Browser=Navegador
+_Accept=Aceptar
+_Cancel=Cancelar
+_Close=Cerrar
+linear_reference_system=Ref. lineal
+progress=Progreso
+error_getting_parameters=Error obteniendo los par\u00e1metros del algoritmo
+need_to_select_a_route_identifier_field=Es necesario seleccionar un campo de identificadores de rutas
+paratemeters=Parametros
+_LrsNeededParameterException=Falta alguno de los par\u00e1metros necesarios.
+need_to_fill_the_target_path=Es necesario rellenar la ruta al archivo de salida
+need_to_select_a_length_measure_field=Es necesario seleccionar un campo para las medidas
+need_to_select_a_from_measure_field=Es necesario seleccionar un campo para las medidas o desde el que comenzarlas
+need_to_select_a_to_measure_field=Es necesario seleccionar un campo hasta el que terminar las medidas
+file_already_exists_do_you_want_overwrite_it=El archivo ya existe \u00bfDesea sobrescribirlo?
+grouping_features=Agrupando elementos
+at_least_one_layer_needed=Es necesaria al menos una capa
+impossible_to_find_needed_layer=No se ha podido encontrar la capa necesaria
+error_creating_outputStore=Error creando el almac\u00e9n de salida
+load_layer_question=\u00bfLe gustar\u00eda cargar la capa generada?
+load_layer_question_title=\u00bfCargar Capa?
+
+#CALIBRATE ROUTE
+calibrate_point_layer=Capa de puntos de calibraci\u00f3n
+id_calibration_point_route_field=Identificador de ruta en la capa de puntos
+measures_field=Campo de medidas
+measure_calc_method=M\u00e9todo de c\u00e1lculo de mediciones
+search_radius=Radio de b\u00fasqueda
+interpolate_between_calibration_points=Interpolar entre puntos de calibraci\u00f3n
+units=Unidades
+extrapolate_before_calibration_points=Extrapolar antes de puntos de calibraci\u00f3n
+extrapolate_after_calibration_points=Extrapolar despu\u00e9s de puntos de calibraci\u00f3n
+include_all=Incluir todos los elementos en la capa de salida
+distance=Distancia
+measures=Medidas
+calibrate_routes=Calibrar rutas
+two_or_more_layers_are_needed=Son necesarias dos o mas capas
+impossible_to_find_needed_layers=No fue posible encontrar las capas necesarias
+error_getting_selected_item_from_cmbInputLayer=Error obteniendo el valor seleccionado del origen
+error_getting_selected_item_from_cmbIdRouteField=Error obteniendo el valor seleccionado del identificador de rutas
+need_to_select_a_source_layer=Es necesario seleccionar un campo para el origen
+error_getting_selected_item_from_cmbCalibratePointLayer=Error obteniendo la capa de puntos de calibraci\u00f3n
+need_to_select_a_calibrate_point_layer=Es necesario seleccionar un campo para la capa de puntos de calibraci\u00f3n
+error_getting_selected_item_from_cmbCalibrationPointIdRouteField=Error obteniendo el valor seleccionado del identificador de rutas de la capa de calibraci\u00f3n
+need_to_select_a_route_identifier_calibration_point_field=Es necesario seleccionar un campo para el identificador de rutas de la capa de calibraci\u00f3n
+error_getting_selected_item_from_cmbFromMeasureField=Error obteniendo el valor seleccionado del campo desde
+need_to_select_a_from_Measure_field=Es necesario seleccionar un valor desde
+calibrating_features=Calibrando elementos
+kilometer=kil\u00f3metro
+meter=metro
+centimeter=cent\u00edmetro
+millimeter=mil\u00edmetro
+mile=milla
+yards=yardas
+feet=pies
+inch=pulgada
+
+#EDIT ROUTE
+a_layer_is_needed=Es necesaria una capa
+an_editing_layer_is_needed=Es necesaria una capa editable
+impossible_to_find_needed_layer=No fue posible encontrar una capa necesaria
+edit_route_calibration=Editar calibraci\u00f3n de ruta
+error_getting_table_info=Error obteniendo la tabla de informaci\u00f3n
+
+minimum=M\u00ednimo
+maximum=M\u00e1ximo
+_Invert=Invertir
+_Apply=Aplicar
+a_selectedIdRoute_is_needed=Es necesario un identificador de ruta seleccionado
+route_not_contained=El identificador de ruta no esta contenido en la capa en edici\u00f3n
+
+warnings_in_edit_route=Se han encontrado las siguientes advertencias en la tabla de edici\u00f3n:
+accept_warnings_question=\u00bfEsta seguro de que desea continuar guardando estos datos?
+warnings_dialog=Di\u00e1logo de Advertencias Encontradas
+more_warnings_found=...y {0} advertencias mas encontradas
+warn_Not_data_found_in_table=La tabla de edici\u00f3n no tiene datos
+warn_Not_enough_data_found_in_table=La tabla de edici\u00f3n no tiene datos suficientes
+warn_Negative_value_at_row=Un dato negativo ha sido encontrado en la fila {0}
+warn_Out_of_sequence_value_at_row=El valor en la fila {0} esta fuera de secuencia
+warn_Repeated_value_at_row=Valores repetidos en las filas {0} y {1}
+
+
+#GENERATE DYNAMIC SEGMENTATION
+generate_dynamic_segmentation=Generar segmentaci\u00f3n din\u00e1mica
+table=Tabla de Valores
+table_id_route_field=Identificador de ruta en la tabla de valores
+landmark_field=Hito
+final_landmark_field=Hito final
+value_field=Valor
+a_table_is_needed=Es necesaria una tabla
+error_getting_selected_item_from_cmbTable=Error obteniendo el valor seleccionando de la tabla
+need_to_select_a_table=Es necesario seleccionar un campo para el valor de la tabla
+error_getting_selected_item_from_cmbTableIdRouteField=Error obteniendo el valor seleccionando el identificador de ruta de la tabla
+error_getting_selected_item_from_cmbLandmarkField=Error obteniendo el valor seleccionando del hito
+need_to_select_a_landmark_field=Es necesario seleccionar un campo para el valor del hito
+error_getting_selected_item_from_cmbFinalLandmarkField=Error obteniendo el valor seleccionando del hito final
+error_getting_selected_item_from_cmbValueField=Error obteniendo el valor seleccionando del campo de valor
+need_to_select_a_value_field=Es necesario seleccionar un campo para el valor
+
+#SHOW MEASURES
+at_least_a_line_needed=Al menos una l\u00ednea es necesaria
+show_measures=Mostrar medidas
+wiper_measures=Limpiar medidas
+
+_Data_units=Unidades de los datos
+_m=m
+_Km=Km
+_Unknown_slash_other=Desconocida / otras
+_Units_of_measure_of_the_M_coordinate_of_the_layer=Unidades de medida de la coordenada M de la capa
+
+_Stretch_{0}=Tramo {0}
+
+_Recalculate_proportionally=Recalcular proporcionalmente
+_Recalibrate=Recalibrar
\ No newline at end of file
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/i18n/text_en.properties
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/i18n/text_en.properties	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/i18n/text_en.properties	(revision 950)
@@ -0,0 +1,142 @@
+#text_en.properties
+
+error_creating_panel=Error creating panel
+
+# CREATE ROUTE
+length=Length
+one_field=One field
+two_fields=Two fields
+up_left=Up left
+down_left=Down left
+up_right=Up right
+down_right=Down right
+create_routes=Create Routes
+source=Source
+id_route_field=Route identifier field
+m-coordinate-selector=Select the geometries to calculate the M coodinate
+calculate-m-routes=Calculate M coordinate
+pk_selected=Fields to get the M coordinate values
+pk_inicial=Initial value
+pk_final=End value
+output_file=Output file
+measure_source=Measure source
+from_measure_field=From-measure or length field
+to_measure_field=To-measure field
+coordinates_priority=Coordinate priority
+measure_factor=Measure factor
+measure_offset=Measure offset
+ignore_spatial_gaps=Ignore spatial gaps
+_Browser=Browser
+_Accept=Ok
+_Cancel=Cancel
+_Close=Close
+linear_reference_system=Linear ref.
+progress=Progress
+error_getting_parameters=Error getting algorithm parameters
+need_to_select_a route_identifier_field=You need to select a route identifier field
+paratemeters=Parameters
+_LrsNeededParameterException=One or more of required parameters are empty
+need_to_fill_the_target_path=You need to fill the target file path
+need_to_select_a_length_measure_field=You need to select a length measure field
+need_to_select_a_from_measure_field=You need to select a from measure field
+need_to_select_a_to_measure_field=You need to select a to measure field
+file_already_exists_do_you_want_overwrite_it=File already exists. Do you want overwrite it?
+grouping_features=Grouping features
+at_least_one_layer_needed=At least one layer is needed
+impossible_to_find_needed_layer=Impossible to find needed layer
+error_creating_outputStore=Error creating output store
+load_layer_question=Would you like to load the generated layer?
+load_layer_question_title=Load Layer?
+
+#CALIBRATE ROUTE
+calibrate_point_layer=Calibration points layer
+id_calibration_point_route_field=Route identifier in calibration points layer
+measures_field=Measures field
+measure_calc_method=Measure calculations method
+search_radius=Search radius
+interpolate_between_calibration_points=Interpolate between calibration points
+units=Units
+extrapolate_before_calibration_points=Extrapolate before calibration points
+extrapolate_after_calibration_points=Extrapolate after calibration points
+include_all=Include all elements in output layer
+distance=Distance
+measures=Measures
+calibrate_routes=Calibrate routes
+two_or_more_layers_are_needed=Two or more layers are needed
+impossible_to_find_needed_layers=Impossible to find needed layers
+error_getting_selected_item_from_cmbInputLayer=Error getting selected item from source layer
+error_getting_selected_item_from_cmbIdRouteField=Error getting selected item from route identifier field
+need_to_select_a_source_layer=You need to select a source layer
+error_getting_selected_item_from_cmbCalibratePointLayer=Error getting selected item from calibration points layer
+need_to_select_a_calibrate_point_layer=You need to select a calibration points layer
+error_getting_selected_item_from_cmbCalibrationPointIdRouteField=Error getting selected item from route identifier in calibration points layer
+need_to_select_a_route_identifier_calibration_point_field=You need to select a route identifier field from calibration points layer
+error_getting_selected_item_from_cmbFromMeasureField=Error getting selected item from From-measure field
+need_to_select_a_from_Measure_field=You need to select a From-measure field
+calibrating_features=Calibrating features
+kilometer=kilometer
+meter=meter
+centimeter=centimeter
+millimeter=millimeter
+mile=mile
+yards=yards
+feet=feet
+inch=inch
+
+#EDIT ROUTE
+a_layer_is_needed=A layer is needed
+an_editing_layer_is_needed=An editing layer is needed
+impossible_to_find_needed_layer=Impossible to find a correct layer
+edit_route_calibration=Edit route calibration
+
+minimum=Minimum
+maximum=Maximum
+_Invert=Invert
+_Apply=Apply
+a_selectedIdRoute_is_needed=A selected route identifier is needed
+route_not_contained=Selected id route is not contained in editing layer
+error_getting_table_info=Error getting table info
+
+warnings_in_edit_route=Have been found the following warnings in the data table:
+accept_warnings_question=Are you sure you want to continue saving this data?
+warnings_dialog=Warnings Found Dialog
+more_warnings_found=...and {0} more warnings found
+warn_Not_data_found_in_table=The editing table has not data
+warn_Not_enough_data_found_in_table=The editing table has not enough data
+warn_Negative_value_at_row=A negative value has been found at row {0}
+warn_Out_of_sequence_value_at_row=Value at row {0} is out of sequence
+warn_Repeated_value_at_row=Repeated values in rows {0} and {1}
+
+
+#GENERATE DYNAMIC SEGMENTATION
+generate_dynamic_segmentation=Generate dynamic segmentation
+table=Value table
+table_id_route_field=Route identifier in value table
+landmark_field=Landmark
+final_landmark_field=Final Landmark
+value_field=Value
+a_table_is_needed=A table is needed
+error_getting_selected_item_from_cmbTable=Error getting selected item from table
+need_to_select_a_table=You need to select a table
+error_getting_selected_item_from_cmbTableIdRouteField=Error getting selected item from route identifier in value table
+error_getting_selected_item_from_cmbLandmarkField=Error getting selected item from landmark field
+need_to_select_a_landmark_field=You need to select a landmark field
+error_getting_selected_item_from_cmbFinalLandmarkField=Error getting selected item from final landmark field
+error_getting_selected_item_from_cmbValueField=Error getting selected item from value field
+need_to_select_a_value_field=You need to select a value field
+
+#SHOW MEASURES
+at_least_a_line_needed=At least a line is needed
+show_measures=Show Measures
+wiper_measures=Clean measures
+
+_Data_units=Data units
+_m=m
+_Km=Km
+_Unknown_slash_other=Unknown / other
+_Units_of_measure_of_the_M_coordinate_of_the_layer=Units of measure of the M coordinate of the layer
+
+_Stretch_{0}=Stretch {0}
+
+_Recalculate_proportionally=Recalculate proportionally
+_Recalibrate=Recalibrate
\ No newline at end of file

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/i18n
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath


Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/config.xml
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/config.xml	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/config.xml	(revision 950)
@@ -0,0 +1,109 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+<!-- gvSIG. Desktop Geographic Information System. Copyright (C) 2007-2013 gvSIG
+  Association. This program is free software; you can redistribute it and/or modify
+  it under the terms of the GNU General Public License as published by the Free Software
+  Foundation; either version 3 of the License, or (at your option) any later version.
+  This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
+  without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
+  PURPOSE. See the GNU General Public License for more details. You should have received
+  a copy of the GNU General Public License along with this program; if not, write to
+  the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
+  USA. For any additional information, do not hesitate to contact us at info AT gvsig.com,
+  or visit our website www.gvsig.com. -->
+<plugin-config>
+  <depends plugin-name="org.gvsig.app.mainplugin" />
+  <depends plugin-name="org.gvsig.app.document.table.app.mainplugin" />
+  <depends plugin-name="org.gvsig.shp.app.mainplugin" />
+  <resourceBundle name="text" />
+  <libraries library-dir="lib" />
+  <extensions>
+    <extension class-name="org.gvsig.lrs.app.createroute.CreateRouteExtension"
+      description="" active="true" priority="1">
+
+      <action name="create-routes" label="create_routes" tooltip="create_routes"
+        position="900700100" action-command="create-routes" icon="pk_red"
+        accelerator="" />
+
+      <menu text="tools/linear_reference_system/create_routes" name="create-routes" />
+
+      <tool-bar name="linear_reference_system" position="900700100">
+        <action-tool name="create-routes" />
+      </tool-bar>
+
+    </extension>
+    <extension class-name="org.gvsig.lrs.app.calibrateroute.CalibrateRouteExtension"
+      description="" active="true" priority="1">
+
+      <action name="calibrate-routes" label="calibrate_routes" tooltip="calibrate_routes"
+        position="900700200" action-command="calibrate-routes" icon="pk_blue"
+        accelerator="" />
+
+      <menu text="tools/linear_reference_system/calibrate_routes" name="calibrate-routes" />
+
+      <tool-bar name="linear_reference_system" position="900700200">
+        <action-tool name="calibrate-routes" />
+      </tool-bar>
+      
+      
+    </extension>
+    <extension class-name="org.gvsig.lrs.app.calibrateroute.MeasureCalculatorRouteExtension"
+      description="" active="true" priority="2">
+      
+      <action name="calculate-m-routes" label="calculate-m-routes" tooltip="calculate-m-routes"
+        position="900700300" action-command="calculate-m-routes" icon="pk_m"
+        accelerator="" />
+
+      <menu text="tools/linear_reference_system/calculate-m-routes" name="calculate-m-routes" />
+
+      <tool-bar name="linear_reference_system" position="900700300">
+        <action-tool name="calculate-m-routes" />
+      </tool-bar>
+
+    </extension>
+
+    <extension class-name="org.gvsig.lrs.app.editroutecalibration.EditRouteCalibrationExtension"
+      description="" active="true" priority="1">
+      <action name="edit-route-calibration" label="edit_route_calibration" tooltip="edit_route_calibration"
+        position="900700400" action-command="edit-route-calibration" icon="pk_cian"
+        accelerator="" />
+      <menu text="tools/linear_reference_system/edit_route_calibration" name="edit-route-calibration" />
+      <tool-bar name="linear_reference_system" position="900700400">
+        <action-tool name="edit-route-calibration" />
+      </tool-bar>
+    </extension>
+
+    <extension class-name="org.gvsig.lrs.app.generatedynamicsegmentation.GenerateDynamicSegmentationExtension"
+      description="" active="true" priority="1">
+      <action name="generate-dynamic-segmentation" label="generate_dynamic_segmentation" tooltip="generate_dynamic_segmentation"
+        position="900700500" action-command="generate-dynamic-segmentation" icon="pk_yellow"
+        accelerator="" />
+      <menu text="tools/linear_reference_system/generate_dynamic_segmentation" name="generate-dynamic-segmentation" />
+      <tool-bar name="linear_reference_system" position="900700500">
+        <action-tool name="generate-dynamic-segmentation" />
+      </tool-bar>
+    </extension>
+
+    <extension class-name="org.gvsig.lrs.app.showmeasures.ShowMeasuresExtension"
+      description="" active="true" priority="1">
+      <action name="show-measures" label="show_measures" tooltip="show_measures"
+        position="900700600" action-command="show-measures" icon="pk_green"
+        accelerator="" />
+      <menu text="tools/linear_reference_system/show_measures" name="show-measures" />
+      <tool-bar name="linear_reference_system" position="900700600">
+        <action-tool name="show-measures" />
+      </tool-bar>
+    </extension>
+
+    <extension class-name="org.gvsig.lrs.app.showmeasures.WiperMeasuresExtension"
+      description="" active="true" priority="1">
+      <action name="wiper-measures" label="wiper_measures" tooltip="wiper_measures"
+        position="900700700" action-command="wiper-measures" icon="wiper"
+        accelerator="" />
+      <menu text="tools/linear_reference_system/wiper_measures" name="wiper-measures" />
+      <tool-bar name="linear_reference_system" position="900700700">
+        <action-tool name="wiper-measures" />
+      </tool-bar>
+    </extension>
+
+  </extensions>
+</plugin-config>
\ No newline at end of file
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/images/lrs/pk_green.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/images/lrs/pk_green.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/images/lrs/pk_blue.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/images/lrs/pk_blue.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/images/lrs/pk_cian.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/images/lrs/pk_cian.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/images/lrs/pk_red.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/images/lrs/pk_red.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/images/lrs/pk_yellow.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/images/lrs/pk_yellow.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/images/lrs/pk_m.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/images/lrs/pk_m.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream

Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/images/lrs/wiper.png
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/images/lrs/wiper.png
___________________________________________________________________
Added: svn:mime-type
   + application/octet-stream


Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/images/lrs
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin/images
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources-plugin
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main/resources
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src/main
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/src
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath


Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/pom.xml
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/pom.xml	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin/pom.xml	(revision 950)
@@ -0,0 +1,53 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+  <parent>
+    <groupId>org.gvsig</groupId>
+    <artifactId>org.gvsig.lrs.app</artifactId>
+    <version>1.0.173</version>
+  </parent>
+  <artifactId>org.gvsig.lrs.app.mainplugin</artifactId>
+  <packaging>jar</packaging>
+  <name>${project.artifactId}</name>
+    <properties>
+    <!-- Package info property values -->
+    <gvsig.package.info.state>testing</gvsig.package.info.state>
+    <gvsig.package.info.dependencies>required: org.gvsig.app.mainplugin -ge 2.3.0-A</gvsig.package.info.dependencies>
+    <gvsig.package.info.official>true</gvsig.package.info.official>
+    <gvsig.package.info.name>Linear reference system</gvsig.package.info.name>
+    <gvsig.package.info.description>Provides tools to manage linear reference system.</gvsig.package.info.description>
+    <gvsig.package.info.categories>Vector</gvsig.package.info.categories>
+    <gvsig.package.info.javaVM>j1_6</gvsig.package.info.javaVM>
+    <gvsig.package.info.poolURL>https://devel.gvsig.org/download/projects/gvsig-lrs/pool</gvsig.package.info.poolURL>
+  </properties>
+
+  <dependencies>
+    <dependency>
+      <groupId>org.gvsig</groupId>
+      <artifactId>org.gvsig.andami</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.gvsig</groupId>
+      <artifactId>org.gvsig.lrs.swing.api</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.gvsig</groupId>
+      <artifactId>org.gvsig.lrs.lib.api</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.gvsig</groupId>
+      <artifactId>org.gvsig.lrs.lib.impl</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.gvsig</groupId>
+      <artifactId>org.gvsig.lrs.swing.impl</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.gvsig</groupId>
+      <artifactId>org.gvsig.app.mainplugin</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.gvsig</groupId>
+      <artifactId>org.gvsig.app.document.table.app.mainplugin</artifactId>
+    </dependency>
+  </dependencies>
+</project>

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/org.gvsig.lrs.app.mainplugin
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath
target

.project



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/src/site
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/src
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath


Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/pom.xml
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/pom.xml	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app/pom.xml	(revision 950)
@@ -0,0 +1,15 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+  <parent>
+    <groupId>org.gvsig</groupId>
+    <artifactId>org.gvsig.lrs</artifactId>
+    <version>1.0.173</version>
+  </parent>
+  <artifactId>org.gvsig.lrs.app</artifactId>
+  <packaging>pom</packaging>
+  <name>${project.artifactId}</name>
+  <modules>
+    <module>org.gvsig.lrs.app.mainplugin</module>
+  </modules>
+
+</project>
\ No newline at end of file

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.app
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath

.project


Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/resources/META-INF/services/org.gvsig.tools.library.Library
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/resources/META-INF/services/org.gvsig.tools.library.Library	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/resources/META-INF/services/org.gvsig.tools.library.Library	(revision 950)
@@ -0,0 +1 @@
+org.gvsig.lrs.lib.impl.DefaultLrsAlgorithmsLibrary
\ No newline at end of file

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/resources/META-INF/services
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/resources/META-INF
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/resources
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath


Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultLrsCreateRouteAlgorithmParams.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultLrsCreateRouteAlgorithmParams.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultLrsCreateRouteAlgorithmParams.java	(revision 950)
@@ -0,0 +1,231 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.lib.impl;
+
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.feature.NewFeatureStoreParameters;
+import org.gvsig.lrs.lib.api.LrsCoordinatesPriority;
+import org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsSourceOfMeasures;
+
+
+/**
+ * @author fdiaz
+ *
+ */
+public class DefaultLrsCreateRouteAlgorithmParams implements LrsCreateRouteAlgorithmParams {
+
+    private FeatureStore sourceFeatureStore;
+    private FeatureAttributeDescriptor idRouteField;
+    private NewFeatureStoreParameters newFeatureStoreParameters;
+    private LrsSourceOfMeasures sourceOfMeasures;
+    private FeatureAttributeDescriptor fromMeasureField;
+    private FeatureAttributeDescriptor toMeasureField;
+    private LrsCoordinatesPriority coordinatePriority;
+    private double measureFactor = 1.0;
+    private double measureOffset = 0.0;
+    private boolean ignoreSpatialGaps;
+    private final String NAME = "LrsCreateRouteAlgorithm";
+    private final String DESCRIPTION = "Algorithm to create routes with linear reference system.";
+
+
+
+    /**
+     *
+     */
+    public DefaultLrsCreateRouteAlgorithmParams() {
+        measureFactor = 1.0;
+        measureOffset = 0.0;
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithmParams#getName()
+     */
+    public String getName() {
+        return NAME;
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithmParams#getDescription()
+     */
+    public String getDescription() {
+        return DESCRIPTION;
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#getSourceFeatureStore()
+     */
+    public FeatureStore getSourceFeatureStore() {
+        return sourceFeatureStore;
+    }
+
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#setSourceFeatureStore(org.gvsig.fmap.dal.feature.FeatureStore)
+     */
+    public void setSourceFeatureStore(FeatureStore sourceFeatureStore) {
+        this.sourceFeatureStore = sourceFeatureStore;
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#getIdRouteField()
+     */
+    public FeatureAttributeDescriptor getIdRouteField() {
+        return idRouteField;
+    }
+
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#setIdRouteField(org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor)
+     */
+    public void setIdRouteField(FeatureAttributeDescriptor idRouteField) {
+        this.idRouteField = idRouteField;
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#getSourceOfMeasures()
+     */
+    public LrsSourceOfMeasures getSourceOfMeasures() {
+        return sourceOfMeasures;
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#setSourceOfMeasures(org.gvsig.lrs.lib.api.SourceOfMeasures)
+     */
+    public void setSourceOfMeasures(LrsSourceOfMeasures sourceOfMeasures) {
+        this.sourceOfMeasures = sourceOfMeasures;
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#getFromMeasureField()
+     */
+    public FeatureAttributeDescriptor getFromMeasureField() {
+        return fromMeasureField;
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#setFromMeasureField(org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor)
+     */
+    public void setFromMeasureField(FeatureAttributeDescriptor fromMeasureField) {
+        this.fromMeasureField = fromMeasureField;
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#getToMeasureField()
+     */
+    public FeatureAttributeDescriptor getToMeasureField() {
+        return toMeasureField;
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#setToMeasureField(org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor)
+     */
+    public void setToMeasureField(FeatureAttributeDescriptor toMeasureField) {
+        this.toMeasureField = toMeasureField;
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#getCoordinatePriority()
+     */
+    public LrsCoordinatesPriority getCoordinatePriority() {
+        return coordinatePriority;
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#setCoordinatePriority(org.gvsig.lrs.lib.api.CoordinatesPriority)
+     */
+    public void setCoordinatePriority(LrsCoordinatesPriority coordinatePriority) {
+        this.coordinatePriority = coordinatePriority;
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#getMeasureFactor()
+     */
+    public double getMeasureFactor() {
+        return measureFactor;
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#setMeasureFactor(double)
+     */
+    public void setMeasureFactor(double measureFactor) {
+        this.measureFactor = measureFactor;
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#getMeasureOffset()
+     */
+    public double getMeasureOffset() {
+        return measureOffset;
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#setMeasureOffset(double)
+     */
+    public void setMeasureOffset(double measureOffset) {
+        this.measureOffset = measureOffset;
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#isIgnoreSpatialGaps()
+     */
+    public boolean ignoreSpatialGaps() {
+        return ignoreSpatialGaps;
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#setIgnoreSpatialGaps(boolean)
+     */
+    public void setIgnoreSpatialGaps(boolean ignoreSpatialGaps) {
+        this.ignoreSpatialGaps = ignoreSpatialGaps;
+    }
+
+    public NewFeatureStoreParameters getNewFeatureStoreParameters() {
+        return this.newFeatureStoreParameters;
+    }
+
+    public void setNewFeatureStoreParameters(
+        NewFeatureStoreParameters newFeatureStoreParameters) {
+        this.newFeatureStoreParameters = newFeatureStoreParameters;
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultMeasuresCalculator.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultMeasuresCalculator.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultMeasuresCalculator.java	(revision 950)
@@ -0,0 +1,504 @@
+package org.gvsig.lrs.lib.impl;
+
+import org.gvsig.lrs.lib.api.MeasuresCalculator;
+import java.util.ArrayList;
+import java.util.List;
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.geom.GeometryLocator;
+import org.gvsig.fmap.geom.GeometryManager;
+import org.gvsig.fmap.geom.operation.GeometryOperationException;
+import org.gvsig.fmap.geom.operation.GeometryOperationNotSupportedException;
+import org.gvsig.fmap.geom.primitive.Line;
+import org.gvsig.fmap.geom.primitive.Point;
+import org.gvsig.lrs.lib.api.LrsMeasureCalculationMethods;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+class DefaultMeasuresCalculator implements MeasuresCalculator {
+
+    private static final Logger logger = LoggerFactory.getLogger(DefaultMeasuresCalculator.class);
+
+    private Geometry route;
+    private List<Boolean> isFixedPoint;
+    private List<Double> distances;
+    private List<Double> oldMValues;
+    private List<Point> vertices;
+    private List<Integer> lineIndexes;
+    private int MDIMENSION;
+
+    private final Double PRECISION = new Double(1.0e-5);
+
+    @Override
+    public Geometry getResult() {
+        return route;
+    }
+
+    public DefaultMeasuresCalculator(Geometry geometry, boolean ignoreSpatialGaps) {
+        isFixedPoint = new ArrayList<Boolean>();
+        distances = new ArrayList<Double>();
+        oldMValues = new ArrayList<Double>();
+        vertices = new ArrayList<Point>();
+        lineIndexes = new ArrayList<Integer>();
+        route = geometry.cloneGeometry();
+
+        double distance = 0;
+        List<Line> lines = LrsAlgorithmUtils.extractLines(geometry);
+        Point previousVertex = null;
+        for (int i = 0; i < lines.size(); i++) {
+            Line line = lines.get(i);
+            for (int j = 0; j < line.getNumVertices(); j++) {
+                Point vertex = line.getVertex(j);
+                if (j == 0) {
+                    if (previousVertex == null) {
+                        //First point in geometry
+                        MDIMENSION = vertex.getDimension() - 1;
+                        distance = 0;
+                    }
+                    Integer visitedIndex = getIndexVisitedVertex(vertex);
+                    if (visitedIndex != null) {
+                        previousVertex = vertices.get(visitedIndex);
+                        distance = distances.get(visitedIndex);
+                    } else {
+                        if (previousVertex != null) {
+                            try {
+                                if (!LrsAlgorithmUtils.equalPoints(vertex, previousVertex)) {
+                                    Integer nearestVertexPos = getIndexNearestVisitedVertex(vertex);
+                                    if (ignoreSpatialGaps) {
+                                        distance = distances.get(nearestVertexPos);
+                                    } else {
+                                        Point nearestVertex = vertices.get(nearestVertexPos);
+                                        distance = distances.get(nearestVertexPos);
+                                        distance += vertex.distance(nearestVertex);
+                                    }
+                                }
+                            } catch (Exception e) {
+                                distance = Double.NaN;
+                            }
+                        }
+                    }
+                } else {
+                    try {
+                        distance += vertex.distance(previousVertex);
+                    } catch (Exception e) {
+                        distance = Double.NaN;
+                    }
+                }
+                Double mValue = vertex.getCoordinateAt(MDIMENSION);
+
+                isFixedPoint.add(false);
+                vertices.add(vertex);
+                distances.add(distance);
+                oldMValues.add(mValue);
+                lineIndexes.add(i);
+
+                previousVertex = vertex;
+            }
+        }
+    }
+
+    private Integer getIndexNearestVisitedVertex(Point vertex) throws GeometryOperationNotSupportedException, GeometryOperationException {
+        double nearestDistance = Double.POSITIVE_INFINITY;
+        Integer nearestPointPos = null;
+        for (int i = 0; i < vertices.size(); i++) {
+            Double distance = vertex.distance(vertices.get(i));
+            if (nearestDistance > distance && distance > Double.valueOf(0)) {
+                nearestDistance = distance;
+                nearestPointPos = i;
+            }
+        }
+        return nearestPointPos;
+    }
+
+    private Integer getIndexVisitedVertex(Point point) {
+        double distance = Double.NEGATIVE_INFINITY;
+        Integer index = null;
+        for (int i = 0; i < vertices.size(); i++) {
+            if (LrsAlgorithmUtils.equalPoints(point, vertices.get(i))) {
+                if (this.distances.get(i) > distance) {
+                    distance = this.distances.get(i);
+                    index = i;
+                }
+            }
+        }
+        return index;
+    }
+
+    @Override
+    public void addControlPoints(List<Point> fixedPoints) {
+        for (Point fixedPoint : fixedPoints) {
+            Double length = Double.valueOf(0);
+            int index = 0;
+            List<Line> lines = LrsAlgorithmUtils.extractLines(route);
+            List<Integer> insertAtList = new ArrayList<Integer>();
+            List<Double> lengths = new ArrayList<Double>();
+            List<Double> oldValues = new ArrayList<Double>();
+            List<Integer> lineReference = new ArrayList<Integer>();
+            for (int i = 0; i < lines.size(); i++) {
+                Line line = lines.get(i);
+                try {
+                    if (line.isWithinDistance(fixedPoint, PRECISION)) {
+                        length = distances.get(index);
+                        for (int j = 0; j < line.getNumVertices(); j++) {
+                            Point vertex = line.getVertex(j);
+                            Point nextVertex;
+                            if (j + 1 < line.getNumVertices()) {
+                                nextVertex = line.getVertex(j + 1);
+                            } else {
+                                nextVertex = null;
+                            }
+                            if (LrsAlgorithmUtils.equalPoints(vertex, fixedPoint) || vertex.distance(fixedPoint) <= PRECISION) {
+                                oldMValues.set(index, vertex.getCoordinateAt(MDIMENSION));
+                                Double mValue = fixedPoint.getCoordinateAt(MDIMENSION);
+                                vertex.setCoordinateAt(MDIMENSION, mValue);
+                                isFixedPoint.set(index, true);
+                                vertices.set(index, vertex);
+                            } else {
+                                if (nextVertex != null
+                                        && !LrsAlgorithmUtils.equalPoints(nextVertex, fixedPoint)
+                                        && vertex.distance(fixedPoint) > PRECISION
+                                        && nextVertex.distance(fixedPoint) > PRECISION) {
+
+                                    GeometryManager geomanager = GeometryLocator.getGeometryManager();
+                                    Line segment = (Line) geomanager
+                                            .create(Geometry.TYPES.LINE, Geometry.SUBTYPES.GEOM2DM);
+                                    segment.addVertex(vertex);
+                                    segment.addVertex(nextVertex);
+                                    //FIXME
+                                    //if (line.intersects(fixedPoint)){
+                                    if (segment.isWithinDistance(fixedPoint, PRECISION)) {
+                                        double distanceFirstVertex = distances.get(index);
+                                        double distanceToFixedPoint = vertex.distance(fixedPoint);
+                                        length = distanceFirstVertex + distanceToFixedPoint;
+                                        Double oldMValue = LrsAlgorithmUtils.straightLineThroughTwoPointsEquation(
+                                                distances.get(index),
+                                                distances.get(index + 1),
+                                                vertex.getCoordinateAt(MDIMENSION),
+                                                nextVertex.getCoordinateAt(MDIMENSION),
+                                                length);
+                                        insertAtList.add(index + 1);
+                                        lengths.add(length);
+                                        oldValues.add(oldMValue);
+                                        lineReference.add(i);
+                                    }
+                                }
+                            }
+                            index++;
+                        }
+                    } else {
+                        index += line.getNumVertices();
+                    }
+                } catch (Exception e) {
+                    logger.warn("Error inserting point " + fixedPoint.toString(), e);
+                }
+            }
+            int pos = 0;
+            for (Integer insertAt : insertAtList) {
+                Double distance = lengths.get(pos);
+                Double oldMValue = oldValues.get(pos);
+                Integer linePos = lineReference.get(pos);
+                int correctedPosition = insertAt + pos;
+                route = LrsAlgorithmUtils.insertVertex(route, fixedPoint, correctedPosition);
+                isFixedPoint.add(correctedPosition, true);
+                distances.add(correctedPosition, distance);
+                oldMValues.add(correctedPosition, oldMValue);
+                lineIndexes.add(correctedPosition, linePos);
+                vertices.add(correctedPosition, fixedPoint);
+                pos++;
+            }
+        }
+    }
+
+    @Override
+    public void setFirstMeasure(double mvalue) {
+        Point mPoint = (Point) this.vertices.get(0).cloneGeometry();
+        int mDimension = mPoint.getDimension() - 1;
+        mPoint.setCoordinateAt(mDimension, mvalue);
+        List<Point> points = new ArrayList<>();
+        points.add(mPoint);
+        this.addControlPoints(points);
+    }
+
+    @Override
+    public void setLastMeasure(double mvalue) {
+        Point mPoint = (Point) this.vertices.get(this.vertices.size()-1).cloneGeometry();
+        int mDimension = mPoint.getDimension() - 1;
+        mPoint.setCoordinateAt(mDimension, mvalue);
+        List<Point> points = new ArrayList<>();
+        points.add(mPoint);
+        this.addControlPoints(points);
+    }
+
+    @Override
+    public void setMeasuresToDistances() {
+        List<Point> points = LrsAlgorithmUtils.extractPoints(route);
+        for (int i = 0; i < points.size(); i++) {
+            if (!isFixedPoint.get(i)) {
+                points.get(i).setCoordinateAt(MDIMENSION, distances.get(i));
+                vertices.get(i).setCoordinateAt(MDIMENSION, distances.get(i));
+                oldMValues.set(i, distances.get(i));
+            }
+        }
+    }
+
+    @Override
+	public void calculate() {
+        this.calculate(
+                LrsMeasureCalculationMethods.DISTANCE,
+                false,
+                true,
+                false
+        );
+    }
+    
+    @Override
+    public void calculate(LrsMeasureCalculationMethods calculationMethod, boolean before, boolean between, boolean after) {
+        for (int i = 0; i < vertices.size(); i++) {
+            if (!isFixedPoint.get(i)) {
+                Integer prevFixedPointPos = getPreviousPosFixedPoint(i);
+                Integer nextFixedPointPos = getNextPosFixedPoint(i, false);
+
+                if (prevFixedPointPos == null && nextFixedPointPos != null && before) {
+                    extrapolateBeforeCalibrationPoints(calculationMethod, nextFixedPointPos, i);
+                }
+                if (prevFixedPointPos != null && nextFixedPointPos != null && between) {
+                    calculateMValue(calculationMethod, prevFixedPointPos, nextFixedPointPos, i);
+                }
+                if (prevFixedPointPos != null && nextFixedPointPos == null && after) {
+                    extrapolateAfterCalibrationPoints(calculationMethod, prevFixedPointPos, i);
+                }
+            }
+        }
+    }
+
+    private void extrapolateBeforeCalibrationPoints(LrsMeasureCalculationMethods calculationMethod, int firstFixedPointPos, int pos) {
+        Integer secondFixedPointPos = getNextPosFixedPoint(firstFixedPointPos, false);
+        if (secondFixedPointPos != null) {
+
+            if (calculationMethod.equals(LrsMeasureCalculationMethods.DISTANCE)) {
+                if (!isFixedPoint.get(pos)) {
+                    List<Point> points = LrsAlgorithmUtils.extractPoints(route);
+                    points.get(pos).setCoordinateAt(MDIMENSION, distances.get(pos));
+                    vertices.get(pos).setCoordinateAt(MDIMENSION, distances.get(pos));
+                    oldMValues.set(pos, distances.get(pos));
+                }
+            }
+
+            Double newMValueFirstPoint = vertices.get(firstFixedPointPos).getCoordinateAt(MDIMENSION);
+            Double newMValueSecondPoint = vertices.get(secondFixedPointPos).getCoordinateAt(MDIMENSION);
+
+            Double oldMValueFirstPoint;
+            Double oldMValueSecondPoint;
+            if (calculationMethod.equals(LrsMeasureCalculationMethods.DISTANCE)) {
+                oldMValueFirstPoint = distances.get(firstFixedPointPos);
+                oldMValueSecondPoint = distances.get(secondFixedPointPos);
+            } else {
+                oldMValueFirstPoint = oldMValues.get(firstFixedPointPos);
+                oldMValueSecondPoint = oldMValues.get(secondFixedPointPos);
+            }
+
+            Double distanceBetweenFixedPoints = newMValueSecondPoint - newMValueFirstPoint;
+            Double distanceBetweenOldFixedPoints = oldMValueSecondPoint - oldMValueFirstPoint;
+
+            Double calibrationRatio = distanceBetweenOldFixedPoints / distanceBetweenFixedPoints;
+
+            Double valueToRecalculate = vertices.get(pos).getCoordinateAt(MDIMENSION);
+            Double distanceBetween = oldMValueFirstPoint - valueToRecalculate;
+            Double mValue = newMValueFirstPoint - (distanceBetween / calibrationRatio);
+            refreshMValueGeometryVertex(pos, mValue, false);
+        }
+    }
+
+    private void extrapolateAfterCalibrationPoints(LrsMeasureCalculationMethods calculationMethod, int lastFixedPointPos, int pos) {
+        Integer prevFixedPointPos = getPreviousPosFixedPoint(lastFixedPointPos);
+        if (prevFixedPointPos != null) {
+            calculateMValue(calculationMethod, prevFixedPointPos, lastFixedPointPos, pos);
+        }
+    }
+
+    private void calculateMValue(LrsMeasureCalculationMethods calculationMethod, Integer prevFixedPointPos, int nextFixedPointPos, int pos) {
+
+        if (calculationMethod.equals(LrsMeasureCalculationMethods.DISTANCE)) {
+            if (!isFixedPoint.get(pos)) {
+                List<Point> points = LrsAlgorithmUtils.extractPoints(route);
+                points.get(pos).setCoordinateAt(MDIMENSION, distances.get(pos));
+                vertices.get(pos).setCoordinateAt(MDIMENSION, distances.get(pos));
+                oldMValues.set(pos, distances.get(pos));
+            }
+        }
+
+        Double newMValueBeforePoint = vertices.get(prevFixedPointPos).getCoordinateAt(MDIMENSION);
+        Double newMValueAfterPoint = vertices.get(nextFixedPointPos).getCoordinateAt(MDIMENSION);
+        while (newMValueBeforePoint.equals(newMValueAfterPoint)) {
+            prevFixedPointPos = getPreviousPosFixedPoint(prevFixedPointPos);
+            if (prevFixedPointPos != null) {
+                newMValueBeforePoint = vertices.get(prevFixedPointPos).getCoordinateAt(MDIMENSION);
+            } else {
+                refreshMValueGeometryVertex(pos, Double.NaN, false);
+                return;
+            }
+        }
+
+        Double oldMValueBeforePoint;
+        Double oldMValueAfterPoint;
+        if (calculationMethod.equals(LrsMeasureCalculationMethods.DISTANCE)) {
+            oldMValueBeforePoint = distances.get(prevFixedPointPos);
+            oldMValueAfterPoint = distances.get(nextFixedPointPos);
+        } else {
+            oldMValueBeforePoint = oldMValues.get(prevFixedPointPos);
+            oldMValueAfterPoint = oldMValues.get(nextFixedPointPos);
+        }
+
+        Double distanceBetweenFixedPoints = newMValueAfterPoint - newMValueBeforePoint;
+        Double distanceBetweenOldFixedPoints = oldMValueAfterPoint - oldMValueBeforePoint;
+
+        Double calibrationRatio = distanceBetweenOldFixedPoints / distanceBetweenFixedPoints;
+
+        Double valueToRecalculate = vertices.get(pos).getCoordinateAt(MDIMENSION);
+        Double distanceBetween = valueToRecalculate - oldMValueBeforePoint;
+        Double mValue = newMValueBeforePoint + (distanceBetween / calibrationRatio);
+        refreshMValueGeometryVertex(pos, mValue, true);
+    }
+
+    private Integer getNextPosFixedPoint(int pos, boolean selfInclude) {
+        Integer nextFixedPointPos = findNextFixedPointInLine(pos, selfInclude);
+        if (nextFixedPointPos != null) {
+            return nextFixedPointPos;
+        } else {
+            int lastPositionInLine = getLastPositionInLine(pos);
+            nextFixedPointPos = findNextFixedPointInNextLines(lastPositionInLine, new ArrayList<Integer>());
+            if (nextFixedPointPos != null) {
+                return nextFixedPointPos;
+            }
+            try {
+                Integer nearestVertex = findNearestNextPoint(lastPositionInLine);
+                return getNextPosFixedPoint(nearestVertex, true);
+            } catch (Exception e) {
+                return null;
+            }
+        }
+    }
+
+    private Integer getLastPositionInLine(int pos) {
+        Integer lineVisited = lineIndexes.get(pos);
+        for (int i = pos + 1; i < vertices.size(); i++) {
+            if (!lineVisited.equals(lineIndexes.get(i))) {
+                return i - 1;
+            }
+        }
+        return vertices.size() - 1;
+    }
+
+    private Integer findNextFixedPointInNextLines(int pos, List<Integer> visitedLines) {
+        Integer nextFixedPointPos = findNextFixedPointInLine(pos, true);
+        if (nextFixedPointPos != null) {
+            return nextFixedPointPos;
+        } else {
+            Integer lineIndex = lineIndexes.get(pos);
+            visitedLines.add(lineIndex);
+            int lastPositionInLine = getLastPositionInLine(pos);
+            Point lastVertexInLine = vertices.get(lastPositionInLine);
+            for (int i = lastPositionInLine; i < vertices.size(); i++) {
+                if (LrsAlgorithmUtils.equalPoints(lastVertexInLine, vertices.get(i))) {
+                    if (!visitedLines.contains(lineIndexes.get(i))) {
+                        findNextFixedPointInNextLines(i, visitedLines);
+                    }
+                }
+            }
+        }
+        return null;
+    }
+
+    private Integer findNextFixedPointInLine(int vertexPos, boolean selfInclude) {
+        int lineIndex = lineIndexes.get(vertexPos);
+        if (!selfInclude) {
+            vertexPos += 1;
+        }
+        for (int i = vertexPos; i < vertices.size(); i++) {
+            if (!lineIndexes.get(i).equals(lineIndex)) {
+                return null;
+            }
+            if (isFixedPoint.get(i)) {
+                return i;
+            }
+        }
+        return null;
+    }
+
+    private Integer findNearestNextPoint(int vertexPos) throws GeometryOperationNotSupportedException, GeometryOperationException {
+        Point vertex = vertices.get(vertexPos);
+        double nearestDistance = Double.POSITIVE_INFINITY;
+        Integer nearestPointPos = null;
+        for (int i = vertexPos + 1; i < vertices.size(); i++) {
+            Double distance = vertex.distance(vertices.get(i));
+            if (nearestDistance > distance && distance > Double.valueOf(0)) {
+                nearestDistance = distance;
+                nearestPointPos = i;
+            }
+        }
+        return nearestPointPos;
+    }
+
+    private Integer getPreviousPosFixedPoint(int pos) {
+        Integer prevFixedPointPos = findPrevFixedPointInLine(pos);
+        if (prevFixedPointPos != null) {
+            return prevFixedPointPos;
+        } else {
+            Integer lineVisited = lineIndexes.get(pos);
+            for (int i = pos - 1; i >= 0; i--) {
+                if (!lineVisited.equals(lineIndexes.get(i))) {//Line has changed
+                    int lastPositionInLine = i + 1;
+                    for (int j = lastPositionInLine; j >= 0; j--) {
+                        if (LrsAlgorithmUtils.equalPoints(vertices.get(lastPositionInLine), vertices.get(j))) {
+                            if (isFixedPoint.get(j) && j < pos) {
+                                return j;
+                            }
+                        }
+                    }
+                    try {
+                        return findNearestPrevFixedPoint(lastPositionInLine);
+                    } catch (Exception e) {
+                        return null;
+                    }
+                }
+            }
+        }
+        return null;
+    }
+
+    private Integer findPrevFixedPointInLine(int vertexPos) {
+        int lineIndex = lineIndexes.get(vertexPos);
+        for (int i = vertexPos - 1; i >= 0; i--) {
+            if (!lineIndexes.get(i).equals(lineIndex)) {
+                return null;
+            }
+            if (isFixedPoint.get(i)) {
+                return i;
+            }
+        }
+        return null;
+    }
+
+    private Integer findNearestPrevFixedPoint(int vertexPos) throws GeometryOperationNotSupportedException, GeometryOperationException {
+        Point vertex = vertices.get(vertexPos);
+        double nearestDistance = Double.POSITIVE_INFINITY;
+        Integer nearestPointPos = null;
+        for (int i = vertexPos - 1; i >= 0; i--) {
+            if (isFixedPoint.get(i)) {
+                Double distance = vertex.distance(vertices.get(i));
+                if (nearestDistance > distance) {
+                    nearestDistance = distance;
+                    nearestPointPos = i;
+                }
+            }
+        }
+        return nearestPointPos;
+    }
+
+    private void refreshMValueGeometryVertex(int i, Double mValue, boolean fixed) {
+        List<Point> points = LrsAlgorithmUtils.extractPoints(route);
+        vertices.get(i).setCoordinateAt(MDIMENSION, mValue);
+        points.get(i).setCoordinateAt(MDIMENSION, mValue);
+        isFixedPoint.set(i, fixed);
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultLrsAlgorithmsLibrary.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultLrsAlgorithmsLibrary.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultLrsAlgorithmsLibrary.java	(revision 950)
@@ -0,0 +1,54 @@
+/**
+ * gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+
+package org.gvsig.lrs.lib.impl;
+
+import org.gvsig.lrs.lib.api.LrsAlgorithmsLibrary;
+import org.gvsig.lrs.lib.api.LrsAlgorithmsLocator;
+import org.gvsig.lrs.lib.impl.expressionevaluator.symboltable.LRSSymbolTableFactory;
+import org.gvsig.tools.library.AbstractLibrary;
+import org.gvsig.tools.library.LibraryException;
+
+/**
+ * @author fdiaz</a>
+ *
+ */
+public class DefaultLrsAlgorithmsLibrary extends AbstractLibrary {
+
+    @Override
+    public void doRegistration() {
+        registerAsImplementationOf(LrsAlgorithmsLibrary.class);
+    }
+
+    @Override
+    protected void doInitialize() throws LibraryException {
+        LrsAlgorithmsLocator.registerLrsAlgorithmsManager(DefaultLrsAlgorithmsManager.class);
+    }
+
+    @Override
+    protected void doPostInitialize() throws LibraryException {
+        LRSSymbolTableFactory.selfRegister();
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/LrsGenerateDynamicSegmentationAlgorithm.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/LrsGenerateDynamicSegmentationAlgorithm.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/LrsGenerateDynamicSegmentationAlgorithm.java	(revision 950)
@@ -0,0 +1,333 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.lib.impl;
+
+import java.io.File;
+import java.util.Iterator;
+import java.util.List;
+
+import org.apache.commons.lang3.StringUtils;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import org.gvsig.fmap.dal.DALLocator;
+import org.gvsig.fmap.dal.DataManager;
+import org.gvsig.fmap.dal.DataServerExplorer;
+import org.gvsig.fmap.dal.DataServerExplorerParameters;
+import org.gvsig.fmap.dal.DataStore;
+import static org.gvsig.fmap.dal.DataStore.SHAPE_PROVIDER_NAME;
+import org.gvsig.fmap.dal.DataTypes;
+import org.gvsig.fmap.dal.feature.EditableFeature;
+import org.gvsig.fmap.dal.feature.EditableFeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.EditableFeatureType;
+import org.gvsig.fmap.dal.feature.Feature;
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureQuery;
+import org.gvsig.fmap.dal.feature.FeatureSet;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.feature.NewFeatureStoreParameters;
+//import org.gvsig.fmap.dal.store.shp.SHPNewStoreParameters;
+//import org.gvsig.fmap.dal.store.shp.SHPStoreProvider;
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.geom.GeometryLocator;
+import org.gvsig.fmap.geom.aggregate.MultiLine;
+import org.gvsig.fmap.geom.primitive.Point;
+import org.gvsig.fmap.geom.type.GeometryType;
+import org.gvsig.lrs.lib.api.LrsAlgorithm;
+import org.gvsig.lrs.lib.api.LrsAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsGenerateDynamicSegmentationAlgorithmParams;
+import org.gvsig.lrs.lib.api.exceptions.LrsCreateRouteException;
+import org.gvsig.lrs.lib.api.exceptions.LrsException;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.dataTypes.DataType;
+import org.gvsig.tools.exception.BaseException;
+import org.gvsig.tools.i18n.I18nManager;
+import org.gvsig.tools.locator.LocatorException;
+import org.gvsig.tools.service.Manager;
+import org.gvsig.tools.task.SimpleTaskStatus;
+import org.gvsig.tools.util.HasAFile;
+import org.gvsig.tools.visitor.VisitCanceledException;
+import org.gvsig.tools.visitor.Visitor;
+
+/**
+ * @author fdiaz
+ *
+ */
+public class LrsGenerateDynamicSegmentationAlgorithm implements LrsAlgorithm {
+
+    private static final Logger logger = LoggerFactory.getLogger(LrsGenerateDynamicSegmentationAlgorithm.class);
+
+    private LrsGenerateDynamicSegmentationAlgorithmParams parameters;
+
+
+    /**
+     *
+     */
+    public LrsGenerateDynamicSegmentationAlgorithm(LrsGenerateDynamicSegmentationAlgorithmParams parameters) {
+        this.parameters = parameters;
+
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see org.gvsig.tools.service.Service#getManager()
+     */
+    public Manager getManager() {
+        return null;
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithm#getParams()
+     */
+    public  LrsAlgorithmParams getParams() {
+        return this.parameters;
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithm#execute(org.gvsig.tools.task.SimpleTaskStatus)
+     */
+    public void execute(final SimpleTaskStatus taskStatus) throws LrsException {
+        NewFeatureStoreParameters newFeatureStoreParameters = parameters.getNewFeatureStoreParameters();
+        final FeatureStore sourceFeatureStore = parameters.getSourceFeatureStore();
+        final FeatureAttributeDescriptor idRouteField = parameters.getIdRouteField();
+        final FeatureAttributeDescriptor idTableRouteField = parameters.getValueTableIdRouteField();
+        FeatureStore tableFeatureStore = parameters.getValueTableFeatureStore();
+        final FeatureAttributeDescriptor landmarkField = parameters.getLandmarkField();
+        final FeatureAttributeDescriptor finalLandmarkField = parameters.getFinalLandmarkField();
+        final FeatureAttributeDescriptor valueField = parameters.getValueField();
+
+        logger.info(parameters.toString());
+
+        taskStatus.setTitle(parameters.getName());
+        I18nManager i18nManager = ToolsLocator.getI18nManager();
+        taskStatus.message(i18nManager.getTranslation("processing"));
+
+        try {
+            final String tableRouteFieldName=idTableRouteField.getName();
+            final String fromFieldName;
+            final DataType fromDataType;
+            final String toFieldName;
+            final DataType toDataType;
+            final int geomType;
+            if (landmarkField!=null){
+                fromDataType=landmarkField.getDataType();
+                if (finalLandmarkField!=null){
+                    fromFieldName="PK INICIAL";
+                    toFieldName="PK FINAL";
+                    toDataType=finalLandmarkField.getDataType();
+                    geomType = Geometry.TYPES.MULTILINE;
+                }else{
+                    fromFieldName="PK";
+                    toFieldName=null;
+                    toDataType=null;
+                    geomType = Geometry.TYPES.POINT;
+                }
+            }else{
+                //TODO: Si no hay fromFieldName ¿salir por patas?
+                fromFieldName=null;
+                fromDataType=null;
+                toFieldName=null;
+                toDataType=null;
+                geomType = Geometry.TYPES.POINT;
+            }
+
+            final FeatureStore newFeatureStore = createNewDataStore(
+                newFeatureStoreParameters,
+                idRouteField,
+                fromFieldName,
+                toFieldName,
+                valueField,
+                geomType
+             );
+
+            FeatureSet tableFeatures;
+            tableFeatures=tableFeatureStore.getFeatureSet();
+            taskStatus.setRangeOfValues(0, tableFeatures.getSize()-1);
+            newFeatureStore.edit(FeatureStore.MODE_FULLEDIT);
+
+            tableFeatures.accept(new Visitor() {
+
+                int taskCount=0;
+                public void visit(Object obj) throws VisitCanceledException, BaseException {
+                    Feature feature = (Feature) obj;
+                    String routeName = (String) feature.get(tableRouteFieldName);
+                    Object objFrom = null;
+                    Object objTo = null;
+                    if (fromFieldName != null) {
+                        objFrom = feature.get(landmarkField.getName());
+                        double fromValue = LrsAlgorithmUtils.getAsDouble(objFrom, fromDataType);
+                        Object value = feature.get(valueField.getName());
+                        if (toFieldName == null || toFieldName.isEmpty()) {
+                            addSegmentatePointsFeatures(newFeatureStore, sourceFeatureStore, idRouteField, routeName, fromFieldName, fromValue, valueField, value);
+                        } else {
+                            objTo = feature.get(finalLandmarkField.getName());
+                            double toValue = LrsAlgorithmUtils.getAsDouble(objTo, toDataType);
+                            addSegmentateLinesFeatures(newFeatureStore, sourceFeatureStore, idRouteField, routeName,
+                                fromFieldName, fromValue, toFieldName, toValue, valueField, value);
+                        }
+
+                    } else {
+                        //TODO: ¿Exception?
+                    }
+                    taskStatus.setCurValue(taskCount++);
+                }
+
+                private void addSegmentatePointsFeatures(final FeatureStore featureStore,
+                    FeatureStore sourceFeatureStore, final FeatureAttributeDescriptor idRouteField,
+                    final String routeName, final String fromFieldName, final double fromValue, final FeatureAttributeDescriptor valueField, final Object value)
+                    throws LocatorException, BaseException {
+
+                    DataManager dataManager = DALLocator.getDataManager();
+                    FeatureQuery query = sourceFeatureStore.createFeatureQuery();
+                    String expression = StringUtils.replace(StringUtils.replace("NOMBRE = 'a%'", "NOMBRE", idRouteField.getName()), "a%", routeName);
+                    query.setFilter( dataManager.createExpresion(expression) );
+
+                    FeatureSet features = sourceFeatureStore.getFeatureSet(query);
+                    features.accept(new Visitor() {
+
+                        public void visit(Object obj) throws VisitCanceledException, BaseException {
+                            Feature feature = (Feature)obj;
+                            Geometry geom = feature.getDefaultGeometry();
+                            List<Point>points = LrsAlgorithmUtils.getPointsWithM(geom, fromValue);
+                            for (Iterator<Point> iterator = points.iterator(); iterator.hasNext();) {
+                                Point point = (Point) iterator.next();
+                                EditableFeature newFeature = featureStore.createNewFeature(true);
+                                newFeature.set(idRouteField.getName(), routeName);
+                                newFeature.set(fromFieldName, fromValue);
+                                newFeature.set(valueField.getName(), value);
+                                newFeature.setDefaultGeometry(point);
+                                featureStore.insert(newFeature);
+                            }
+                        }
+                    });
+                }
+
+                private void addSegmentateLinesFeatures(final FeatureStore featureStore,
+                    FeatureStore sourceFeatureStore, final FeatureAttributeDescriptor idRouteField,
+                    final String routeName, final String fromFieldName, final double fromValue,
+                    final String toFieldName, final double toValue, final FeatureAttributeDescriptor valueField, final Object value) throws LocatorException, BaseException {
+
+                    DataManager dataManager = DALLocator.getDataManager();
+                    FeatureQuery query = sourceFeatureStore.createFeatureQuery();
+                    String expression = StringUtils.replace(StringUtils.replace("NOMBRE = 'a%'", "NOMBRE", idRouteField.getName()), "a%", routeName);
+                    query.setFilter( dataManager.createExpresion(expression) );
+
+                    FeatureSet features = sourceFeatureStore.getFeatureSet(query);
+                    features.accept(new Visitor() {
+
+                        public void visit(Object obj) throws VisitCanceledException, BaseException {
+                            Feature feature = (Feature) obj;
+                            Geometry geom = feature.getDefaultGeometry();
+                            MultiLine lines = LrsAlgorithmUtils.getLinesBetweenTwoM(geom, fromValue, toValue);
+                            if (lines != null && lines.getPrimitivesNumber()>0) {
+                                EditableFeature newFeature = featureStore.createNewFeature(true);
+                                newFeature.set(idRouteField.getName(), routeName);
+                                newFeature.set(fromFieldName, fromValue);
+                                newFeature.set(toFieldName, toValue);
+                                newFeature.set(valueField.getName(), value);
+                                newFeature.setDefaultGeometry(lines);
+                                featureStore.insert(newFeature);
+                            }
+                        }
+                    });
+                }
+            });
+
+            newFeatureStore.finishEditing();
+
+        } catch (Exception e1) {
+            taskStatus.abort();
+            throw new LrsCreateRouteException("Error creating routes", e1);
+        }
+
+
+        taskStatus.terminate();
+
+    }
+
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithm#setParams(org.gvsig.lrs.lib.api.LrsAlgorithmParams)
+     */
+    public void setParams(LrsAlgorithmParams params) throws IllegalArgumentException {
+        if(!(params instanceof LrsCreateRouteAlgorithmParams)){
+            throw new IllegalArgumentException("params should be LrsCreateRouteAlgorithmParams type.");
+        }
+        this.parameters = (LrsGenerateDynamicSegmentationAlgorithmParams) params;
+
+    }
+
+    private FeatureStore createNewDataStore(
+        NewFeatureStoreParameters newFeatureStoreParameters,
+        FeatureAttributeDescriptor idRouteField,
+        String fromFieldName,
+        String toFieldName,
+        FeatureAttributeDescriptor valueField,
+        int type) throws Exception{
+        try {
+            File file=((HasAFile)newFeatureStoreParameters).getFile();
+            String filePath=file.getPath().substring(0, file.getPath().lastIndexOf(File.separator));
+
+            DataManager dataManager = DALLocator.getDataManager();
+            DataServerExplorerParameters serverParams =
+                dataManager.createServerExplorerParameters("FilesystemExplorer");
+            serverParams.setDynValue("initialpath", filePath);
+            DataServerExplorer serverExplorer =
+                dataManager.openServerExplorer(serverParams.getExplorerName(), serverParams);
+
+            EditableFeatureType featureType = (EditableFeatureType)newFeatureStoreParameters.getDefaultFeatureType();
+            featureType.add(idRouteField.getName(), idRouteField.getType(), idRouteField.getSize());
+            featureType.add(fromFieldName, DataTypes.DOUBLE);
+            if(toFieldName!=null){
+                featureType.add(toFieldName, DataTypes.DOUBLE);
+            }
+            featureType.add(valueField.getName(), valueField.getType(), valueField.getSize());
+            EditableFeatureAttributeDescriptor geometryField = featureType.add("Geometry", DataTypes.GEOMETRY);
+            GeometryType geometryType = GeometryLocator.getGeometryManager().getGeometryType(type, Geometry.SUBTYPES.GEOM2DM);
+            geometryField.setGeometryType(geometryType);
+
+            featureType.setDefaultGeometryAttributeName("Geometry");
+
+            newFeatureStoreParameters.setDefaultFeatureType(featureType);
+            serverExplorer.add("Shape", newFeatureStoreParameters, true);
+
+            DataStore store = dataManager.openStore(SHAPE_PROVIDER_NAME, newFeatureStoreParameters);
+
+            return (FeatureStore)store;
+
+        } catch (Exception e) {
+            throw new LrsCreateRouteException("Error creating new dataStore", e);
+        }
+    }
+
+
+}
+
+
+
+
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultLrsCalibrateRouteAlgorithmParams.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultLrsCalibrateRouteAlgorithmParams.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultLrsCalibrateRouteAlgorithmParams.java	(revision 950)
@@ -0,0 +1,253 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.lib.impl;
+
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.feature.NewFeatureStoreParameters;
+import org.gvsig.lrs.lib.api.DistanceUnits;
+import org.gvsig.lrs.lib.api.LrsCalibrateRouteAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsMeasureCalculationMethods;
+
+
+/**
+ * @author dmartinez
+ *
+ */
+public class DefaultLrsCalibrateRouteAlgorithmParams implements LrsCalibrateRouteAlgorithmParams {
+
+    private FeatureStore sourceFeatureStore;
+    private FeatureAttributeDescriptor idRouteField;
+    private NewFeatureStoreParameters newFeatureStoreParameters;
+    private FeatureStore calibratePointFeatureStore;
+    private FeatureAttributeDescriptor calibratePointIdRouteField;
+    private FeatureAttributeDescriptor fromMeasureField;
+    private LrsMeasureCalculationMethods measureCalculationMethods;
+    private DistanceUnits measureUnits;
+    private double searchRadius = 0.0;
+    private boolean interpolateBetweenCalibrationPoints=false;
+    private boolean extrapolateBeforeCalibrationPoints=false;
+    private boolean extrapolateAfterCalibrationPoints=false;
+    private boolean ignoreSpatialGaps=false;
+    private boolean includeAll=false;
+    private final String NAME = "LrsCalibrateRouteAlgorithm";
+    private final String DESCRIPTION = "Algorithm to calibrate routes with linear reference system.";
+
+
+
+    /**
+     *
+     */
+    public DefaultLrsCalibrateRouteAlgorithmParams() {
+        searchRadius = 0.0;
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithmParams#getName()
+     */
+    public String getName() {
+        return NAME;
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithmParams#getDescription()
+     */
+    public String getDescription() {
+        return DESCRIPTION;
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#getSourceFeatureStore()
+     */
+    public FeatureStore getSourceFeatureStore() {
+        return sourceFeatureStore;
+    }
+
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#setSourceFeatureStore(org.gvsig.fmap.dal.feature.FeatureStore)
+     */
+    public void setSourceFeatureStore(FeatureStore sourceFeatureStore) {
+        this.sourceFeatureStore = sourceFeatureStore;
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#getIdRouteField()
+     */
+    public FeatureAttributeDescriptor getIdRouteField() {
+        return idRouteField;
+    }
+
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#setIdRouteField(org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor)
+     */
+    public void setIdRouteField(FeatureAttributeDescriptor idRouteField) {
+        this.idRouteField = idRouteField;
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#getFromMeasureField()
+     */
+    public FeatureAttributeDescriptor getFromMeasureField() {
+        return fromMeasureField;
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#setFromMeasureField(org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor)
+     */
+    public void setFromMeasureField(FeatureAttributeDescriptor fromMeasureField) {
+        this.fromMeasureField = fromMeasureField;
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#isIgnoreSpatialGaps()
+     */
+    public boolean ignoreSpatialGaps() {
+        return ignoreSpatialGaps;
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#setIgnoreSpatialGaps(boolean)
+     */
+    public void setIgnoreSpatialGaps(boolean ignoreSpatialGaps) {
+        this.ignoreSpatialGaps = ignoreSpatialGaps;
+    }
+
+    public NewFeatureStoreParameters getNewFeatureStoreParameters() {
+        return this.newFeatureStoreParameters;
+    }
+
+    public void setNewFeatureStoreParameters(
+        NewFeatureStoreParameters newFeatureStoreParameters) {
+        this.newFeatureStoreParameters = newFeatureStoreParameters;
+    }
+
+
+    public FeatureStore getCalibratePointFeatureStore() {
+        return calibratePointFeatureStore;
+    }
+
+
+    public void setCalibratePointFeatureStore(
+        FeatureStore calibratePointFeatureStore) {
+        this.calibratePointFeatureStore = calibratePointFeatureStore;
+    }
+
+
+    public FeatureAttributeDescriptor getCalibratePointIdRouteField() {
+        return calibratePointIdRouteField;
+    }
+
+
+    public void setCalibratePointIdRouteField(
+        FeatureAttributeDescriptor calibratePointIdRouteField) {
+        this.calibratePointIdRouteField = calibratePointIdRouteField;
+    }
+
+
+    public LrsMeasureCalculationMethods getMeasureCalculationMethods() {
+        return measureCalculationMethods;
+    }
+
+
+    public void setMeasureCalculationMethods(
+        LrsMeasureCalculationMethods measureCalculationMethods) {
+        this.measureCalculationMethods = measureCalculationMethods;
+    }
+
+
+    public DistanceUnits getMeasureUnits() {
+        return measureUnits;
+    }
+
+
+    public void setMeasureUnits(DistanceUnits measureUnits) {
+        this.measureUnits = measureUnits;
+    }
+
+
+    public double getSearchRadius() {
+        return searchRadius;
+    }
+
+
+    public void setSearchRadius(double searchRadius) {
+        this.searchRadius = searchRadius;
+    }
+
+
+    public boolean interpolateBetweenCalibrationPoints() {
+        return interpolateBetweenCalibrationPoints;
+    }
+
+
+    public void setInterpolateBetweenCalibrationPoints(
+        boolean interpolateBetweenCalibrationPoints) {
+        this.interpolateBetweenCalibrationPoints =
+            interpolateBetweenCalibrationPoints;
+    }
+
+
+    public boolean extrapolateBeforeCalibrationPoints() {
+        return extrapolateBeforeCalibrationPoints;
+    }
+
+
+    public void setExtrapolateBeforeCalibrationPoints(
+        boolean extrapolateBeforeCalibrationPoints) {
+        this.extrapolateBeforeCalibrationPoints =
+            extrapolateBeforeCalibrationPoints;
+    }
+
+
+    public boolean extrapolateAfterCalibrationPoints() {
+        return extrapolateAfterCalibrationPoints;
+    }
+
+
+    public void setExtrapolateAfterCalibrationPoints(
+        boolean extrapolateAfterCalibrationPoints) {
+        this.extrapolateAfterCalibrationPoints = extrapolateAfterCalibrationPoints;
+    }
+
+
+    public boolean includeAll() {
+        return includeAll;
+    }
+
+
+    public void setIncludeAll(boolean includeAll) {
+        this.includeAll = includeAll;
+    }
+
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultLrsShowMeasuresAlgorithmParams.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultLrsShowMeasuresAlgorithmParams.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultLrsShowMeasuresAlgorithmParams.java	(revision 950)
@@ -0,0 +1,79 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.lib.impl;
+
+import org.gvsig.lrs.lib.api.LrsShowMeasuresAlgorithmParams;
+
+
+
+/**
+ * @author dmartinez
+ *
+ */
+public class DefaultLrsShowMeasuresAlgorithmParams implements LrsShowMeasuresAlgorithmParams {
+
+
+    private double distance = 0.0;
+    private final String NAME = "LrsShowMeasuresAlgorithm";
+    private final String DESCRIPTION = "Algorithm to show measures with linear reference system.";
+    private int units = LRS_SHOWMEASURES_UNKNOWN_OTHER;
+
+
+    /**
+     *
+     */
+    public DefaultLrsShowMeasuresAlgorithmParams() {
+        distance = 0.0;
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithmParams#getName()
+     */
+    public String getName() {
+        return NAME;
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithmParams#getDescription()
+     */
+    public String getDescription() {
+        return DESCRIPTION;
+    }
+
+    public double getDistance() {
+        return distance;
+    }
+
+    public void setDistance(double distance) {
+        this.distance = distance;
+    }
+
+    public int getUnits() {
+        return units;
+    }
+
+    public void setUnits(int units) {
+        this.units = units;
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/LrsAlgorithmUtils.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/LrsAlgorithmUtils.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/LrsAlgorithmUtils.java	(revision 950)
@@ -0,0 +1,494 @@
+/*
+ * Copyright 2015 DiSiD Technologies S.L.L. All rights reserved.
+ *
+ * Project  : DiSiD org.gvsig.lrs.lib.impl
+ * SVN Id   : $Id$
+ */
+package org.gvsig.lrs.lib.impl;
+
+import java.io.File;
+import java.util.ArrayList;
+import java.util.List;
+import org.gvsig.fmap.dal.DALLocator;
+import org.gvsig.fmap.dal.DataManager;
+import org.gvsig.fmap.dal.DataServerExplorer;
+import org.gvsig.fmap.dal.DataServerExplorerParameters;
+import org.gvsig.fmap.dal.DataStore;
+import org.gvsig.fmap.dal.DataTypes;
+import org.gvsig.fmap.dal.feature.EditableFeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.EditableFeatureType;
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.feature.NewFeatureStoreParameters;
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.geom.GeometryLocator;
+import org.gvsig.fmap.geom.GeometryManager;
+import org.gvsig.fmap.geom.aggregate.MultiLine;
+import org.gvsig.fmap.geom.exception.CreateGeometryException;
+import org.gvsig.fmap.geom.operation.GeometryOperationException;
+import org.gvsig.fmap.geom.operation.GeometryOperationNotSupportedException;
+import org.gvsig.fmap.geom.primitive.Line;
+import org.gvsig.fmap.geom.primitive.Point;
+import org.gvsig.fmap.geom.type.GeometryType;
+import org.gvsig.lrs.lib.api.exceptions.LrsCreateRouteException;
+import org.gvsig.tools.dataTypes.DataType;
+import org.gvsig.tools.locator.LocatorException;
+import org.gvsig.tools.util.HasAFile;
+
+/**
+ * @author fdiaz
+ *
+ */
+public class LrsAlgorithmUtils {
+
+    static protected FeatureStore createNewDataStore(NewFeatureStoreParameters newFeatureStoreParameters,
+        FeatureAttributeDescriptor idRouteField) throws Exception {
+        return createNewDataStore(newFeatureStoreParameters, idRouteField, Geometry.TYPES.MULTILINE);
+    }
+
+    static protected FeatureStore createNewDataStore(NewFeatureStoreParameters newFeatureStoreParameters,
+        FeatureAttributeDescriptor idRouteField, int type) throws Exception {
+        try {
+            File file = ((HasAFile)newFeatureStoreParameters).getFile();
+            String filePath = file.getPath().substring(0, file.getPath().lastIndexOf(File.separator));
+
+            DataManager dataManager = DALLocator.getDataManager();
+            DataServerExplorerParameters serverParams =
+                dataManager.createServerExplorerParameters("FilesystemExplorer");
+            serverParams.setDynValue("initialpath", filePath);
+            DataServerExplorer serverExplorer =
+                dataManager.openServerExplorer(serverParams.getExplorerName(), serverParams);
+
+            EditableFeatureType featureType = (EditableFeatureType) newFeatureStoreParameters.getDefaultFeatureType();
+            featureType.add(idRouteField.getName(), idRouteField.getType(), idRouteField.getSize());
+            EditableFeatureAttributeDescriptor geometryField = featureType.add("Geometry", DataTypes.GEOMETRY);
+            GeometryType geometryType =
+                GeometryLocator.getGeometryManager().getGeometryType(type, Geometry.SUBTYPES.GEOM2DM);
+            geometryField.setGeometryType(geometryType);
+
+            featureType.setDefaultGeometryAttributeName("Geometry");
+
+            newFeatureStoreParameters.setDefaultFeatureType(featureType);
+            serverExplorer.add("Shape", newFeatureStoreParameters, true);
+
+            DataStore store = dataManager.createStore(newFeatureStoreParameters);
+
+            return (FeatureStore) store;
+
+        } catch (Exception e) {
+            throw new LrsCreateRouteException("Error creating new dataStore", e);
+        }
+    }
+
+    static protected Double getAsDouble(Object obj, DataType dataType) {
+        if (obj == null || dataType == null) {
+            return null;
+        }
+        Double result = Double.NaN;
+        if (dataType.equals(DataTypes.DOUBLE)) {
+            result = (Double) obj;
+        } else if (dataType.isNumeric()) {
+            result = Double.valueOf(String.valueOf(obj));
+        }
+        return result;
+    }
+
+    static List<Point> getPointsWithM(Geometry geom, double m) throws CreateGeometryException, LocatorException {
+
+        List<Point> points = new ArrayList<Point>();
+
+        if (geom instanceof Line) {
+            Line line = (Line) geom;
+            for (int i = 0; i < line.getNumVertices() - 1; i++) {
+                Point currentVertex = line.getVertex(i);
+                Point nextVertex = line.getVertex(i + 1);
+                Point point = getPointWithMBetweenTwoMPoints(m, currentVertex, nextVertex);
+                if (point != null && !points.contains(point)) {
+                    points.add(point);
+                }
+            }
+        } else if (geom instanceof MultiLine) {
+            MultiLine multiLine = (MultiLine) geom;
+            for (int p = 0; p < multiLine.getPrimitivesNumber(); p++) {
+                Line line = (Line) multiLine.getPrimitiveAt(p);
+                for (int i = 0; i < line.getNumVertices() - 1; i++) {
+                    Point point = getPointWithMBetweenTwoMPoints(m, line.getVertex(i), line.getVertex(i + 1));
+                    if (point != null && !points.contains(point)) {
+                        points.add(point);
+                    }
+                }
+            }
+        }
+        return points;
+    }
+
+    private static boolean isInRange(double v, double r1, double r2) {
+        if (r1 < r2) {
+            return v >= r1 && v <= r2;
+        } else if (r1 > r2) {
+            return v >= r2 && v <= r1;
+        } else {
+            return v == r1;
+        }
+    }
+
+    static MultiLine getLinesBetweenTwoM(Geometry geom, double m1, double m2) throws CreateGeometryException,
+        LocatorException {
+        GeometryManager geomManager = GeometryLocator.getGeometryManager();
+
+        MultiLine lines = null;
+        if (geom instanceof Line) {
+            lines = getLinesBetweenTwoM((Line) geom, m1, m2);
+        } else if (geom instanceof MultiLine) {
+            lines = (MultiLine) geomManager.create(Geometry.TYPES.MULTILINE, geom.getGeometryType().getSubType());
+            MultiLine multiLine = (MultiLine) geom;
+            for (int i = 0; i < multiLine.getPrimitivesNumber(); i++) {
+                MultiLine auxMultiLine = getLinesBetweenTwoM(multiLine.getPrimitiveAt(i), m1, m2);
+                for (int j = 0; j < auxMultiLine.getPrimitivesNumber(); j++) {
+                    lines.addPrimitive(auxMultiLine.getPrimitiveAt(j));
+                }
+            }
+        }
+        return lines;
+    }
+
+    static private MultiLine getLinesBetweenTwoM(Line line, double m1, double m2) throws CreateGeometryException {
+        GeometryManager geomManager = GeometryLocator.getGeometryManager();
+        MultiLine lines = (MultiLine) geomManager.create(Geometry.TYPES.MULTILINE, line.getGeometryType().getSubType());
+        Line auxLine = (Line) geomManager.create(Geometry.TYPES.LINE, line.getGeometryType().getSubType());
+
+        boolean inSegment = false;
+        if (line.getNumVertices() > 0) {
+            int ivertex = 0;
+            Point previousVertex = null;
+            while (ivertex < line.getNumVertices()) {
+                if (!inSegment) { // NO ESTAMOS EN UN SEGMENTO VALIDO
+                    Point vertex = line.getVertex(ivertex);
+                    double m = vertex.getCoordinateAt(vertex.getDimension() - 1);
+                    if (isInRange(m, m1, m2)) {
+                        // Si la m del vertice actual entra en el rango:
+                        if (previousVertex == null) {
+                            // Si no hay previousVertex, este debe ser el primer
+                            // vertice, entonces
+                            // - añadimos el vértice a la linea
+                            // - marcamos que estamos en un segmento valido
+                            // - nos guardamos el vertice como previousVertex
+                            // - aumentamos el indice para coger el siguiente
+                            // vértice en la próxima iteración
+                            auxLine.addVertex(vertex);
+                            previousVertex = vertex;
+                            inSegment = true;
+                            ivertex++;
+                        } else {
+                            // - Calculamos qué punto habría iniciado el
+                            // segmento válido
+                            double previousM = previousVertex.getCoordinateAt(previousVertex.getDimension() - 1);
+                            // FIXME: Esta comprobación se podría quitar
+                            if (isInRange(m1, previousM, m) || isInRange(m2, previousM, m)) {
+                                Point point = getPointWithMBetweenTwoMPoints(m1, previousVertex, vertex);
+                                if (point == null) {
+                                    point = getPointWithMBetweenTwoMPoints(m2, previousVertex, vertex);
+                                }
+                                if (point != null) {
+                                    // - Añadimos el punto a la linea auxiliar
+                                    // - Marcamos que estamos en un segmento válido
+                                    // - nos guardamos el punto como previousVertex
+                                    // - y NO aumentamos el indice
+                                    auxLine.addVertex(point);
+                                    inSegment = true;
+                                    previousVertex = point;
+                                } else {
+                                    // Nunca debería pasar por aquí
+                                }
+                            }
+                        }
+                    } else {
+                        // Cabe la posibilidad de que entre un vertice y otro se
+                        // entre y se salga del rango
+                        if (previousVertex != null) {
+                            double previousM = previousVertex.getCoordinateAt(previousVertex.getDimension() - 1);
+                            if (isInRange(m1, previousM, m) && isInRange(m2, previousM, m)) {
+                                Point point1 = getPointWithMBetweenTwoMPoints(m1, previousVertex, vertex);
+                                Point point2 = getPointWithMBetweenTwoMPoints(m2, previousVertex, vertex);
+                                auxLine.addVertex(point1);
+                                auxLine.addVertex(point2);
+                                lines.addPrimitive(auxLine);
+                            }
+                        }
+
+                        // Si la m del vértice actual no entra en el rango:
+                        // - nos guardamos el vertice como previousVertex
+                        // - aumentamos el indice para coger el siguiente
+                        // vértice en la próxima iteración
+                        previousVertex = vertex;
+                        ivertex++;
+                    }
+                } else { // ESTAMOS EN UN SEGMENTO VALIDO
+                    Point vertex = line.getVertex(ivertex);
+                    double m = vertex.getCoordinateAt(previousVertex.getDimension() - 1);
+                    if (isInRange(m, m1, m2)) {
+                        // Si la m del vertice actual entra en el rango:
+                        // - añadimos el vértice a la linea
+                        // - aumentamos el indice para coger el siguiente
+                        // vértice en la próxima iteración
+                        auxLine.addVertex(vertex);
+                        previousVertex = vertex;
+                        ivertex++;
+                    } else {
+                        // Si la m del vértice actual no entra en el rango:
+                        // - Calculamos el punto que habría finalizado el
+                        // segmento válido entre el vertice anterior y el actual
+                        Point point = getPointWithMBetweenTwoMPoints(m1, previousVertex, vertex);
+                        if (point == null) {
+                            point = getPointWithMBetweenTwoMPoints(m2, previousVertex, vertex);
+                        }
+                        if (point != null) {
+                            // - Añadimos el punto a la linea auxiliar
+                            // - añadimos la linea y creamos una nueva
+                            // - Marcamos que NO estamos en un segmento válido
+                            // - nos guardamos el punto como previousVertex
+                            // - y NO aumentamos el indice
+                            auxLine.addVertex(point);
+                            lines.addPrimitive(auxLine);
+                            auxLine =
+                                (Line) geomManager.create(Geometry.TYPES.LINE, line.getGeometryType().getSubType());
+                            inSegment = false;
+                            previousVertex = point;
+                        } else {
+                            // Nunca debería pasar por aquí
+                        }
+                    }
+                }
+            }
+        }
+        if (inSegment && auxLine.getNumVertices() > 0) {
+            lines.addPrimitive(auxLine);
+        }
+        return lines;
+    }
+
+    /*
+     *
+     */
+    private static Point getPointWithMBetweenTwoMPoints(double m, Point p1, Point p2) throws CreateGeometryException,
+        LocatorException {
+        double x;
+        double y;
+        double m1 = p1.getCoordinateAt(p1.getDimension() - 1);
+        double m2 = p2.getCoordinateAt(p2.getDimension() - 1);
+
+        if (m1 <= m2) {
+            if (m < m1 || m > m2) {
+                return null;
+            }
+        } else {
+            if (m < m2 || m > m1) {
+                return null;
+            }
+        }
+
+        double x1 = p1.getX();
+        double x2 = p2.getX();
+        double y1 = p1.getY();
+        double y2 = p2.getY();
+        if (x1 == x2) {
+            x = x1;
+        } else {
+            x = ((x2 - x1) * (m - m1) / (m2 - m1)) + x1;
+        }
+        if (y1 == y2) {
+            y = y1;
+        } else {
+            y = ((y2 - y1) * (m - m1) / (m2 - m1)) + y1;
+        }
+
+        Point point = (Point) GeometryLocator.getGeometryManager().create(p1.getGeometryType());
+        point.setX(x);
+        point.setY(y);
+        point.setCoordinateAt(point.getDimension() - 1, m);
+        return point;
+    }
+
+
+
+    /**
+     * Returns geometry length without gaps
+     * @param geometry
+     * @return
+     * @throws GeometryOperationNotSupportedException
+     * @throws GeometryOperationException
+     */
+    static protected Double getGeometryLength(Geometry geometry) throws GeometryOperationNotSupportedException, GeometryOperationException{
+        return getGeometryLength(geometry, true);
+    }
+
+    /**
+     * Returns geometry length without gaps with the option to not ignore spatial gaps.
+     * @param geometry
+     * @param ignoreSpatialGaps
+     * @return
+     * @throws GeometryOperationNotSupportedException
+     * @throws GeometryOperationException
+     */
+    static protected Double getGeometryLength(Geometry geometry,
+        boolean ignoreSpatialGaps)
+            throws GeometryOperationNotSupportedException,
+            GeometryOperationException {
+        if (geometry instanceof Line) {
+            Line line = (Line) geometry;
+            return getLineLength(line);
+        }
+        if (geometry instanceof MultiLine) {
+            MultiLine multiLine = (MultiLine) geometry;
+            return getMultiLineLength(multiLine, ignoreSpatialGaps);
+        }
+        return Double.NaN;
+    }
+
+    /**
+     * @param line
+     * @return lenght
+     * @throws GeometryOperationException
+     * @throws GeometryOperationNotSupportedException
+     */
+    static protected double getLineLength(Line line)
+        throws GeometryOperationNotSupportedException,
+        GeometryOperationException {
+        double lenght = 0;
+        Point previousVertex = null;
+        for (int i = 0; i < line.getNumVertices(); i++) {
+            Point vertex = line.getVertex(i);
+            if (previousVertex != null) {
+                lenght += previousVertex.distance(vertex);
+            }
+            previousVertex = vertex;
+        }
+        return lenght;
+    }
+
+    /**
+     * @param multiLine
+     * @return lenght
+     * @throws GeometryOperationException
+     * @throws GeometryOperationNotSupportedException
+     */
+    static protected double getMultiLineLength(MultiLine multiLine,
+        boolean ignoreSpatialGaps)
+            throws GeometryOperationNotSupportedException,
+            GeometryOperationException {
+        double length = 0;
+        Point previousVertex = null;
+        for (int j = 0; j < multiLine.getPrimitivesNumber(); j++) {
+            Line line = (Line) multiLine.getPrimitiveAt(j);
+            if (ignoreSpatialGaps) {
+                previousVertex = null;
+            }
+            for (int i = 0; i < line.getNumVertices(); i++) {
+                Point vertex = line.getVertex(i);
+                if (previousVertex != null) {
+                    length += previousVertex.distance(vertex);
+                }
+                previousVertex = vertex;
+            }
+        }
+        return length;
+    }
+
+    /**
+     * Extracts the lines in a Line or Multiline
+     * @param geometry
+     * @return
+     */
+    static protected List<Line> extractLines(Geometry geometry){
+        List<Line> lines=new ArrayList<Line>();
+        if (geometry instanceof  Line){
+            lines.add((Line) geometry);
+        }
+        if (geometry instanceof MultiLine){
+            MultiLine multiline=(MultiLine)geometry;
+            for (int i=0;i<multiline.getPrimitivesNumber();i++){
+                lines.add((Line) multiline.getPrimitiveAt(i));
+            }
+        }
+        return lines;
+    }
+
+    static protected List<Point> extractPoints(Geometry geometry){
+        List<Point> points=new ArrayList<Point>();
+        List<Line> lines=LrsAlgorithmUtils.extractLines(geometry);
+        for (Line line: lines){
+            for (int i=0;i<line.getNumVertices();i++){
+                points.add(line.getVertex(i));
+            }
+        }
+        return points;
+    }
+
+
+    static protected Point extractFirstPoint(Geometry geometry){
+        Point firstPoint=null;
+        List<Line> lines= LrsAlgorithmUtils.extractLines(geometry);
+        if (lines!=null && !lines.isEmpty()){
+            firstPoint=lines.get(0).getVertex(0);
+        }
+        return firstPoint;
+    }
+
+    static protected boolean equalPoints(Point point1, Point point2){
+        if ( point1.getX()==point2.getX() && point1.getY()==point2.getY()){
+            return true;
+        }
+        return false;
+    }
+
+    static protected Geometry insertVertex(Geometry geometry, Point vertex, int index){
+        if (geometry instanceof Line){
+            Line line=(Line)geometry;
+            line.insertVertex(index, vertex);
+        }
+        if (geometry instanceof MultiLine){
+            List<Line> lines=extractLines(geometry);
+            for(Line line:lines){
+                if (index<=line.getNumVertices()){
+                    line.insertVertex(index, vertex);
+                    return geometry;
+                }else{
+                    index-=line.getNumVertices();
+                }
+
+            }
+        }
+        return geometry;
+    }
+
+    /**
+     * Reduced versión of straight line through two points equation to calculate M's
+     *
+     * @param totalLength
+     * @param minValue
+     * @param maxValue
+     * @param relativeDistance
+     * @return
+     */
+    static protected double calculateM(Double totalLength, Double minValue, Double maxValue, Double relativeDistance) {
+        return LrsAlgorithmUtils.straightLineThroughTwoPointsEquation(0, totalLength, minValue, maxValue, relativeDistance);
+    }
+
+    /**
+     * Straight line through two points equation.
+     *
+     * @param x1
+     * @param x2
+     * @param y1
+     * @param y2
+     * @param x
+     * @return
+     */
+    static protected double straightLineThroughTwoPointsEquation(double x1, double x2, double y1, double y2, double x) {
+        if (x2 - x1 == 0.0) {
+            return Double.POSITIVE_INFINITY;
+        }
+        return ((y2 - y1) * (x - x1) / (x2 - x1)) + y1;
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultLrsEditRouteCalibrationSelectIdRouteAlgorithmParams.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultLrsEditRouteCalibrationSelectIdRouteAlgorithmParams.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultLrsEditRouteCalibrationSelectIdRouteAlgorithmParams.java	(revision 950)
@@ -0,0 +1,75 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.lib.impl;
+
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.feature.NewFeatureStoreParameters;
+import org.gvsig.lrs.lib.api.DistanceUnits;
+import org.gvsig.lrs.lib.api.LrsCalibrateRouteAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsEditRouteCalibrationSelectIdRouteAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsMeasureCalculationMethods;
+
+
+/**
+ * @author dmartinez
+ *
+ */
+public class DefaultLrsEditRouteCalibrationSelectIdRouteAlgorithmParams implements LrsEditRouteCalibrationSelectIdRouteAlgorithmParams {
+
+    private FeatureAttributeDescriptor idRouteField;
+    private final String NAME = "LrsEditRouteCalibrationSelectIdRouteAlgorithm";
+    private final String DESCRIPTION = "Algorithm to select id route to edit calibration with linear reference system.";
+
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithmParams#getName()
+     */
+    public String getName() {
+        return NAME;
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithmParams#getDescription()
+     */
+    public String getDescription() {
+        return DESCRIPTION;
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#getIdRouteField()
+     */
+    public FeatureAttributeDescriptor getIdRouteField() {
+        return idRouteField;
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams#setIdRouteField(org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor)
+     */
+    public void setIdRouteField(FeatureAttributeDescriptor idRouteField) {
+        this.idRouteField = idRouteField;
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultLrsAlgorithmsManager.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultLrsAlgorithmsManager.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultLrsAlgorithmsManager.java	(revision 950)
@@ -0,0 +1,324 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.lib.impl;
+
+import org.gvsig.lrs.lib.api.MeasuresCalculator;
+
+import java.util.List;
+
+import org.apache.commons.lang3.StringUtils;
+import org.cresques.cts.IProjection;
+
+import org.gvsig.fmap.dal.DALLocator;
+import org.gvsig.fmap.dal.DataManager;
+import org.gvsig.fmap.dal.DataServerExplorer;
+import org.gvsig.fmap.dal.DataServerExplorerParameters;
+import org.gvsig.fmap.dal.DataStoreParameters;
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.dal.exception.InitializeException;
+import org.gvsig.fmap.dal.exception.ProviderNotRegisteredException;
+import org.gvsig.fmap.dal.exception.ValidateDataParametersException;
+import org.gvsig.fmap.dal.feature.EditableFeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.EditableFeatureType;
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.feature.FeatureType;
+import org.gvsig.fmap.dal.feature.NewFeatureStoreParameters;
+import org.gvsig.fmap.geom.DataTypes;
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.geom.GeometryLocator;
+import org.gvsig.fmap.geom.GeometryManager;
+import org.gvsig.fmap.geom.exception.CreateGeometryException;
+import org.gvsig.fmap.geom.operation.GeometryOperationException;
+import org.gvsig.fmap.geom.operation.GeometryOperationNotSupportedException;
+import org.gvsig.fmap.geom.primitive.Line;
+import org.gvsig.fmap.geom.primitive.Point;
+import org.gvsig.fmap.geom.type.GeometryType;
+import org.gvsig.fmap.geom.type.GeometryTypeNotSupportedException;
+import org.gvsig.fmap.geom.type.GeometryTypeNotValidException;
+import org.gvsig.lrs.lib.api.LrsAlgorithm;
+import org.gvsig.lrs.lib.api.LrsAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsAlgorithmsManager;
+import org.gvsig.lrs.lib.api.LrsCalibrateRouteAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsEditRouteCalibrationAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsEditRouteCalibrationSelectIdRouteAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsGenerateDynamicSegmentationAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsShowMeasuresAlgorithmParams;
+import org.gvsig.tools.dynobject.DynObject;
+import org.gvsig.tools.locator.LocatorException;
+import org.gvsig.tools.service.Service;
+import org.gvsig.tools.service.ServiceException;
+
+
+/**
+ * @author fdiaz
+ *
+ */
+public class DefaultLrsAlgorithmsManager implements LrsAlgorithmsManager {
+
+    /* (non-Javadoc)
+     * @see org.gvsig.tools.service.Manager#createServiceParameters(java.lang.String)
+     */
+    public DynObject createServiceParameters(String serviceName) throws ServiceException {
+        // TODO Auto-generated method stub
+        return null;
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.tools.service.Manager#getService(org.gvsig.tools.dynobject.DynObject)
+     */
+    public Service getService(DynObject parameters) throws ServiceException {
+        // TODO Auto-generated method stub
+        return null;
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithmsManager#createLrsAlgorithm(org.gvsig.lrs.lib.api.LrsAlgorithmParams)
+     */
+    public LrsAlgorithm createLrsAlgorithm(LrsAlgorithmParams params) {
+        if(params instanceof LrsCreateRouteAlgorithmParams){
+            return new LrsCreateRouteAlgorithm((LrsCreateRouteAlgorithmParams)params);
+        }
+        if(params instanceof LrsCalibrateRouteAlgorithmParams){
+            return new LrsCalibrateRouteAlgorithm((LrsCalibrateRouteAlgorithmParams)params);
+        }
+        if(params instanceof LrsGenerateDynamicSegmentationAlgorithmParams){
+            return new LrsGenerateDynamicSegmentationAlgorithm((LrsGenerateDynamicSegmentationAlgorithmParams)params);
+        }
+        return null;
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithmsManager#createLrsCreateRouteAlgorithmParams()
+     */
+    public LrsCreateRouteAlgorithmParams createLrsCreateRouteAlgorithmParams() {
+        return new DefaultLrsCreateRouteAlgorithmParams();
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithmsManager#createLrsCalibrateRouteAlgorithmParams()
+     */
+    public LrsCalibrateRouteAlgorithmParams createLrsCalibrateRouteAlgorithmParams() {
+        return new DefaultLrsCalibrateRouteAlgorithmParams();
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithmsManager#createLrsEditRouteCalibrationAlgorithmParams()
+     */
+    public LrsEditRouteCalibrationAlgorithmParams createLrsEditRouteCalibrationAlgorithmParams() {
+        return new DefaultLrsEditRouteCalibrationAlgorithmParams();
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithmsManager#createLrsEditRouteCalibrationSelectIdRouteAlgorithmParams()
+     */
+    public LrsEditRouteCalibrationSelectIdRouteAlgorithmParams createLrsEditRouteCalibrationSelectIdRouteAlgorithmParams() {
+        return new DefaultLrsEditRouteCalibrationSelectIdRouteAlgorithmParams();
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithmsManager#createLrsShowMeasuresAlgorithmParams()
+     */
+    public LrsShowMeasuresAlgorithmParams createLrsShowMeasuresAlgorithmParams() {
+        return new DefaultLrsShowMeasuresAlgorithmParams();
+    }
+
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithmsManager#createLrsGenerateDynamicSegmentationAlgorithmParams()
+     */
+    public LrsGenerateDynamicSegmentationAlgorithmParams createLrsGenerateDynamicSegmentationAlgorithmParams() {
+        return new DefaultLrsGenerateDynamicSegmentationAlgorithmParams();
+    }
+
+
+    public void createNewShape(FeatureType sourceFeatureType,
+        int outputLayerType, String outputLayerPath, IProjection projection) throws ValidateDataParametersException, DataException, GeometryTypeNotSupportedException, GeometryTypeNotValidException {
+
+        DataManager dataManager = DALLocator.getDataManager();
+        DataServerExplorerParameters eparams =
+            dataManager.createServerExplorerParameters("FilesystemExplorer");
+        eparams.setDynValue("initialpath", "/data");
+        DataServerExplorer serverExplorer =
+            dataManager.openServerExplorer(eparams.getExplorerName(), eparams);
+
+        NewFeatureStoreParameters sparams =
+            (NewFeatureStoreParameters) serverExplorer
+                .getAddParameters("Shape");
+
+        EditableFeatureType newEditableFeatureType =
+            (EditableFeatureType) sparams.getDefaultFeatureType();
+
+        // Iterate over feature type. Don't add geometry fields.
+        for (int i = 0; i < sourceFeatureType.size(); i++) {
+            String fieldName =
+                sourceFeatureType.getAttributeDescriptor(i).getName();
+            int fieldType =
+                sourceFeatureType.getAttributeDescriptor(i).getType();
+            if (fieldType != DataTypes.GEOMETRY) {
+                newEditableFeatureType.add(fieldName, fieldType);
+            }
+        }
+
+        // Add new geometry field with new geometry type
+        FeatureAttributeDescriptor geometryAttribute =
+            (FeatureAttributeDescriptor) sourceFeatureType
+                .get(sourceFeatureType.getDefaultGeometryAttributeName());
+        EditableFeatureAttributeDescriptor newGeometryAttribute =
+            newEditableFeatureType.add(geometryAttribute.getName(),
+                geometryAttribute.getType(), geometryAttribute.getSize());
+
+        GeometryManager geoManager = GeometryLocator.getGeometryManager();
+        GeometryType sourceLayerGeomType =
+            sourceFeatureType.getDefaultGeometryAttribute().getGeomType();
+        GeometryType outputLayerGeomType =
+            geoManager.getGeometryType(outputLayerType,
+                sourceLayerGeomType.getSubType());
+
+        newGeometryAttribute.setGeometryType(outputLayerGeomType);
+        newGeometryAttribute.setPrecision(geometryAttribute.getPrecision());
+        newGeometryAttribute.setDefaultValue(geometryAttribute
+            .getDefaultValue());
+
+        newEditableFeatureType
+            .setDefaultGeometryAttributeName(geometryAttribute.getName());
+
+        if(!StringUtils.endsWithIgnoreCase(outputLayerPath, ".shp")){
+            outputLayerPath = new StringBuilder().append(outputLayerPath).append(".shp").toString();
+        }
+
+        sparams.setDynValue("geometryType", null);
+        sparams.setDynValue("shpfile", outputLayerPath);
+        sparams.setDynValue("CRS", projection);
+        sparams.setDynValue("useNullGeometry", false);
+        sparams.setDefaultFeatureType(newEditableFeatureType);
+        sparams.validate();
+
+        serverExplorer.add("Shape", sparams, true);
+    }
+
+    public FeatureStore getFeatureStore(String outputLayerPath,
+        IProjection projection) throws InitializeException, ProviderNotRegisteredException, ValidateDataParametersException{
+
+        DataManager dataManager = DALLocator.getDataManager();
+        DataStoreParameters dataStoreParams =
+            dataManager.createStoreParameters("Shape");
+        dataStoreParams.setDynValue("shpfile", outputLayerPath);
+        dataStoreParams.setDynValue("CRS", projection);
+        dataStoreParams.setDynValue("useNullGeometry", false);
+        dataStoreParams.validate();
+
+        return (FeatureStore) dataManager.openStore("Shape", dataStoreParams);
+    }
+
+    public MeasuresCalculator createMeasuresCalculator(Geometry geometry, boolean ignoreSpatialGaps) {
+        return new DefaultMeasuresCalculator(geometry, ignoreSpatialGaps);
+    }
+
+    @Override
+    public Point getMPointFromGeometry(Geometry geom, double m) throws CreateGeometryException, LocatorException {
+        List<Point> points = LrsAlgorithmUtils.getPointsWithM( geom,  m);
+        if (points!=null && !points.isEmpty()){
+            return points.get(0);
+        }
+        return null;
+    }
+
+    /**
+     * Given a point without m in a M-Geometry, returns the point with the m-value
+     * @param geom
+     * @param pointNoM
+     * @return
+     * @throws GeometryOperationException
+     * @throws GeometryOperationNotSupportedException
+     * @throws CreateGeometryException
+     */
+    @Override
+    public Point getMPointFromGeometry(Geometry geom, Point pointNoM) throws CreateGeometryException, GeometryOperationNotSupportedException, GeometryOperationException{
+        final Double PRECISION = new Double(1.0e-5);
+        final int MDIMENSION = geom.getDimension() - 1;
+
+        List<Line> lines = LrsAlgorithmUtils.extractLines(geom);
+        for (int i = 0; i < lines.size(); i++) {
+            Line line = lines.get(i);
+
+            if (line.isWithinDistance(pointNoM, PRECISION)) {
+                for (int j = 0; j < line.getNumVertices(); j++) {
+                    Point vertex = line.getVertex(j);
+                    Point nextVertex;
+                    if (j + 1 < line.getNumVertices()) {
+                        nextVertex = line.getVertex(j + 1);
+                    } else {
+                        nextVertex = null;
+                    }
+                    //The point and the first vertex are the same
+                    if (LrsAlgorithmUtils.equalPoints(vertex, pointNoM) || vertex.distance(pointNoM) <= PRECISION) {
+                        Double m=vertex.getCoordinateAt(MDIMENSION);
+                        GeometryManager geomanager = GeometryLocator.getGeometryManager();
+                        Point mPoint = (Point) geomanager
+                                .create(Geometry.TYPES.POINT, Geometry.SUBTYPES.GEOM2DM);
+                        mPoint.setX(pointNoM.getX());
+                        mPoint.setY(pointNoM.getY());
+                        mPoint.setCoordinateAt(MDIMENSION, m);
+                        return mPoint;
+                    }else{
+                        if (nextVertex != null
+                            && !LrsAlgorithmUtils.equalPoints(nextVertex, pointNoM)
+                            && vertex.distance(pointNoM) > PRECISION
+                            && nextVertex.distance(pointNoM) > PRECISION) {
+
+                            GeometryManager geomanager = GeometryLocator.getGeometryManager();
+                            Line segment = (Line) geomanager
+                                    .create(Geometry.TYPES.LINE, Geometry.SUBTYPES.GEOM2DM);
+                            segment.addVertex(vertex);
+                            segment.addVertex(nextVertex);
+                            if (segment.isWithinDistance(pointNoM, PRECISION)) {
+                                double distanceFirstVertex = 0;
+                                double distanceNextVertex = nextVertex.distance(vertex);
+                                double distanceToFixedPoint = vertex.distance(pointNoM);
+
+                                Double m = LrsAlgorithmUtils.straightLineThroughTwoPointsEquation(
+                                    distanceFirstVertex,
+                                    distanceNextVertex,
+                                    vertex.getCoordinateAt(MDIMENSION),
+                                    nextVertex.getCoordinateAt(MDIMENSION),
+                                    distanceToFixedPoint);
+
+                                Point mPoint = (Point) geomanager
+                                        .create(Geometry.TYPES.POINT, Geometry.SUBTYPES.GEOM2DM);
+                                mPoint.setX(pointNoM.getX());
+                                mPoint.setY(pointNoM.getY());
+                                mPoint.setCoordinateAt(MDIMENSION, m);
+                                return mPoint;
+                            }
+                        }
+                    }
+                }
+            }
+
+        }
+        return null;
+
+    }
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/LrsCreateRouteAlgorithm.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/LrsCreateRouteAlgorithm.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/LrsCreateRouteAlgorithm.java	(revision 950)
@@ -0,0 +1,1294 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.lib.impl;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map.Entry;
+import java.util.SortedMap;
+import java.util.TreeMap;
+
+import org.apache.commons.lang3.mutable.MutableInt;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import org.gvsig.fmap.dal.feature.EditableFeature;
+import org.gvsig.fmap.dal.feature.Feature;
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureSet;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.feature.NewFeatureStoreParameters;
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.geom.Geometry.DIMENSIONS;
+import org.gvsig.fmap.geom.GeometryLocator;
+import org.gvsig.fmap.geom.GeometryManager;
+import org.gvsig.fmap.geom.aggregate.MultiLine;
+import org.gvsig.fmap.geom.exception.CreateEnvelopeException;
+import org.gvsig.fmap.geom.exception.CreateGeometryException;
+import org.gvsig.fmap.geom.operation.GeometryOperationException;
+import org.gvsig.fmap.geom.operation.GeometryOperationNotSupportedException;
+import org.gvsig.fmap.geom.primitive.Envelope;
+import org.gvsig.fmap.geom.primitive.Line;
+import org.gvsig.fmap.geom.primitive.Point;
+import org.gvsig.lrs.lib.api.LrsAlgorithm;
+import org.gvsig.lrs.lib.api.LrsAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsCoordinatesPriority;
+import org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsSourceOfMeasures;
+import org.gvsig.lrs.lib.api.exceptions.LrsCreateRouteException;
+import org.gvsig.lrs.lib.api.exceptions.LrsException;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.dataTypes.DataType;
+import org.gvsig.tools.exception.BaseException;
+import org.gvsig.tools.i18n.I18nManager;
+import org.gvsig.tools.locator.LocatorException;
+import org.gvsig.tools.service.Manager;
+import org.gvsig.tools.task.SimpleTaskStatus;
+import org.gvsig.tools.visitor.VisitCanceledException;
+import org.gvsig.tools.visitor.Visitor;
+
+/**
+ * @author fdiaz
+ *
+ */
+public class LrsCreateRouteAlgorithm implements LrsAlgorithm {
+
+    private static final Logger logger = LoggerFactory.getLogger(LrsCreateRouteAlgorithm.class);
+
+    private LrsCreateRouteAlgorithmParams parameters;
+
+    /**
+     *
+     */
+    public LrsCreateRouteAlgorithm(LrsCreateRouteAlgorithmParams parameters) {
+        this.parameters = parameters;
+
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see org.gvsig.tools.service.Service#getManager()
+     */
+    public Manager getManager() {
+        return null;
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithm#getParams()
+     */
+    public LrsAlgorithmParams getParams() {
+        return this.parameters;
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithm#execute(org.gvsig.tools.task.
+     * SimpleTaskStatus)
+     */
+    public void execute(SimpleTaskStatus taskStatus) throws LrsException {
+        NewFeatureStoreParameters newFeatureStoreParameters = parameters.getNewFeatureStoreParameters();
+        FeatureStore sourceFeatureStore = parameters.getSourceFeatureStore();
+        FeatureAttributeDescriptor idRouteField = parameters.getIdRouteField();
+        FeatureAttributeDescriptor fromMeasureField = parameters.getFromMeasureField();
+        FeatureAttributeDescriptor toMeasureField = parameters.getToMeasureField();
+
+        logger.info(parameters.toString());
+
+        taskStatus.setTitle(parameters.getName());
+        I18nManager i18nManager = ToolsLocator.getI18nManager();
+        taskStatus.message(i18nManager.getTranslation("grouping_features"));
+
+        try {
+            final String routeFieldName = idRouteField.getName();
+            final String fromFieldName;
+            final DataType fromDataType;
+            final DataType toDataType;
+            if (fromMeasureField != null) {
+                fromFieldName = fromMeasureField.getName();
+                fromDataType = fromMeasureField.getDataType();
+            } else {
+                fromFieldName = null;
+                fromDataType = null;
+            }
+            final String toFieldName;
+            if (toMeasureField != null) {
+                toFieldName = toMeasureField.getName();
+                toDataType = toMeasureField.getDataType();
+            } else {
+                toFieldName = null;
+                toDataType = null;
+            }
+
+            FeatureStore newFeatureStore =
+                LrsAlgorithmUtils.createNewDataStore(newFeatureStoreParameters, idRouteField);
+
+            FeatureSet sourceFeatures;
+            if (sourceFeatureStore.getFeatureSelection().getSize() > 0) {
+                sourceFeatures = sourceFeatureStore.getFeatureSelection();
+            } else {
+                sourceFeatures = sourceFeatureStore.getFeatureSet();
+            }
+
+            final SortedMap<String, List<MSegment>> featuresMap = new TreeMap<String, List<MSegment>>();
+            final MutableInt contId = new MutableInt(0);
+            sourceFeatures.accept(new Visitor() {
+
+                public void visit(Object obj) throws VisitCanceledException, BaseException {
+                    Feature feature = (Feature) obj;
+                    String routeName = (String) feature.get(routeFieldName);
+                    Object objFrom = null;
+                    Object objTo = null;
+                    if (fromFieldName != null) {
+                        objFrom = feature.get(fromFieldName);
+                    }
+                    if (toFieldName != null) {
+                        objTo = feature.get(toFieldName);
+                    }
+                    if (!featuresMap.containsKey(routeName)) {
+                        featuresMap.put(routeName, new ArrayList<MSegment>());
+                    }
+                    List<MSegment> mList = featuresMap.get(routeName);
+                    MSegment mSegment = new MSegment();
+                    mSegment.geometry = feature.getDefaultGeometry().cloneGeometry();
+                    mSegment.fromValue = LrsAlgorithmUtils.getAsDouble(objFrom, fromDataType);
+                    mSegment.toValue = LrsAlgorithmUtils.getAsDouble(objTo, toDataType);
+                    mSegment.id = contId.getValue();
+                    contId.increment();
+                    mList.add(mSegment);
+                    featuresMap.put(routeName, mList);
+                }
+            });
+
+            taskStatus.setRangeOfValues(0, featuresMap.size());
+            int taskCount = 0;
+
+            newFeatureStore.edit(FeatureStore.MODE_FULLEDIT);
+
+            for (Entry<String, List<MSegment>> entry : featuresMap.entrySet()) {
+                String routeName = entry.getKey();
+                List<MSegment> mList = entry.getValue();
+
+                EditableFeature newFeature = newFeatureStore.createNewFeature(true);
+                newFeature.set(routeFieldName, routeName);
+                Geometry route = createGeometryRoute(mList);
+                newFeature.setDefaultGeometry(route);
+
+                newFeatureStore.update(newFeature);
+
+                taskCount++;
+                taskStatus.setCurValue(taskCount);
+
+            }
+            newFeatureStore.finishEditing();
+
+        } catch (Exception e1) {
+            taskStatus.abort();
+            throw new LrsCreateRouteException("Error creating routes", e1);
+        }
+
+        taskStatus.terminate();
+
+    }
+
+    private Geometry createGeometryRoute(List<MSegment> mList) throws CreateGeometryException,
+        GeometryOperationNotSupportedException, GeometryOperationException, CreateEnvelopeException {
+        LrsSourceOfMeasures sourceOfMeasures = parameters.getSourceOfMeasures();
+        Geometry geometryResult = null;
+        simplifyMultilines(mList);
+        switch (sourceOfMeasures) {
+        case ONE_FIELD:
+            geometryResult = calculateGeometryByOneField(mList);
+            break;
+        case TWO_FIELDS:
+            geometryResult = calculateGeometryByTwoField(mList);
+            break;
+        case LENGTH:
+        default:
+            geometryResult = calculateGeometryByLength(mList);
+            break;
+        }
+        geometryResult = applyOffsetAndFactor(geometryResult);
+        return geometryResult;
+    }
+
+    private Geometry calculateGeometryByLength(List<MSegment> mList) throws CreateGeometryException,
+        GeometryOperationNotSupportedException, GeometryOperationException, CreateEnvelopeException {
+        boolean ignoreSpatialGaps = parameters.ignoreSpatialGaps();
+        for (MSegment mSegment : mList) {
+            mSegment.fromValue = LrsAlgorithmUtils.getGeometryLength(mSegment.geometry, ignoreSpatialGaps);
+        }
+        return calculateGeometryByOneField(mList);
+    }
+
+    private Geometry calculateGeometryByOneField(List<MSegment> mList) throws CreateGeometryException,
+        GeometryOperationNotSupportedException, GeometryOperationException, CreateEnvelopeException {
+        boolean ignoreSpatialGaps = parameters.ignoreSpatialGaps();
+        GeometryManager gmanager = GeometryLocator.getGeometryManager();
+        try {
+            mList = sortMList(mList);
+        } catch (Exception e) {
+            logger.warn("Geometries couldn't be ordered");
+        }
+
+        MultiLine auxMultiLine = (MultiLine) gmanager.create(Geometry.TYPES.MULTILINE, Geometry.SUBTYPES.GEOM2DM);
+
+        Point previousPoint = null;
+        double previousM = 0.0;
+        for (MSegment mSegment : mList) {
+            Geometry geom = mSegment.geometry;
+            Double geometryLength = mSegment.getLength(ignoreSpatialGaps);
+            if (geom instanceof Line) {
+                Line line = (Line) geom;
+                Line auxLine = (Line) gmanager.create(Geometry.TYPES.LINE, Geometry.SUBTYPES.GEOM2DM);
+                double distance = 0.0;
+                double firstM = previousM;
+                for (int i = 0; i < line.getNumVertices(); i++) {
+                    Point vertex = line.getVertex(i);
+                    Point point = (Point) gmanager.create(Geometry.TYPES.POINT, Geometry.SUBTYPES.GEOM2DM);
+                    point.setX(vertex.getX());
+                    point.setY(vertex.getY());
+                    if (i == 0 && previousPoint != null) {
+                        boolean gap = false;
+                        if (areInSame2DLocation(previousPoint, vertex)) {
+                            // Buscamos si ha sido una bifurcación
+                            Point fork = getPossibleFork(auxMultiLine, vertex);
+                            if(fork!=null){
+                                previousPoint = fork;
+                                // OJO, aquí previousPoint pasa a ser 2DM
+                            }
+                        } else {
+                            // En caso de salto, calculamos el previousPoint
+                            // buscando el vértice más cercano
+                            previousPoint = getClosestVertex(auxMultiLine, vertex);
+                            // OJO, aquí previousPoint pasa a ser 2DM
+                            gap = true;
+                        }
+                        previousM = previousPoint.getCoordinateAt(previousPoint.getDimension() - 1);
+                        if (i == 0) {
+                            firstM = previousM;
+                        }
+                        if (gap && !ignoreSpatialGaps) {
+                            Point previousVertex = getPreviousVertexToPoint(auxMultiLine, previousPoint);
+                            if(areInSame2DLocation(previousPoint,previousVertex)){
+                                Point nextVertex = getNextVertexToPoint(auxMultiLine, previousPoint);
+                                double distanceToNextPoint = nextVertex.distance(previousPoint);
+                                previousM = LrsAlgorithmUtils.straightLineThroughTwoPointsEquation(0, distanceToNextPoint,
+                                    previousM, nextVertex.getCoordinateAt(previousVertex.getDimension() - 1),
+                                        previousPoint.distance(point));
+                            } else {
+                                double distanceToPreviousPoint = previousVertex.distance(previousPoint);
+                                previousM = LrsAlgorithmUtils.straightLineThroughTwoPointsEquation(0, distanceToPreviousPoint,
+                                        previousVertex.getCoordinateAt(previousVertex.getDimension() - 1), previousM,
+                                        distanceToPreviousPoint + previousPoint.distance(point));
+                            }
+                            firstM = previousM;
+                        }
+                    }
+                    if (i != 0) {
+                        distance += previousPoint.distance(vertex);
+                    }
+                    double m =
+                        LrsAlgorithmUtils.straightLineThroughTwoPointsEquation(0, geometryLength, firstM, firstM + mSegment.fromValue,
+                            distance);
+                    point.setCoordinateAt(point.getDimension() - 1, m);
+                    auxLine.addVertex(point);
+                    previousM = m;
+                    previousPoint = vertex;
+                }
+                auxMultiLine.addPrimitive(auxLine);
+            } else if (geom instanceof MultiLine) {
+                MultiLine multiline = (MultiLine) geom;
+                for (int i = 0; i < multiline.getPrimitivesNumber(); i++) {
+                    Line line = (Line) multiline.getPrimitiveAt(i);
+                    Line auxLine = (Line) gmanager.create(Geometry.TYPES.LINE, Geometry.SUBTYPES.GEOM2DM);
+                    double distance = 0.0;
+                    double firstM = previousM;
+                    for (int j = 0; j < line.getNumVertices(); j++) {
+                        Point vertex = line.getVertex(j);
+                        Point point = (Point) gmanager.create(Geometry.TYPES.POINT, Geometry.SUBTYPES.GEOM2DM);
+                        point.setX(vertex.getX());
+                        point.setY(vertex.getY());
+                        if (j == 0 && previousPoint != null) {
+                            boolean gap = false;
+                            if (areInSame2DLocation(previousPoint, vertex)) {
+                                // Buscamos si ha sido una bifurcación
+                                previousPoint = getPossibleFork(auxMultiLine, vertex);
+                                // OJO, aquí previousPoint pasa a ser 2DM
+                            } else {
+                                // En caso de salto, calculamos el previousPoint
+                                // buscando el vértice más cercano
+                                previousPoint = getClosestVertex(auxMultiLine, vertex);
+                                // OJO, aquí previousPoint pasa a ser 2DM
+                                gap = true;
+                            }
+                            previousM = previousPoint.getCoordinateAt(previousPoint.getDimension() - 1);
+                            if (j == 0) {
+                                firstM = previousM;
+                            }
+                            if (gap && !ignoreSpatialGaps) {
+                                Point previousVertex = getPreviousVertexToPoint(auxMultiLine, previousPoint);
+                                previousVertex.getCoordinateAt(previousVertex.getDimension() - 1);
+                                previousM =
+                                    LrsAlgorithmUtils.straightLineThroughTwoPointsEquation(0, previousVertex.distance(previousPoint),
+                                        previousVertex.getCoordinateAt(previousVertex.getDimension() - 1), previousM,
+                                        previousVertex.distance(previousPoint) + previousPoint.distance(point));
+                                firstM = previousM;
+                            }
+                        }
+                        if (j != 0) {
+                            distance += previousPoint.distance(vertex);
+                        }
+                        double m =
+                            LrsAlgorithmUtils.straightLineThroughTwoPointsEquation(0, geometryLength, firstM, firstM + mSegment.fromValue,
+                                distance);
+                        point.setCoordinateAt(point.getDimension() - 1, m);
+                        auxLine.addVertex(point);
+                        previousM = m;
+                        previousPoint = vertex;
+                    }
+                    multiline.addPrimitive(auxLine);
+                }
+            } else {
+                // NO debería entrar por aquí
+                logger.warn("A not LINE nor MULTILINE geometry found in CreateRoute process");
+            }
+        }
+
+        return compactMultiLine(auxMultiLine);
+    }
+
+    /**
+     * Joins consecutive adjacent lines into the multiLine that are not involved in a fork
+     *
+     * @param auxMultiLine
+     * @return
+     * @throws CreateGeometryException
+     * @throws GeometryOperationException
+     * @throws GeometryOperationNotSupportedException
+     */
+    private MultiLine compactMultiLine(MultiLine multiLine) throws CreateGeometryException, GeometryOperationNotSupportedException, GeometryOperationException {
+        GeometryManager geomManager = GeometryLocator.getGeometryManager();
+        MultiLine result =  (MultiLine) geomManager.create(multiLine.getGeometryType());
+
+        int primitivesNumber = multiLine.getPrimitivesNumber();
+        List<Line> lines = new ArrayList<Line>(primitivesNumber);
+        for(int i = 0; i < primitivesNumber; i++){
+            lines.add((Line)multiLine.getPrimitiveAt(i).cloneGeometry());
+        }
+        if (lines.size() > 0) {
+            Line line = lines.get(0);
+            while (lines.size() > 1) {
+                Point lastVertex = line.getVertex(line.getNumVertices() - 1);
+                lines.remove(0);
+                // Borramos la primera linea de la lista ==> lines.get(0) es la siguiente
+                Line line2 = lines.get(0);
+                // Si el ultimo punto de la primera
+                if (lastVertex.equals(line2.getVertex(0)) && !bifurcation(lastVertex, lines)) {
+                    for(int i = 1; i<line2.getNumVertices(); i++){
+                        line.addVertex(line2.getVertex(i));
+                    }
+                } else {
+                    result.addPrimitive(line);
+                    line = line2;
+                }
+            }
+            result.addPrimitive(line);
+        }
+        return result;
+    }
+
+    /**
+     * Checks if a bifurcation occurs at one point.
+     *
+     * @param point
+     * @param lines
+     * @return
+     */
+    private boolean bifurcation(Point point, List<org.gvsig.fmap.geom.primitive.Line> lines) {
+        // Saltamos la primera linea
+        for(int i = 1; i<lines.size(); i++){
+            if(point.equals(lines.get(i).getVertex(0))){
+                return true;
+            }
+        }
+        return false;
+    }
+
+    /**
+     * Returns the previous vertex to a point.
+     *
+     * @param auxMultiLine
+     * @param previousPoint
+     * @return
+     * @throws GeometryOperationException
+     * @throws GeometryOperationNotSupportedException
+     * @throws CreateGeometryException
+     */
+    private Point getPreviousVertexToPoint(MultiLine multiLine, Point point) throws CreateGeometryException,
+        GeometryOperationNotSupportedException, GeometryOperationException {
+        GeometryManager geomManager = GeometryLocator.getGeometryManager();
+        for (int i = 0; i < multiLine.getPrimitivesNumber(); i++) {
+            Line line = (Line) multiLine.getPrimitiveAt(i);
+            if (line.intersects(point)) {
+                for (int j = 0; j < line.getNumVertices() - 1; j++) {
+                    if (point.equals(line.getVertex(j + 1))) {
+                        return line.getVertex(j);
+                    }
+                    Line auxLine = (Line) geomManager.create(Geometry.TYPES.LINE, Geometry.SUBTYPES.GEOM2DM);
+                    auxLine.addVertex(line.getVertex(j));
+                    auxLine.addVertex(line.getVertex(j + 1));
+                    if (auxLine.intersects(point)) {
+                        return line.getVertex(j);
+                    }
+                }
+            }
+        }
+        return null;
+    }
+
+    /**
+     * Returns the next vertex to a point.
+     *
+     * @param auxMultiLine
+     * @param previousPoint
+     * @return
+     * @throws GeometryOperationException
+     * @throws GeometryOperationNotSupportedException
+     * @throws CreateGeometryException
+     */
+    private Point getNextVertexToPoint(MultiLine multiLine, Point point) throws CreateGeometryException,
+        GeometryOperationNotSupportedException, GeometryOperationException {
+        GeometryManager geomManager = GeometryLocator.getGeometryManager();
+        for (int i = 0; i < multiLine.getPrimitivesNumber(); i++) {
+            Line line = (Line) multiLine.getPrimitiveAt(i);
+            if (line.intersects(point)) {
+                for (int j = 0; j < line.getNumVertices() - 1; j++) {
+                    if (point.equals(line.getVertex(j))) {
+                        return line.getVertex(j+1);
+                    }
+                    Line auxLine = (Line) geomManager.create(Geometry.TYPES.LINE, Geometry.SUBTYPES.GEOM2DM);
+                    auxLine.addVertex(line.getVertex(j));
+                    auxLine.addVertex(line.getVertex(j + 1));
+                    if (auxLine.intersects(point)) {
+                        return line.getVertex(j+1);
+                    }
+                }
+            }
+        }
+        return null;
+    }
+
+    /**
+     * Checks if a bifurcation occurs at one point and return the vertex with maximum M
+     *
+     * @param multiLine
+     * @param vertex
+     * @return
+     */
+    private Point getPossibleFork(MultiLine multiLine, Point point) {
+
+        List<Point> vertices = new ArrayList<Point>();
+        for (int i = 0; i < multiLine.getPrimitivesNumber(); i++) {
+            Line line = (Line) multiLine.getPrimitiveAt(i);
+            for (int j = 0; j < line.getNumVertices(); j++) {
+                Point vertex = line.getVertex(j);
+                if (areInSame2DLocation(vertex, point)) {
+                    vertices.add(vertex);
+                }
+            }
+        }
+        if (vertices.size() > 0) {
+            Double maxM = Double.NEGATIVE_INFINITY;
+            Point forked = null;
+            for (Iterator<Point> iterator = vertices.iterator(); iterator.hasNext();) {
+                Point vertex = (Point) iterator.next();
+                double m = vertex.getCoordinateAt(vertex.getDimension() - 1);
+                if (m > maxM) {
+                    maxM = m;
+                    forked = vertex;
+                }
+            }
+            return forked;
+        }
+        return null;
+    }
+
+    /**
+     * Compares x & y coordinates of a point.
+     *
+     * @param p1
+     * @param p2
+     * @return
+     */
+    private boolean areInSame2DLocation(Point p1, Point p2) {
+        return ((p1.getX() == p2.getX()) && (p1.getY() == p2.getY()));
+    }
+
+    /**
+     * Returns the vertex of the multiline closest to a point
+     *
+     * @param mGeometry
+     * @param vertex
+     * @return
+     * @throws GeometryOperationException
+     * @throws GeometryOperationNotSupportedException
+     * @throws CreateEnvelopeException
+     */
+    private Point getClosestVertex(MultiLine multiLine, Point point) throws CreateEnvelopeException,
+        GeometryOperationNotSupportedException, GeometryOperationException {
+        Point result = null;
+        double minDistance = Double.POSITIVE_INFINITY;
+
+        for (int i = 0; i < multiLine.getPrimitivesNumber(); i++) {
+            Line line = (Line) multiLine.getPrimitiveAt(i);
+            for (int j = 0; j < line.getNumVertices(); j++) {
+                Point vertex = line.getVertex(j);
+                double distance = point.distance(vertex);
+                if (distance <= minDistance) {
+                    minDistance = distance;
+                    result = vertex;
+                }
+            }
+        }
+
+        return result;
+    }
+
+    /**
+     * Returns a multiline calculate by two field method
+     *
+     * @param mList
+     * @return
+     * @throws CreateGeometryException
+     * @throws GeometryOperationNotSupportedException
+     * @throws GeometryOperationException
+     */
+    private MultiLine calculateGeometryByTwoField(List<MSegment> mList) throws CreateGeometryException,
+        GeometryOperationNotSupportedException, GeometryOperationException {
+        GeometryManager geomanager = GeometryLocator.getGeometryManager();
+        MultiLine mGeometry = (MultiLine) geomanager.create(Geometry.TYPES.MULTILINE, Geometry.SUBTYPES.GEOM2DM);
+
+        for (MSegment mSegment : mList) {
+            Geometry geometry = mSegment.geometry;
+            List<Line> geometryLines = extractLines(geometry);
+            Double geometryLength = LrsAlgorithmUtils.getGeometryLength(geometry);
+
+            Double geometryMFirstPoint = mSegment.fromValue;
+            Double geometryMLastPoint = mSegment.toValue;
+
+            Double distance = Double.valueOf(0);
+            for (Line line : geometryLines) {
+                Double lineLength = getLineLength(line);
+                Double mFirstPoint = LrsAlgorithmUtils.calculateM(geometryLength, geometryMFirstPoint, geometryMLastPoint, distance);
+                distance += lineLength;
+                Double mLastPoint = LrsAlgorithmUtils.calculateM(geometryLength, geometryMFirstPoint, geometryMLastPoint, distance);
+                Line mLine = lineToMLine(line, mFirstPoint, mLastPoint);
+                mGeometry.addPrimitive(mLine);
+            }
+        }
+
+        return mGeometry;
+    }
+
+    /**
+     * Converts a Line2D in a Line2DM filled it with proportional calculated M's
+     *
+     * @param line
+     * @param minMValue
+     * @param maxMValue
+     * @return
+     * @throws CreateGeometryException
+     * @throws GeometryOperationNotSupportedException
+     * @throws GeometryOperationException
+     */
+    private Line lineToMLine(Line line, Double minMValue, Double maxMValue) throws CreateGeometryException,
+        GeometryOperationNotSupportedException, GeometryOperationException {
+        GeometryManager geomanager = GeometryLocator.getGeometryManager();
+        Double lineLength = getLineLength(line);
+        Line lineM = (Line) geomanager.create(Geometry.TYPES.LINE, Geometry.SUBTYPES.GEOM2DM);
+        Double inLineDistance = Double.valueOf(0);
+        for (int i = 0; i < line.getNumVertices(); i++) {
+            Point vertex = line.getVertex(i);
+            Point mVertex = (Point) geomanager.create(Geometry.TYPES.POINT, Geometry.SUBTYPES.GEOM2DM);
+            mVertex.setX(vertex.getX());
+            mVertex.setY(vertex.getY());
+
+            Double mValue;
+            if (i == 0)
+                mValue = minMValue;
+            else if (i == line.getNumVertices() - 1)
+                mValue = maxMValue;
+            else {
+                Point previousVertex = line.getVertex(i - 1);
+                inLineDistance += vertex.distance(previousVertex);
+                mValue = LrsAlgorithmUtils.calculateM(lineLength, minMValue, maxMValue, inLineDistance);
+            }
+
+            mVertex.setCoordinateAt(mVertex.getDimension() - 1, mValue);
+            lineM.addVertex(mVertex);
+        }
+        return lineM;
+    }
+
+
+    /**
+     * Simplify the multilines in mList calling simplifyMultiline method
+     *
+     * @param mList
+     * @throws CreateGeometryException
+     * @throws LocatorException
+     */
+    private void simplifyMultilines(List<MSegment> mList) throws CreateGeometryException, LocatorException {
+        for (MSegment mSegment : mList) {
+            mSegment.geometry = simplifyMultiline(mSegment.geometry);
+        }
+    }
+
+    /**
+     * Simplify a Multiline ordering and joining her lines if can.
+     *
+     * @param geometry
+     * @return
+     * @throws CreateGeometryException
+     * @throws LocatorException
+     */
+    private Geometry simplifyMultiline(Geometry geometry) throws CreateGeometryException, LocatorException {
+        if (geometry instanceof MultiLine) {
+            MultiLine multiline = (MultiLine) geometry;
+
+            if (multiline.getPrimitivesNumber() == 1) {
+                return multiline.getPrimitiveAt(0);
+            } else {
+                List<Line> simplifiedLines = new ArrayList<Line>();
+                List<Line> complexLines = new ArrayList<Line>();
+                for (int i = 0; i < multiline.getPrimitivesNumber(); i++) {
+                    complexLines.add((Line) multiline.getPrimitiveAt(i));
+                }
+
+                Line line = null;
+                while (complexLines.size() > 0) {
+                    line = complexLines.remove(0);
+                    int i = 0;
+                    while (i < complexLines.size()) {
+                        Line auxLine = complexLines.get(i);
+                        Line unitedLine = unionAdjacentLines(line, auxLine);
+                        if (unitedLine != null) {
+                            line = unitedLine;
+                            complexLines.remove(i);
+                            i = 0;
+                        } else {
+                            i++;
+                        }
+                    }
+                    simplifiedLines.add(line);
+                }
+
+                if (simplifiedLines.size() == 1) {
+                    geometry = simplifiedLines.get(0);
+                } else {
+                    MultiLine simplifiedMultiLine =
+                        (MultiLine) GeometryLocator.getGeometryManager().create(multiline.getGeometryType());
+                    for (Line simpleLine : simplifiedLines) {
+                        simplifiedMultiLine.addPrimitive(simpleLine);
+                    }
+                    return simplifiedMultiLine;
+                }
+            }
+        }
+        return geometry;
+    }
+
+    /**
+     * Join two adjacent lines flipping it if necessary
+     *
+     * @param line1
+     * @param line2
+     * @return
+     */
+    private Line unionAdjacentLines(Line line1, Line line2) {
+        if (line1 == null || line2 == null) {
+            return null;
+        }
+        Line resultLine;
+        try {
+            resultLine = (Line) GeometryLocator.getGeometryManager().create(line1.getGeometryType());
+        } catch (Exception e) {
+            return null;
+        }
+
+        Point firstPointL1 = line1.getVertex(0);
+        Point lastPointL1 = line1.getVertex(line1.getNumVertices() - 1);
+        Point firstPointL2 = line2.getVertex(0);
+        Point lastPointL2 = line2.getVertex(line2.getNumVertices() - 1);
+        if (lastPointL1.equals(firstPointL2)) {
+            resultLine = (Line) line1.cloneGeometry();
+            for (int i = 1; i < line2.getNumVertices(); i++) {
+                resultLine.addVertex((Point) line2.getVertex(i).cloneGeometry());
+            }
+            return resultLine;
+        }
+        if (lastPointL2.equals(firstPointL1)) {
+            resultLine = (Line) line2.cloneGeometry();
+            for (int i = 1; i < line1.getNumVertices(); i++) {
+                resultLine.addVertex((Point) line1.getVertex(i).cloneGeometry());
+            }
+            return resultLine;
+        }
+        if (firstPointL1.equals(firstPointL2)) {
+            for (int i = line1.getNumVertices() - 1; i >= 0; i--) {
+                resultLine.addVertex((Point) line1.getVertex(i).cloneGeometry());
+            }
+            for (int i = 1; i < line2.getNumVertices(); i++) {
+                resultLine.addVertex((Point) line2.getVertex(i).cloneGeometry());
+            }
+            return resultLine;
+        }
+        if (lastPointL1.equals(lastPointL2)) {
+            resultLine = (Line) line1.cloneGeometry();
+            for (int i = line2.getNumVertices() - 2; i >= 0; i--) {
+                resultLine.addVertex((Point) line2.getVertex(i).cloneGeometry());
+            }
+            return resultLine;
+        }
+        return null;
+    }
+
+    /**
+     * Sorts mList
+     *
+     * @param mList
+     * @return
+     * @throws CreateEnvelopeException
+     * @throws GeometryOperationNotSupportedException
+     * @throws GeometryOperationException
+     */
+    private List<MSegment> sortMList(List<MSegment> mList) throws CreateEnvelopeException,
+        GeometryOperationNotSupportedException, GeometryOperationException {
+        LrsCoordinatesPriority coordinatePriority = parameters.getCoordinatePriority();
+        GeometryManager geomanager = GeometryLocator.getGeometryManager();
+        Envelope envelope = geomanager.createEnvelope(Geometry.SUBTYPES.GEOM2D);
+        for (MSegment mSegment : mList) {
+            envelope.add(mSegment.geometry.getEnvelope());
+        }
+        Point origin = envelope.getLowerCorner();
+        switch (coordinatePriority) {
+        case DOWN_LEFT:
+            break;
+        case DOWN_RIGHT:
+            Double maxX = envelope.getMaximum(DIMENSIONS.X);
+            origin.setX(maxX);
+            break;
+        case UP_LEFT:
+            Double maxY = envelope.getMaximum(DIMENSIONS.Y);
+            origin.setY(maxY);
+            break;
+        case UP_RIGHT:
+            origin = envelope.getUpperCorner();
+            break;
+        default:
+            break;
+        }
+
+        List<Stretch> stretches = createStretches(mList, origin);
+        stretches = sortStretches(stretches, origin);
+        return extractSegmentsFromStretches(stretches);
+    }
+
+    /**
+     * Extracts segment from stretches and returns a list of segment.
+     *
+     * @param stretches
+     * @return
+     */
+    private List<MSegment> extractSegmentsFromStretches(List<Stretch> stretches) {
+        List<MSegment> result = new ArrayList<MSegment>();
+        for (Stretch stretch : stretches) {
+            for (int i = 0; i < stretch.getSegmentNumber(); i++) {
+                result.add(stretch.getSegment(i));
+            }
+        }
+        return result;
+    }
+
+    /**
+     * Sort the stretches
+     *
+     * @param stretches
+     * @param origin
+     * @return
+     * @throws GeometryOperationNotSupportedException
+     * @throws GeometryOperationException
+     */
+    private List<Stretch> sortStretches(List<Stretch> stretches, Point origin)
+        throws GeometryOperationNotSupportedException, GeometryOperationException {
+        List<Stretch> result = new ArrayList<Stretch>();
+
+        Point originPoint = origin;
+        while (result.size() < stretches.size()) {
+            // Buscamos tramos que sean adyacentes al origin
+            if (result.size() == 0) {
+                addUnvisitedAdjacentStretches(stretches, result, originPoint);
+            }
+            if (result.size() == 0) {
+                result.add(getNearestUnvisitedStretch(stretches, originPoint, result));
+            }
+
+            boolean addedAdjacentStretches = true;
+            while (addedAdjacentStretches) {
+                addedAdjacentStretches = false;
+                int visitedNumber = result.size();
+                for (int i = 0; i < visitedNumber; i++) {
+                    Stretch visited = result.get(i);
+                    addUnvisitedAdjacentStretches(stretches, result, visited.getFinalPoint());
+                }
+                addedAdjacentStretches = (visitedNumber < result.size());
+            }
+
+            int visitedNumber = result.size();
+            Stretch nearest = null;
+            for (int i = visitedNumber - 1; i >= 0; i--) {
+                if(nearest!=null){
+                    break;
+                }
+                Stretch visited = result.get(i);
+                for (int j=0; j<visited.getSegmentNumber(); j++) {
+                    if(nearest!=null){
+                        break;
+                    }
+                    MSegment segment = visited.getSegment(j);
+                    Geometry geom = segment.geometry;
+                    if(geom instanceof Line){
+                        Line line = (Line)geom;
+                        for (int k=0; k<line.getNumVertices(); k++){
+                            nearest = getNearestUnvisitedStretch(stretches, line.getVertex(k), result);
+                            if (nearest != null) {
+                                result.add(nearest);
+                                break;
+                            }
+                        }
+                    } else { //geom is multiline
+                        MultiLine multiline = (MultiLine)geom;
+                        for (int l=0; l<multiline.getPrimitivesNumber(); l++){
+                            if(nearest!=null){
+                                break;
+                            }
+                            Line line = (Line)multiline.getPrimitiveAt(l);
+                            for (int k=0; k<line.getNumVertices(); k++){
+                                nearest = getNearestUnvisitedStretch(stretches, line.getVertex(k), result);
+                                if (nearest != null) {
+                                    result.add(nearest);
+                                    break;
+                                }
+                            }
+
+                        }
+                    }
+                }
+            }
+        }
+        return result;
+    }
+
+    /**
+     * Adds unvisited adjacent stretches to the visited list
+     *
+     * @param stretches
+     * @param visited
+     * @param originPoint
+     * @throws GeometryOperationNotSupportedException
+     * @throws GeometryOperationException
+     */
+    private void addUnvisitedAdjacentStretches(List<Stretch> stretches, List<Stretch> visited, Point originPoint)
+        throws GeometryOperationNotSupportedException, GeometryOperationException {
+        for (Stretch stretch : stretches) {
+            if (!visited.contains(stretch)) {
+                if (areInSame2DLocation(stretch.getInitialPoint(), originPoint)) {
+                    visited.add(stretch);
+                } else if (areInSame2DLocation(stretch.getFinalPoint(), originPoint)) {
+                    visited.add(stretch.flip());
+                }
+            }
+        }
+    }
+
+    /**
+     * Returns the unvisited stretch nearest to a point
+     *
+     * @param stretches
+     * @param origin
+     * @param visited
+     * @return
+     * @throws GeometryOperationNotSupportedException
+     * @throws GeometryOperationException
+     */
+    private Stretch getNearestUnvisitedStretch(List<Stretch> stretches, Point origin, List<Stretch> visited)
+        throws GeometryOperationNotSupportedException, GeometryOperationException {
+
+        double minDistance = Double.POSITIVE_INFINITY;
+        Stretch nearest = null;
+        boolean needFlip = false;
+        for (Stretch stretch : stretches) {
+            if (!visited.contains(stretch)) {
+                Double initialDistance = origin.distance(stretch.getInitialPoint());
+                if (initialDistance < minDistance) {
+                    minDistance = initialDistance;
+                    nearest = stretch;
+                    needFlip = false;
+                }
+                Double finalDistance = origin.distance(stretch.getFinalPoint());
+                if (finalDistance < minDistance) {
+                    minDistance = finalDistance;
+                    nearest = stretch;
+                    needFlip = true;
+                }
+            }
+        }
+        if (needFlip && nearest != null) {
+            nearest.flip();
+        }
+        return nearest;
+    }
+
+    /**
+     * Creates stretches from mList and returns a list of stretches
+     *
+     * @param mList
+     * @param origin
+     * @return
+     * @throws GeometryOperationNotSupportedException
+     * @throws GeometryOperationException
+     */
+    private List<Stretch> createStretches(List<MSegment> mList, Point origin)
+        throws GeometryOperationNotSupportedException, GeometryOperationException {
+
+        List<MSegment> addedMSegment = new ArrayList<LrsCreateRouteAlgorithm.MSegment>();
+        List<Stretch> stretches = new ArrayList<Stretch>();
+        while (addedMSegment.size() < mList.size()) {
+            for (MSegment mSegment : mList) {
+                if (!addedMSegment.contains(mSegment)) {
+                    Stretch stretch = new Stretch();
+                    stretches.add(stretch);
+                    stretch.addSegment(mSegment);
+                    addedMSegment.add(mSegment);
+
+                    List<MSegment> initialNextSegments =
+                        mSegment.searchNextSegments(stretch.getInitialPoint(), mList);
+                    do {
+                        if (initialNextSegments.size() == 1) {
+                            MSegment previousSegment = initialNextSegments.get(0);
+                            if (!addedMSegment.contains(previousSegment)) {
+                                if (!previousSegment.getFinalPoint().equals(stretch.getInitialPoint())) {
+                                    previousSegment.flip();
+                                }
+                                stretch.addSegment(0, previousSegment);
+                                addedMSegment.add(previousSegment);
+                                initialNextSegments =
+                                    previousSegment.searchNextSegments(stretch.getInitialPoint(), mList);
+                            } else {
+                                break;
+                            }
+                        } else {
+                            break;
+                        }
+                    } while (initialNextSegments.size() == 1);
+
+                    List<MSegment> finalNextSegments =
+                        mSegment.searchNextSegments(stretch.getFinalPoint(), mList);
+                    do {
+                        if (finalNextSegments.size() == 1) {
+                            MSegment nextSegment = finalNextSegments.get(0);
+                            if (!addedMSegment.contains(nextSegment)) {
+                                if (!nextSegment.getInitialPoint().equals(stretch.getFinalPoint())) {
+                                    nextSegment.flip();
+                                }
+                                stretch.addSegment(nextSegment);
+                                addedMSegment.add(nextSegment);
+                                finalNextSegments =
+                                    nextSegment.searchNextSegments(stretch.getFinalPoint(), mList);
+                            } else {
+                                break;
+                            }
+                        } else {
+                            break;
+                        }
+                    } while ((finalNextSegments.size() == 1));
+                }
+            }
+        }
+        return stretches;
+    }
+
+    /**
+     * Extracts lines of a geometry.
+     *
+     * @param geometry
+     * @return
+     */
+    private List<Line> extractLines(Geometry geometry) {
+        List<Line> lines = new ArrayList<Line>();
+        if (geometry instanceof Line) {
+            lines.add((Line) geometry);
+        }
+        if (geometry instanceof MultiLine) {
+            MultiLine multiline = (MultiLine) geometry;
+            for (int i = 0; i < multiline.getPrimitivesNumber(); i++) {
+                lines.add((Line) multiline.getPrimitiveAt(i));
+            }
+        }
+        return lines;
+    }
+
+    /**
+     * Applies offsetAndFactor to a route
+     *
+     * @param geometry
+     * @return
+     */
+    private Geometry applyOffsetAndFactor(Geometry geometry) {
+        double measureFactor = parameters.getMeasureFactor();
+        double measureOffset = parameters.getMeasureOffset();
+        if (geometry instanceof Line) {
+            Line line = (Line) geometry;
+            for (int i = 0; i < line.getNumVertices(); i++) {
+                Point mVertex = line.getVertex(i);
+                Double mValue = mVertex.getCoordinateAt(mVertex.getDimension() - 1);
+                Double newMValue = (mValue * measureFactor) + measureOffset;
+                mVertex.setCoordinateAt(mVertex.getDimension() - 1, newMValue);
+                line.setVertex(i, mVertex);
+            }
+        }
+        if (geometry instanceof MultiLine) {
+            MultiLine multiLine = (MultiLine) geometry;
+            for (int i = 0; i < multiLine.getPrimitivesNumber(); i++) {
+                Line line = (Line) multiLine.getPrimitiveAt(i);
+                for (int j = 0; j < line.getNumVertices(); j++) {
+                    Point mVertex = line.getVertex(j);
+                    Double mValue = mVertex.getCoordinateAt(mVertex.getDimension() - 1);
+                    Double newMValue = (mValue * measureFactor) + measureOffset;
+                    mVertex.setCoordinateAt(mVertex.getDimension() - 1, newMValue);
+                    line.setVertex(j, mVertex);
+                }
+            }
+        }
+        return geometry;
+    }
+
+    /**
+     * Returns the geometric length of a line
+     *
+     * @param line
+     * @return lenght
+     * @throws GeometryOperationException
+     * @throws GeometryOperationNotSupportedException
+     */
+    private double getLineLength(Line line) throws GeometryOperationNotSupportedException, GeometryOperationException {
+        double lenght = 0;
+        Point previousVertex = null;
+        for (int i = 0; i < line.getNumVertices(); i++) {
+            Point vertex = line.getVertex(i);
+            if (previousVertex != null) {
+                lenght += previousVertex.distance(vertex);
+            }
+            previousVertex = vertex;
+        }
+        return lenght;
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithm#setParams(org.gvsig.lrs.lib.api.
+     * LrsAlgorithmParams)
+     */
+    public void setParams(LrsAlgorithmParams params) throws IllegalArgumentException {
+        if (!(params instanceof LrsCreateRouteAlgorithmParams)) {
+            throw new IllegalArgumentException("params should be LrsCreateRouteAlgorithmParams type.");
+        }
+        this.parameters = (LrsCreateRouteAlgorithmParams) params;
+    }
+
+    private class MSegment {
+
+        Geometry geometry;
+        Double fromValue;
+        Double toValue;
+        int id;
+
+        protected MSegment clone() {
+            MSegment cloned = new MSegment();
+            cloned.geometry = geometry.cloneGeometry();
+
+            cloned.fromValue = null;
+            if (fromValue != null) {
+                cloned.fromValue = new Double(fromValue);
+            }
+
+            cloned.toValue = null;
+            if (toValue != null) {
+                cloned.toValue = new Double(toValue);
+            }
+
+            cloned.id = id;
+
+            return cloned;
+        }
+
+        protected Point getInitialPoint() {
+            if (geometry instanceof Line) {
+                Line line = ((Line) geometry);
+                return line.getVertex(0);
+            } else if (geometry instanceof MultiLine) {
+                MultiLine multiLine = (MultiLine) geometry;
+                Line firstLine = ((Line) multiLine.getPrimitiveAt(0));
+                return firstLine.getVertex(0);
+            }
+            return null;
+        }
+
+        protected Point getFinalPoint() {
+            if (geometry instanceof Line) {
+                Line line = ((Line) geometry);
+                return line.getVertex(line.getNumVertices() - 1);
+            } else if (geometry instanceof MultiLine) {
+                MultiLine multiLine = (MultiLine) geometry;
+                Line lastLine = ((Line) multiLine.getPrimitiveAt(multiLine.getPrimitivesNumber() - 1));
+                return lastLine.getVertex(lastLine.getNumVertices() - 1);
+            }
+            return null;
+        }
+
+        protected void flip() throws GeometryOperationNotSupportedException, GeometryOperationException {
+            geometry.flip();
+        }
+
+        /**
+         * @param point
+         * @param mList
+         * @return
+         */
+        protected List<MSegment> searchNextSegments(Point point, List<MSegment> mList) {
+            List<MSegment> result = new ArrayList<LrsCreateRouteAlgorithm.MSegment>();
+            for (Iterator<MSegment> iterator = mList.iterator(); iterator.hasNext();) {
+                MSegment mSegment = (MSegment) iterator.next();
+                if (mSegment != this) { // !addedSegments.contains(mSegment)) {
+                    Geometry geom = mSegment.geometry;
+                    if (geom instanceof Line) {
+                        Line line = ((Line) geom);
+                        if (line.getVertex(0).equals(point) || line.getVertex(line.getNumVertices() - 1).equals(point)) {
+                            result.add(mSegment);
+                        }
+                        ;
+                    } else if (geom instanceof MultiLine) {
+                        MultiLine multiLine = (MultiLine) geom;
+                        Line firstLine = ((Line) multiLine.getPrimitiveAt(0));
+                        Line lastLine = ((Line) multiLine.getPrimitiveAt(multiLine.getPrimitivesNumber() - 1));
+                        if (firstLine.getVertex(0).equals(point)
+                            || lastLine.getVertex(lastLine.getNumVertices() - 1).equals(point)) {
+                            result.add(mSegment);
+                        }
+                    }
+                }
+            }
+            return result;
+        }
+
+        public double getLength(boolean ignoreSpatialGaps) throws GeometryOperationNotSupportedException,
+            GeometryOperationException {
+            return LrsAlgorithmUtils.getGeometryLength(geometry, ignoreSpatialGaps);
+        }
+    }
+
+    private class Stretch {
+
+        private List<MSegment> segments;
+        private Point initialPoint;
+        private Point finalPoint;
+
+        public Stretch() {
+            segments = new ArrayList<MSegment>();
+        }
+
+        public MSegment getSegment(int index) {
+            return segments.get(index);
+        }
+
+        public int getSegmentNumber() {
+            return segments.size();
+        }
+
+        public void addSegment(MSegment segment) {
+            if (segments.isEmpty()) {
+                initialPoint = segment.getInitialPoint();
+            }
+            finalPoint = segment.getFinalPoint();
+            segments.add(segment);
+        }
+
+        public void addSegment(int index, MSegment segment) {
+            if (index == 0) {
+                initialPoint = segment.getInitialPoint();
+            }
+            if (index >= segments.size()) {
+                finalPoint = segment.getFinalPoint();
+            }
+            segments.add(index, segment);
+        }
+
+        public double getLength(boolean ignoreSpatialGaps) throws GeometryOperationNotSupportedException,
+            GeometryOperationException {
+            double result = 0.0;
+            for (MSegment segment : segments) {
+                result += segment.getLength(ignoreSpatialGaps);
+            }
+            return result;
+        }
+
+        public Stretch flip() throws GeometryOperationNotSupportedException, GeometryOperationException {
+            Collections.reverse(segments);
+            for (Iterator<MSegment> iterator = segments.iterator(); iterator.hasNext();) {
+                MSegment segment = (MSegment) iterator.next();
+                segment.flip();
+            }
+            Point aux = initialPoint;
+            initialPoint = finalPoint;
+            finalPoint = aux;
+            return this;
+        }
+
+        public Point getInitialPoint() {
+            return initialPoint;
+        }
+
+        public Point getFinalPoint() {
+            return finalPoint;
+        }
+
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultLrsEditRouteCalibrationAlgorithmParams.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultLrsEditRouteCalibrationAlgorithmParams.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultLrsEditRouteCalibrationAlgorithmParams.java	(revision 950)
@@ -0,0 +1,106 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.lib.impl;
+
+import java.util.List;
+import java.util.Map;
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureReference;
+import org.gvsig.lrs.lib.api.LrsEditRouteCalibrationAlgorithmParams;
+
+
+
+/**
+ * @author dmartinez
+ *
+ */
+public class DefaultLrsEditRouteCalibrationAlgorithmParams implements LrsEditRouteCalibrationAlgorithmParams {
+
+
+    private FeatureAttributeDescriptor idRouteField;
+    private String selectedRouteName;
+    private final String NAME = "LrsEditRouteCalibrationAlgorithm";
+    private final String DESCRIPTION = "Algorithm to edit route calibration with linear reference system.";
+    private Map<FeatureReference, List<Double>> modifiedMCoordinates;
+
+
+    /**
+     *
+     */
+    public DefaultLrsEditRouteCalibrationAlgorithmParams() {
+
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithmParams#getName()
+     */
+    @Override
+    public String getName() {
+        return NAME;
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithmParams#getDescription()
+     */
+    @Override
+    public String getDescription() {
+        return DESCRIPTION;
+    }
+
+
+    @Override
+    public FeatureAttributeDescriptor getIdRouteField() {
+        return idRouteField;
+    }
+
+
+    @Override
+    public void setIdRouteField(FeatureAttributeDescriptor idRouteField) {
+        this.idRouteField = idRouteField;
+    }
+
+
+    @Override
+    public String getSelectedRouteName() {
+        return selectedRouteName;
+    }
+
+
+    @Override
+    public void setSelectedRouteName(String selectedRouteName) {
+        this.selectedRouteName = selectedRouteName;
+    }
+
+
+    @Override
+    public Map<FeatureReference, List<Double>> getModifiedMCoordinates() {
+        return this.modifiedMCoordinates;
+    }
+
+    @Override
+    public void setModifiedMCoordinates(Map<FeatureReference, List<Double>> modifiedMCoordinates) {
+        this.modifiedMCoordinates = modifiedMCoordinates;
+    }
+
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/LrsCalibrateRouteAlgorithm.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/LrsCalibrateRouteAlgorithm.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/LrsCalibrateRouteAlgorithm.java	(revision 950)
@@ -0,0 +1,345 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.lib.impl;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.Map.Entry;
+
+import org.cresques.cts.IProjection;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import org.gvsig.fmap.dal.feature.EditableFeature;
+import org.gvsig.fmap.dal.feature.Feature;
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureSet;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.feature.NewFeatureStoreParameters;
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.geom.GeometryLocator;
+import org.gvsig.fmap.geom.GeometryManager;
+import org.gvsig.fmap.geom.exception.CreateGeometryException;
+import org.gvsig.fmap.geom.operation.GeometryOperationException;
+import org.gvsig.fmap.geom.operation.GeometryOperationNotSupportedException;
+import org.gvsig.fmap.geom.primitive.Line;
+import org.gvsig.fmap.geom.primitive.Point;
+import org.gvsig.lrs.lib.api.DistanceUnits;
+import org.gvsig.lrs.lib.api.LrsAlgorithm;
+import org.gvsig.lrs.lib.api.LrsAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsCalibrateRouteAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsMeasureCalculationMethods;
+import org.gvsig.lrs.lib.api.MeasuresCalculator;
+import org.gvsig.lrs.lib.api.exceptions.LrsCalibrateRouteException;
+import org.gvsig.lrs.lib.api.exceptions.LrsException;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.exception.BaseException;
+import org.gvsig.tools.i18n.I18nManager;
+import org.gvsig.tools.service.Manager;
+import org.gvsig.tools.task.SimpleTaskStatus;
+import org.gvsig.tools.visitor.VisitCanceledException;
+import org.gvsig.tools.visitor.Visitor;
+
+/**
+ * @author dmartinez
+ *
+ */
+public class LrsCalibrateRouteAlgorithm implements LrsAlgorithm {
+
+    private static final Logger logger = LoggerFactory.getLogger(LrsCalibrateRouteAlgorithm.class);
+
+    private LrsCalibrateRouteAlgorithmParams parameters;
+
+    /**
+     *
+     */
+    public LrsCalibrateRouteAlgorithm(LrsCalibrateRouteAlgorithmParams parameters) {
+        this.parameters = parameters;
+
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see org.gvsig.tools.service.Service#getManager()
+     */
+    public Manager getManager() {
+        return null;
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithm#getParams()
+     */
+    public  LrsAlgorithmParams getParams() {
+        return this.parameters;
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithm#setParams(org.gvsig.lrs.lib.api.LrsAlgorithmParams)
+     */
+    public void setParams(LrsAlgorithmParams params) throws IllegalArgumentException {
+        if(!(params instanceof LrsCreateRouteAlgorithmParams)){
+            throw new IllegalArgumentException("params should be LrsCalibrateRouteAlgorithmParams type.");
+        }
+        this.parameters = (LrsCalibrateRouteAlgorithmParams) params;
+    }
+
+    /*
+     * (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithm#execute(org.gvsig.tools.task.SimpleTaskStatus)
+     */
+    public void execute(final SimpleTaskStatus taskStatus) throws LrsException {
+        NewFeatureStoreParameters newFeatureStoreParameters =
+            parameters.getNewFeatureStoreParameters();
+        FeatureStore sourceFeatureStore = parameters.getSourceFeatureStore();
+        FeatureAttributeDescriptor idRouteField = parameters.getIdRouteField();
+        FeatureStore calibratePointFeatureStore= parameters.getCalibratePointFeatureStore();
+        FeatureAttributeDescriptor idRouteCalibratePointField =parameters.getCalibratePointIdRouteField();
+        FeatureAttributeDescriptor fromMeasureField = parameters.getFromMeasureField();
+        final boolean includeAll=parameters.includeAll();
+
+        logger.info(parameters.toString());
+
+        taskStatus.setTitle(parameters.getName());
+        I18nManager i18nManager = ToolsLocator.getI18nManager();
+        taskStatus.message(i18nManager.getTranslation("grouping_features"));
+
+        try {
+            final String routeFieldName = idRouteField.getName();
+            final String routeCalibratePointFieldName=idRouteCalibratePointField.getName();
+            final String measureFieldName=fromMeasureField.getName();
+            final Double convertedSearchRadius=calculateConvertedSearchRadius();
+
+            FeatureStore newFeatureStore = LrsAlgorithmUtils
+                .createNewDataStore(newFeatureStoreParameters, idRouteField);
+
+            FeatureSet sourceFeatures;
+            if (sourceFeatureStore.getFeatureSelection().getSize() > 0) {
+                sourceFeatures = sourceFeatureStore.getFeatureSelection();
+            } else {
+                sourceFeatures = sourceFeatureStore.getFeatureSet();
+            }
+
+            final Map<String, RouteAndPoints> featuresMap =
+                new HashMap<String, RouteAndPoints>();
+            sourceFeatures.accept(new Visitor() {
+
+                public void visit(Object obj)
+                    throws VisitCanceledException, BaseException {
+                    Feature feature = (Feature) obj;
+                    String routeName = (String) feature.get(routeFieldName);
+                    RouteAndPoints routeAndPoints = new RouteAndPoints(feature.getDefaultGeometry());
+
+                    featuresMap.put(routeName, routeAndPoints);
+                }
+            });
+
+            FeatureSet pointFeatures=calibratePointFeatureStore.getFeatureSet();
+            pointFeatures.accept(new Visitor() {
+
+                public void visit(Object obj) throws VisitCanceledException, BaseException {
+                    Feature feature = (Feature) obj;
+                    String routeName = (String) feature.get(routeCalibratePointFieldName);
+                    Double measure= (Double) feature.get(measureFieldName);
+                    Geometry geomPoint=(Point)feature.getDefaultGeometry();
+
+                    if (geomPoint instanceof Point){
+                        Point point=(Point) geomPoint;
+                        Object valueObject=featuresMap.get(routeName);
+                        if (valueObject != null && valueObject instanceof RouteAndPoints) {
+                            RouteAndPoints routeAndPoints = (RouteAndPoints) valueObject;
+                            List<Point> points = routeAndPoints.getPoints();
+                            if (feature.getDefaultGeometry() instanceof Point) {
+                                Geometry route = routeAndPoints.getRoute();
+                                if (isValidPoint(point, route, convertedSearchRadius)) {
+                                    try {
+                                        Point mPoint = getInRouteMPoint(route, point, measure);
+                                        points.add(mPoint);
+                                    } catch (Exception e) {
+                                        logger.debug("Error adding point", e);
+                                    }
+                                }
+                            }
+                        }
+                    }
+                }
+            });
+
+            taskStatus.setRangeOfValues(0, featuresMap.size());
+            int taskCount = 0;
+
+            newFeatureStore.edit(FeatureStore.MODE_FULLEDIT);
+
+            for (Entry<String, RouteAndPoints> entry : featuresMap.entrySet()) {
+                String routeName = entry.getKey();
+                Object valueObject = entry.getValue();
+                List<Point> points=null;
+                Geometry geometry=null;
+
+                if (valueObject!=null && valueObject instanceof RouteAndPoints){
+                    RouteAndPoints routeAndPoints=(RouteAndPoints)valueObject;
+                        geometry=routeAndPoints.getRoute();
+                        points=routeAndPoints.getPoints();
+                }
+                if (!points.isEmpty()){
+                    EditableFeature newFeature =
+                        newFeatureStore.createNewFeature(true);
+                    newFeature.set(routeFieldName, routeName);
+                    Geometry calibratedRoute = calibrateRoute(geometry,points);
+                    newFeature.setDefaultGeometry(calibratedRoute);
+                    newFeatureStore.update(newFeature);
+                } else if (includeAll) {
+                    EditableFeature newFeature = newFeatureStore.createNewFeature(true);
+                    newFeature.set(routeFieldName, routeName);
+                    newFeature.setDefaultGeometry(geometry);
+                    newFeatureStore.update(newFeature);
+                }
+                taskCount++;
+                taskStatus.setCurValue(taskCount);
+            }
+            newFeatureStore.finishEditing();
+        } catch (Exception e1) {
+            taskStatus.abort();
+            throw new LrsCalibrateRouteException("Error calibrating routes", e1);
+        }
+
+        taskStatus.terminate();
+    }
+
+
+    private Point getInRouteMPoint(Geometry geometry,Point point, Double measure) throws CreateGeometryException, GeometryOperationNotSupportedException, GeometryOperationException{
+        GeometryManager geomanager = GeometryLocator.getGeometryManager();
+
+        Point[] pointsInLine=(Point[])geometry.closestPoints(point);
+        Point pointInLine=pointsInLine[0];
+
+        Point mPoint = (Point) geomanager
+            .create(Geometry.TYPES.POINT, Geometry.SUBTYPES.GEOM2DM);
+        mPoint.setX(pointInLine.getX());
+        mPoint.setY(pointInLine.getY());
+        int mDimension=mPoint.getDimension()-1;
+        mPoint.setCoordinateAt(mDimension, measure);
+
+        return mPoint;
+    }
+
+    private Double calculateConvertedSearchRadius(){
+        Double searchRadius=parameters.getSearchRadius();
+        DistanceUnits measureUnits = parameters.getMeasureUnits();
+        FeatureStore sourceFeatureStore = parameters.getSourceFeatureStore();
+
+        try {
+            IProjection projection = sourceFeatureStore.getDefaultFeatureType().getDefaultSRS();
+
+            Double searchRadiusInMeters=searchRadius*measureUnits.getTransToMeter();
+            //TODO
+            //DistanceUnits projectionDistanceUnits=getProjectionDistanceUnits(projection);
+            //return searchRadiusInMeters/projectionDistanceUnits.getTransToMeter();
+            return searchRadiusInMeters;
+        } catch (Exception e) {
+            return new Double(0);
+        }
+    }
+
+    private boolean isValidPoint(Point point,Geometry geometry, Double convertedSearchRadius){
+        try {
+            return geometry.isWithinDistance(point, convertedSearchRadius);
+        } catch (Exception e) {
+            return false;
+        }
+    }
+
+    private Geometry calibrateRoute(Geometry geometry, List<Point> points) {
+        LrsMeasureCalculationMethods calculationMethod= parameters.getMeasureCalculationMethods();
+        boolean ignoreSpatialGaps = parameters.ignoreSpatialGaps();
+        boolean interpolateBetweenCalibrationPoints=parameters.interpolateBetweenCalibrationPoints();
+        boolean extrapolateBeforeCalibrationPoints=parameters.extrapolateBeforeCalibrationPoints();
+        boolean extrapolateAfterCalibrationPoints=parameters.extrapolateAfterCalibrationPoints();
+
+        if (points.isEmpty()){
+            return geometry;
+        }
+        MeasuresCalculator expandedRoute=new DefaultMeasuresCalculator(geometry, ignoreSpatialGaps);
+
+
+        expandedRoute.addControlPoints(points);
+        expandedRoute.calculate(calculationMethod,extrapolateBeforeCalibrationPoints,interpolateBetweenCalibrationPoints,extrapolateAfterCalibrationPoints);
+        return expandedRoute.getResult();
+    }
+
+    private class RouteAndPoints {
+        private Geometry route;
+        private List<Point> points;
+
+
+        /**
+         *
+         */
+        public RouteAndPoints(Geometry route) {
+            this.setRoute(route);
+            this.setPoints(new ArrayList<Point>());
+        }
+
+
+        /**
+         * @return the route
+         */
+        public Geometry getRoute() {
+            return route;
+        }
+
+
+        /**
+         * @param route the route to set
+         */
+        public void setRoute(Geometry route) {
+            this.route = route;
+        }
+
+
+        /**
+         * @return the points
+         */
+        public List<Point> getPoints() {
+            return points;
+        }
+
+
+        /**
+         * @param points the points to set
+         */
+        public void setPoints(List<Point> points) {
+            this.points = points;
+        }
+
+    }
+}
+
+
+
+
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultLrsGenerateDynamicSegmentationAlgorithmParams.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultLrsGenerateDynamicSegmentationAlgorithmParams.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/DefaultLrsGenerateDynamicSegmentationAlgorithmParams.java	(revision 950)
@@ -0,0 +1,159 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.lib.impl;
+
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.feature.NewFeatureStoreParameters;
+import org.gvsig.lrs.lib.api.DistanceUnits;
+import org.gvsig.lrs.lib.api.LrsCalibrateRouteAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsGenerateDynamicSegmentationAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsMeasureCalculationMethods;
+
+
+/**
+ * @author dmartinez
+ *
+ */
+public class DefaultLrsGenerateDynamicSegmentationAlgorithmParams implements LrsGenerateDynamicSegmentationAlgorithmParams {
+
+    private FeatureStore sourceFeatureStore;
+    private FeatureAttributeDescriptor idRouteField;
+    private NewFeatureStoreParameters newFeatureStoreParameters;
+    private FeatureStore valueTableFeatureStore;
+    private FeatureAttributeDescriptor valueTableIdRouteField;
+    private FeatureAttributeDescriptor landmarkField;
+    private FeatureAttributeDescriptor finalLandmarkField;
+    private FeatureAttributeDescriptor valueField;
+    private final String NAME = "LrsCalibrateRouteAlgorithm";
+    private final String DESCRIPTION = "Algorithm to calibrate routes with linear reference system.";
+
+
+
+    /**
+     *
+     */
+    public DefaultLrsGenerateDynamicSegmentationAlgorithmParams() {
+
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithmParams#getName()
+     */
+    public String getName() {
+        return NAME;
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.lib.api.LrsAlgorithmParams#getDescription()
+     */
+    public String getDescription() {
+        return DESCRIPTION;
+    }
+
+
+    public FeatureStore getSourceFeatureStore() {
+        return sourceFeatureStore;
+    }
+
+
+    public void setSourceFeatureStore(FeatureStore sourceFeatureStore) {
+        this.sourceFeatureStore = sourceFeatureStore;
+    }
+
+
+    public FeatureAttributeDescriptor getIdRouteField() {
+        return idRouteField;
+    }
+
+
+    public void setIdRouteField(FeatureAttributeDescriptor idRouteField) {
+        this.idRouteField = idRouteField;
+    }
+
+
+    public NewFeatureStoreParameters getNewFeatureStoreParameters() {
+        return newFeatureStoreParameters;
+    }
+
+
+    public void setNewFeatureStoreParameters(
+        NewFeatureStoreParameters newFeatureStoreParameters) {
+        this.newFeatureStoreParameters = newFeatureStoreParameters;
+    }
+
+
+    public FeatureStore getValueTableFeatureStore() {
+        return valueTableFeatureStore;
+    }
+
+
+    public void setValueTableFeatureStore(FeatureStore valueTableFeatureStore) {
+        this.valueTableFeatureStore = valueTableFeatureStore;
+    }
+
+
+    public FeatureAttributeDescriptor getValueTableIdRouteField() {
+        return valueTableIdRouteField;
+    }
+
+
+    public void setValueTableIdRouteField(
+        FeatureAttributeDescriptor valueTableIdRouteField) {
+        this.valueTableIdRouteField = valueTableIdRouteField;
+    }
+
+
+    public FeatureAttributeDescriptor getLandmarkField() {
+        return landmarkField;
+    }
+
+
+    public void setLandmarkField(FeatureAttributeDescriptor landmarkField) {
+        this.landmarkField = landmarkField;
+    }
+
+
+    public FeatureAttributeDescriptor getFinalLandmarkField() {
+        return finalLandmarkField;
+    }
+
+
+    public void setFinalLandmarkField(
+        FeatureAttributeDescriptor finalLandmarkField) {
+        this.finalLandmarkField = finalLandmarkField;
+    }
+
+
+    public FeatureAttributeDescriptor getValueField() {
+        return valueField;
+    }
+
+
+    public void setValueField(FeatureAttributeDescriptor valueField) {
+        this.valueField = valueField;
+    }
+
+
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/expressionevaluator/function/lrs/LRSPointFromGeometryFunction.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/expressionevaluator/function/lrs/LRSPointFromGeometryFunction.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/expressionevaluator/function/lrs/LRSPointFromGeometryFunction.java	(revision 950)
@@ -0,0 +1,54 @@
+package org.gvsig.lrs.lib.impl.expressionevaluator.function.lrs;
+
+import org.apache.commons.lang3.Range;
+import org.gvsig.expressionevaluator.Interpreter;
+import org.gvsig.expressionevaluator.spi.AbstractGeometryFunction;
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.geom.primitive.Point;
+import org.gvsig.lrs.lib.api.LrsAlgorithmsLocator;
+import org.gvsig.lrs.lib.api.LrsAlgorithmsManager;
+import org.gvsig.lrs.lib.impl.expressionevaluator.symboltable.LRSSymbolTable;
+
+public class LRSPointFromGeometryFunction extends AbstractGeometryFunction {
+
+    public static final String FUNCTION_LRSPOINTFROMGEOMETRY = "LRSPointFromGeometry";
+    
+    public LRSPointFromGeometryFunction() {
+        super(
+                LRSSymbolTable.GROUP_LRS, 
+                FUNCTION_LRSPOINTFROMGEOMETRY, 
+                Range.is(2),
+                "Returns ?????? TODO.\n",
+                FUNCTION_LRSPOINTFROMGEOMETRY+"( {{geom}}, point_or_distance)",
+                new String[]{
+                    "geom - TODO.",
+                    "point_or_distance - TODO",
+                },
+                "Point",
+                false
+        );
+    }
+
+    @Override
+    public boolean allowConstantFolding() {
+        return true;
+    }
+    
+    @Override
+    public Object call(Interpreter interpreter, Object[] args) throws Exception {
+        Geometry geom = this.getGeom(args, 0);
+        Object v2 = this.getObject(args, 1);
+
+        LrsAlgorithmsManager manager = LrsAlgorithmsLocator.getLrsAlgorithmsManager();
+        Point r = null;
+        if( v2 instanceof Number ) {
+            double distance = this.getDouble(args, 1);
+            r = manager.getMPointFromGeometry(geom, distance);
+        } else {
+            Point point =this.getPoint(args, 1);
+            r = manager.getMPointFromGeometry(geom, point);
+        }
+        return r;
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/expressionevaluator/function/lrs/STLineInterpolatePointFunction.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/expressionevaluator/function/lrs/STLineInterpolatePointFunction.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/expressionevaluator/function/lrs/STLineInterpolatePointFunction.java	(revision 950)
@@ -0,0 +1,59 @@
+package org.gvsig.lrs.lib.impl.expressionevaluator.function.lrs;
+
+import org.apache.commons.lang3.Range;
+import org.gvsig.expressionevaluator.Interpreter;
+import org.gvsig.expressionevaluator.spi.AbstractGeometryFunction;
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.geom.aggregate.MultiLine;
+import org.gvsig.fmap.geom.primitive.Line;
+import org.gvsig.fmap.geom.primitive.Point;
+import org.gvsig.lrs.lib.impl.expressionevaluator.symboltable.LRSSymbolTable;
+
+public class STLineInterpolatePointFunction extends AbstractGeometryFunction {
+
+    public static final String FUNCTION_ST_LINEINTERPOLATEPOINT = "ST_LineInterpolatePoint";
+    
+    public STLineInterpolatePointFunction() {
+        super(
+                LRSSymbolTable.GROUP_LRS,
+                FUNCTION_ST_LINEINTERPOLATEPOINT,
+                Range.is(2),
+                "Returns a point interpolated along a line at a fractional location. First argument must be a LINESTRING. Second argument is a float between 0 and 1 representing the fraction of line length where the point is to be located. The Z and M values are interpolated if present.\n" +
+                "See ST_LineLocatePoint for computing the line location nearest to a Point.",
+                FUNCTION_ST_LINEINTERPOLATEPOINT + "( {{ a_linestring}},  a_fraction)",
+                new String[]{
+                    " a_linestring - a LineString with M coordinate.",
+                    " a_fraction - the fractional location",},
+                "Point",
+                false
+        );
+    }
+
+    @Override
+    public boolean allowConstantFolding() {
+        return true;
+    }
+    
+    @Override
+    public Object call(Interpreter interpreter, Object[] args) throws Exception {
+        Geometry geom = this.getGeom(args, 0);
+        double fraction = this.getDouble(args, 1);
+        
+        return lineInterpolatePoint(geom, fraction);
+    }
+    
+    public static Point lineInterpolatePoint(Geometry geom, double fraction) throws Exception{
+        double l = geom.perimeter();
+        Point point;
+        if (geom instanceof Line){
+            point = ((Line)geom).extractPoint(fraction*l);
+        } else if (geom instanceof MultiLine){
+            point = ((MultiLine)geom).extractPoint(fraction*l);
+        } else {
+            throw new IllegalArgumentException("Need Line or MultiLine geometry.");
+        }
+        
+        return point;
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/expressionevaluator/function/lrs/STLineLocatePointFunction.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/expressionevaluator/function/lrs/STLineLocatePointFunction.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/expressionevaluator/function/lrs/STLineLocatePointFunction.java	(revision 950)
@@ -0,0 +1,62 @@
+package org.gvsig.lrs.lib.impl.expressionevaluator.function.lrs;
+
+import org.apache.commons.lang3.Range;
+import org.gvsig.expressionevaluator.Interpreter;
+import org.gvsig.expressionevaluator.spi.AbstractGeometryFunction;
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.geom.aggregate.MultiLine;
+import org.gvsig.fmap.geom.primitive.Line;
+import org.gvsig.fmap.geom.primitive.Point;
+import org.gvsig.lrs.lib.impl.expressionevaluator.symboltable.LRSSymbolTable;
+
+public class STLineLocatePointFunction extends AbstractGeometryFunction {
+
+    public static final String FUNCTION_ST_LINELOCATEPOINT = "ST_LineLocatePoint";
+    
+    public STLineLocatePointFunction() {
+        super(
+                LRSSymbolTable.GROUP_LRS,
+                FUNCTION_ST_LINELOCATEPOINT,
+                Range.is(2),
+                "Returns a float between 0 and 1 representing the location of the closest point on a LineString to the given Point, as a fraction of 2d line length.\n"
+                + "You can use the returned location to extract a Point (ST_LineInterpolatePoint) or a substring (ST_LineSubstring).\n"
+                + "This is useful for approximating numbers of addresses\n",
+                FUNCTION_ST_LINELOCATEPOINT + "( {{ a_linestring}},  a_point)",
+                new String[]{
+                    " a_linestring - a LineString with M coordinate.",
+                    " a_point - a Point (with or without M coordinate) near of the LineString",},
+                "Double",
+                false
+        );
+    }
+
+    @Override
+    public boolean allowConstantFolding() {
+        return true;
+    }
+    
+    @Override
+    public Object call(Interpreter interpreter, Object[] args) throws Exception {
+        Geometry geom = this.getGeom(args, 0);
+        Point point =this.getPoint(args, 1);
+        
+        return lineLocatePoint(geom, point);
+    }
+    
+    public static double lineLocatePoint(Geometry geom, Point point) throws Exception{
+        double l = geom.perimeter();
+        double locatePoint;
+        if (geom instanceof Line){
+            locatePoint = ((Line)geom).getPathLength(point);
+        } else if (geom instanceof MultiLine){
+            locatePoint = ((MultiLine)geom).getPathLength(point);
+        } else {
+            throw new IllegalArgumentException("Need Line or MultiLine geometry.");
+        }
+        
+        double fraction = locatePoint / l;
+        
+        return fraction;
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/expressionevaluator/symboltable/LRSSymbolTable.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/expressionevaluator/symboltable/LRSSymbolTable.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/expressionevaluator/symboltable/LRSSymbolTable.java	(revision 950)
@@ -0,0 +1,25 @@
+package org.gvsig.lrs.lib.impl.expressionevaluator.symboltable;
+
+import org.gvsig.expressionevaluator.spi.AbstractSymbolTable;
+import org.gvsig.lrs.lib.impl.expressionevaluator.function.lrs.STLineInterpolatePointFunction;
+import org.gvsig.lrs.lib.impl.expressionevaluator.function.lrs.STLineLocatePointFunction;
+
+/**
+ *
+ * @author jjdelcerro
+ */
+public class LRSSymbolTable extends AbstractSymbolTable {
+    public static final String GROUP_LRS = "Linear reference system";
+    
+    static final String NAME = "Linear reference system";
+    
+    @SuppressWarnings("OverridableMethodCallInConstructor")
+    public LRSSymbolTable() {
+        super(NAME);
+
+//        this.addFunction(new LRSPointFromGeometryFunction());
+        this.addFunction(new STLineLocatePointFunction());
+        this.addFunction(new STLineInterpolatePointFunction());
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/expressionevaluator/symboltable/LRSSymbolTableFactory.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/expressionevaluator/symboltable/LRSSymbolTableFactory.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl/expressionevaluator/symboltable/LRSSymbolTableFactory.java	(revision 950)
@@ -0,0 +1,33 @@
+package org.gvsig.lrs.lib.impl.expressionevaluator.symboltable;
+
+import org.gvsig.expressionevaluator.ExpressionEvaluatorLocator;
+import org.gvsig.expressionevaluator.ExpressionEvaluatorManager;
+import org.gvsig.expressionevaluator.SymbolTable;
+import org.gvsig.expressionevaluator.spi.AbstractSymbolTableFactory;
+
+/**
+ *
+ * @author jjdelcerro
+ */
+public class LRSSymbolTableFactory extends AbstractSymbolTableFactory {
+
+    private SymbolTable symbolTable;
+    
+    public LRSSymbolTableFactory() {
+        super(LRSSymbolTable.NAME, true);
+    }
+    
+    @Override
+    public SymbolTable create(Object... args) {
+        if( this.symbolTable==null ) {
+            this.symbolTable = new LRSSymbolTable();
+        }
+        return this.symbolTable;
+    }
+    
+    public static final void selfRegister() {
+        ExpressionEvaluatorManager manager = ExpressionEvaluatorLocator.getManager();
+        
+        manager.registerSymbolTable(new LRSSymbolTableFactory());
+    }
+}

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib/impl
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs/lib
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig/lrs
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org/gvsig
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java/org
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main/java
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/main
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/test/resources
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath


Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/test/java/org/gvsig/lrs/lib/impl/TestLineInterpolatePoint.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/test/java/org/gvsig/lrs/lib/impl/TestLineInterpolatePoint.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/test/java/org/gvsig/lrs/lib/impl/TestLineInterpolatePoint.java	(revision 950)
@@ -0,0 +1,79 @@
+package org.gvsig.lrs.lib.impl;
+
+import junit.framework.TestCase;
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.geom.GeometryLocator;
+import org.gvsig.fmap.geom.GeometryManager;
+import org.gvsig.fmap.geom.primitive.Point;
+import org.gvsig.lrs.lib.impl.expressionevaluator.function.lrs.STLineInterpolatePointFunction;
+import org.gvsig.tools.library.impl.DefaultLibrariesInitializer;
+
+public class TestLineInterpolatePoint extends TestCase {
+    
+    public TestLineInterpolatePoint(String testName) {
+        super(testName);
+    }
+    
+    @Override
+    protected void setUp() throws Exception {
+        super.setUp();
+        new DefaultLibrariesInitializer().fullInitialize();
+    }
+    
+    @Override
+    protected void tearDown() throws Exception {
+        super.tearDown();
+    }
+
+    // TODO add test methods here. The name must begin with 'test'. For example:
+    // public void testHello() {}
+    
+    public void testLine1() throws Exception{
+        
+        GeometryManager manager = GeometryLocator.getGeometryManager();
+        Geometry line = manager.createFrom("LINESTRING (100 400, 400 400, 605 464, 800 460)");
+        
+        double fraction = 150/line.perimeter();
+        
+        Point point = STLineInterpolatePointFunction.lineInterpolatePoint(line, fraction);
+        
+        assertEquals("POINT (250 400)", point.convertToWKT());
+    }
+
+    public void testMultiLine1() throws Exception{
+        
+        GeometryManager manager = GeometryLocator.getGeometryManager();
+        Geometry line = manager.createFrom("MULTILINESTRING ((100 400, 400 400),  (400 500, 600 500),  (600 500, 800 460))");
+
+        double fraction = 400/line.perimeter();
+        
+        Point point = STLineInterpolatePointFunction.lineInterpolatePoint(line, fraction);
+        
+        assertEquals("POINT (500 500)", point.convertToWKT());
+    }
+    
+    public void testLineM1() throws Exception{
+        
+        GeometryManager manager = GeometryLocator.getGeometryManager();
+        Geometry line = manager.createFrom("LINESTRING M(100 400 0, 400 400 300, 605 464 505, 800 460 700)");
+        
+        double fraction = 150/line.perimeter();
+        
+        Point point = STLineInterpolatePointFunction.lineInterpolatePoint(line, fraction);
+        
+        assertEquals("POINT M (250 400 150)", point.convertToWKT());
+    }
+
+    public void testMultiLineM1() throws Exception{
+        
+        GeometryManager manager = GeometryLocator.getGeometryManager();
+        Geometry line = manager.createFrom("MULTILINESTRING M((100 400 0, 400 400 300),  (400 500 300, 600 500 500),  (600 500 500, 800 460 700))");
+
+        double fraction = 400/line.perimeter();
+        
+        Point point = STLineInterpolatePointFunction.lineInterpolatePoint(line, fraction);
+        
+        assertEquals("POINT M (500 500 400)", point.convertToWKT());
+    }
+    
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/test/java/org/gvsig/lrs/lib/impl/TestLineLocatePoint.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/test/java/org/gvsig/lrs/lib/impl/TestLineLocatePoint.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/test/java/org/gvsig/lrs/lib/impl/TestLineLocatePoint.java	(revision 950)
@@ -0,0 +1,55 @@
+package org.gvsig.lrs.lib.impl;
+
+import junit.framework.TestCase;
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.geom.GeometryLocator;
+import org.gvsig.fmap.geom.GeometryManager;
+import org.gvsig.fmap.geom.aggregate.MultiLine;
+import org.gvsig.fmap.geom.primitive.Line;
+import org.gvsig.fmap.geom.primitive.Point;
+import org.gvsig.lrs.lib.impl.expressionevaluator.function.lrs.STLineLocatePointFunction;
+import org.gvsig.tools.library.impl.DefaultLibrariesInitializer;
+
+public class TestLineLocatePoint extends TestCase {
+    
+    public TestLineLocatePoint(String testName) {
+        super(testName);
+    }
+    
+    @Override
+    protected void setUp() throws Exception {
+        super.setUp();
+        new DefaultLibrariesInitializer().fullInitialize();
+    }
+    
+    @Override
+    protected void tearDown() throws Exception {
+        super.tearDown();
+    }
+
+    // TODO add test methods here. The name must begin with 'test'. For example:
+    // public void testHello() {}
+    
+    public void testLine1() throws Exception{
+        
+        GeometryManager manager = GeometryLocator.getGeometryManager();
+        Geometry line = manager.createFrom("LINESTRING (100 400, 400 400, 605 464, 800 460)");
+        
+        Geometry point = manager.createFrom("POINT (250 350)");
+        
+        double location = STLineLocatePointFunction.lineLocatePoint((Line)line, (Point)point);
+        assertEquals(150/line.perimeter(), location);
+    }
+
+    public void testMultiLine1() throws Exception{
+        
+        GeometryManager manager = GeometryLocator.getGeometryManager();
+        Geometry line = manager.createFrom("MULTILINESTRING ((100 400, 400 400),  (400 500, 600 500),  (600 500, 800 460))");
+        
+        Geometry point = manager.createFrom("POINT (500 450)");
+        
+        double location = STLineLocatePointFunction.lineLocatePoint((MultiLine)line, (Point)point);
+        assertEquals(400/line.perimeter(), location);
+    }
+    
+}

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/test/java
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src/test
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/src
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath


Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/pom.xml
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/pom.xml	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl/pom.xml	(revision 950)
@@ -0,0 +1,46 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+  <parent>
+    <groupId>org.gvsig</groupId>
+    <artifactId>org.gvsig.lrs.lib</artifactId>
+    <version>1.0.173</version>
+  </parent>
+  <artifactId>org.gvsig.lrs.lib.impl</artifactId>
+  <name>${project.artifactId}</name>
+  <dependencies>
+    <dependency>
+      <groupId>org.gvsig</groupId>
+      <artifactId>org.gvsig.lrs.lib.api</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.gvsig</groupId>
+      <artifactId>org.gvsig.fmap.dal.api</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.gvsig</groupId>
+      <artifactId>org.gvsig.fmap.dal.file.lib</artifactId>
+        <scope>compile</scope>
+    </dependency>
+    <dependency>
+        <groupId>org.gvsig</groupId>
+        <artifactId>org.gvsig.fmap.dal.spi</artifactId>
+        <scope>test</scope>
+    </dependency>
+    <dependency>
+        <groupId>org.gvsig</groupId>
+        <artifactId>org.gvsig.fmap.dal.impl</artifactId>
+        <scope>test</scope>
+    </dependency>
+    <dependency>
+        <groupId>org.gvsig</groupId>
+        <artifactId>${org.gvsig.fmap.geometry.impl}</artifactId>
+        <scope>test</scope>
+    </dependency>
+    <dependency>
+        <groupId>org.gvsig</groupId>
+        <artifactId>org.gvsig.tools.lib</artifactId>
+        <scope>test</scope>
+        <type>test-jar</type>
+    </dependency>
+  </dependencies>
+</project>

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.impl
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath
target

.project


Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/pom.xml
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/pom.xml	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/pom.xml	(revision 950)
@@ -0,0 +1,14 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+  <parent>
+    <groupId>org.gvsig</groupId>
+    <artifactId>org.gvsig.lrs</artifactId>
+    <version>1.0.173</version>
+  </parent>
+  <artifactId>org.gvsig.lrs.lib</artifactId>
+  <packaging>pom</packaging>
+  <modules>
+    <module>org.gvsig.lrs.lib.api</module>
+    <module>org.gvsig.lrs.lib.impl</module>
+  </modules>
+</project>
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/resources/META-INF/services/org.gvsig.tools.library.Library
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/resources/META-INF/services/org.gvsig.tools.library.Library	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/resources/META-INF/services/org.gvsig.tools.library.Library	(revision 950)
@@ -0,0 +1 @@
+org.gvsig.lrs.lib.api.LrsAlgorithmsLibrary
\ No newline at end of file

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/resources/META-INF/services
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/resources/META-INF
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/resources
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath


Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsCoordinatesPriority.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsCoordinatesPriority.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsCoordinatesPriority.java	(revision 950)
@@ -0,0 +1,57 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.lib.api;
+
+import org.gvsig.tools.ToolsLocator;
+
+
+/**
+ * @author fdiaz
+ *
+ */
+public enum LrsCoordinatesPriority {
+    UP_LEFT("up_left",0),
+    DOWN_LEFT("down_left",1),
+    UP_RIGHT("up_right",2),
+    DOWN_RIGHT("down_right",3);
+
+    private final String name;
+    private final int value;
+
+    LrsCoordinatesPriority(String name, int value){
+        this.name = name;
+        this.value = value;
+    }
+
+    public String getName(){
+        return this.name;
+    }
+
+    public int getValue(){
+        return this.value;
+    }
+
+    public String toString(){
+        return ToolsLocator.getI18nManager().getTranslation(name);
+    }
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/MeasuresCalculator.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/MeasuresCalculator.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/MeasuresCalculator.java	(revision 950)
@@ -0,0 +1,23 @@
+
+package org.gvsig.lrs.lib.api;
+
+import java.util.List;
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.geom.primitive.Point;
+
+
+public interface MeasuresCalculator {
+
+    public void addControlPoints(List<Point> fixedPoints);
+
+    public void calculate();
+    public void calculate(LrsMeasureCalculationMethods calculationMethod, boolean before, boolean between, boolean after);
+
+    public Geometry getResult();
+
+    public void setMeasuresToDistances();
+
+    public void setFirstMeasure(double mvalue);
+    public void setLastMeasure(double mvalue);
+	
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/exceptions/LrsCreateRouteException.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/exceptions/LrsCreateRouteException.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/exceptions/LrsCreateRouteException.java	(revision 950)
@@ -0,0 +1,47 @@
+/**
+ * gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2014 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+
+package org.gvsig.lrs.lib.api.exceptions;
+
+public class LrsCreateRouteException extends LrsException {
+
+    /**
+     *
+     */
+    private static final long serialVersionUID = -7593469257155358436L;
+
+    private static final String MESSAGE =
+        "Error creating routes.";
+
+    private static final String KEY = "_LrsCreateRouteException";
+
+    public LrsCreateRouteException(Throwable ex) {
+        super(MESSAGE, ex, KEY, serialVersionUID);
+    }
+
+    public LrsCreateRouteException(String message, Throwable ex) {
+        super(message, ex, KEY, serialVersionUID);
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/exceptions/LrsCalibrateRouteException.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/exceptions/LrsCalibrateRouteException.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/exceptions/LrsCalibrateRouteException.java	(revision 950)
@@ -0,0 +1,47 @@
+/**
+ * gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2014 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+
+package org.gvsig.lrs.lib.api.exceptions;
+
+public class LrsCalibrateRouteException extends LrsException {
+
+    /**
+     *
+     */
+    private static final long serialVersionUID = -7593469257155358436L;
+
+    private static final String MESSAGE =
+        "Error calibrating routes.";
+
+    private static final String KEY = "_LrsCalibrateRouteException";
+
+    public LrsCalibrateRouteException(Throwable ex) {
+        super(MESSAGE, ex, KEY, serialVersionUID);
+    }
+
+    public LrsCalibrateRouteException(String message, Throwable ex) {
+        super(message, ex, KEY, serialVersionUID);
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/exceptions/LrsGettingParametersException.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/exceptions/LrsGettingParametersException.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/exceptions/LrsGettingParametersException.java	(revision 950)
@@ -0,0 +1,48 @@
+/**
+ * gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2014 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+
+package org.gvsig.lrs.lib.api.exceptions;
+
+public class LrsGettingParametersException extends LrsException {
+
+
+    /**
+     *
+     */
+    private static final long serialVersionUID = 8201868527295813900L;
+
+    private static final String MESSAGE =
+        "An error has been produced getting algorithm parameters.";
+
+    private static final String KEY = "_LrsGettingParametersException";
+
+    public LrsGettingParametersException(Throwable ex) {
+        super(MESSAGE, ex, KEY, serialVersionUID);
+    }
+
+    public LrsGettingParametersException(String message, Throwable ex) {
+        super(message, ex, KEY, serialVersionUID);
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/exceptions/LrsNeededParameterException.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/exceptions/LrsNeededParameterException.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/exceptions/LrsNeededParameterException.java	(revision 950)
@@ -0,0 +1,47 @@
+/**
+ * gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2014 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+
+package org.gvsig.lrs.lib.api.exceptions;
+
+public class LrsNeededParameterException extends LrsException {
+
+    /**
+     *
+     */
+    private static final long serialVersionUID = 3472690716035276175L;
+
+    private static final String MESSAGE =
+        "One or more of required parameters are empty.";
+
+    private static final String KEY = "_LrsNeededParameterException";
+
+    public LrsNeededParameterException(Throwable ex) {
+        super(MESSAGE, ex, KEY, serialVersionUID);
+    }
+
+    public LrsNeededParameterException(String message, Throwable ex) {
+        super(message, ex, KEY, serialVersionUID);
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/exceptions/LrsException.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/exceptions/LrsException.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/exceptions/LrsException.java	(revision 950)
@@ -0,0 +1,98 @@
+/**
+ * gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2014 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.lib.api.exceptions;
+
+
+import org.gvsig.tools.exception.BaseException;
+
+/**
+ *
+ * @author gvSIG team.
+ *
+ */
+public class LrsException extends BaseException {
+
+    /**
+     *
+     */
+    private static final long serialVersionUID = -1043709801185809443L;
+
+    private static final String MESSAGE =
+        "An error has been produced in the LRS library";
+
+    private static final String KEY = "_WasteException";
+
+    /**
+     * Constructor to be used in rare cases, usually you must create a new child
+     * exception class for each case.
+     * <strong>Don't use this constructor in child classes.</strong>
+     */
+    public LrsException() {
+        super(MESSAGE, KEY, serialVersionUID);
+    }
+
+    /**
+     * Constructor to be used in rare cases, usually you must create a new child
+     * exception class for each case.
+     * <p>
+     * <strong>Don't use this constructor in child classes.</strong>
+     * </p>
+     *
+     * @param cause
+     *            the original cause of the exception
+     */
+    public LrsException(Exception cause) {
+        super(MESSAGE, cause, KEY, serialVersionUID);
+    }
+
+    /**
+     * @see BaseException#BaseException(String, String, long).
+     * @param message
+     *            the default messageFormat to describe the exception
+     * @param key
+     *            the key to use to search a localized messageFormnata
+     * @param code
+     *            the unique code to identify the exception
+     */
+    protected LrsException(String message, String key, long code) {
+        super(message, key, code);
+    }
+
+    /**
+     * @see BaseException#BaseException(String, Throwable, String, long).
+     * @param message
+     *            the default messageFormat to describe the exception
+     * @param cause
+     *            the original cause of the exception
+     * @param key
+     *            the key to use to search a localized messageFormnata
+     * @param code
+     *            the unique code to identify the exception
+     */
+    protected LrsException(String message, Throwable cause,
+        String key, long code) {
+        super(message, cause, key, code);
+    }
+
+}

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/exceptions
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath


Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsCalibrateRouteAlgorithmParams.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsCalibrateRouteAlgorithmParams.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsCalibrateRouteAlgorithmParams.java	(revision 950)
@@ -0,0 +1,187 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.lib.api;
+
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.feature.NewFeatureStoreParameters;
+
+/**
+ * @author dmartinez
+ *
+ */
+public interface LrsCalibrateRouteAlgorithmParams extends LrsAlgorithmParams {
+    /**
+     * @return the sourceFeatureStore
+     */
+    public FeatureStore getSourceFeatureStore();
+
+
+    /**
+     * @param sourceFeatureStore the sourceFeatureStore to set
+     */
+    public void setSourceFeatureStore(FeatureStore sourceFeatureStore);
+
+
+    /**
+     * @return the idRouteField
+     */
+    public FeatureAttributeDescriptor getIdRouteField();
+
+    /**
+     * @param idRouteField the idRouteField to set
+     */
+    public void setIdRouteField(FeatureAttributeDescriptor idRouteField);
+
+
+    /**
+     * @return the calibratePointFeatureStore
+     */
+    public FeatureStore getCalibratePointFeatureStore();
+
+    /**
+     * @param calibratePointFeatureStore the calibratePointFeatureStore to set
+     */
+    public void setCalibratePointFeatureStore(FeatureStore calibratePointFeatureStore);
+
+
+    /**
+     * @return the calibratePointIdRouteField
+     */
+    public FeatureAttributeDescriptor getCalibratePointIdRouteField();
+
+    /**
+     * @param calibratePointIdRouteField the calibratePointIdRouteField to set
+     */
+    public void setCalibratePointIdRouteField(FeatureAttributeDescriptor calibratePointIdRouteField);
+
+    /**
+     * @return the fromMeasureField
+     */
+    public FeatureAttributeDescriptor getFromMeasureField();
+
+    /**
+     * @param fromMeasureField the fromMeasureField to set
+     */
+    public void setFromMeasureField(FeatureAttributeDescriptor fromMeasureField);
+
+    /**
+     * @return the newFeatureStoreParameters
+     */
+    public NewFeatureStoreParameters getNewFeatureStoreParameters();
+
+    /**
+     * @param newFeatureStoreParameters
+     *            the newFeatureStoreParameters to set
+     */
+    public void setNewFeatureStoreParameters(NewFeatureStoreParameters newFeatureStoreParameters);
+
+
+    /**
+     * @return the measureCalculationMethods
+     */
+    public LrsMeasureCalculationMethods getMeasureCalculationMethods();
+
+    /**
+     * @param measureCalculationMethods the measureCalculationMethods to set
+     */
+    public void setMeasureCalculationMethods(LrsMeasureCalculationMethods measureCalculationMethods);
+
+
+    /**
+     * @return the measureUnits
+     */
+    public DistanceUnits getMeasureUnits();
+
+    /**
+     * @param measureUnits the measureUnits to set
+     */
+    public void setMeasureUnits(DistanceUnits measureUnits);
+
+
+    /**
+     * @return the searchRadius
+     */
+    public double getSearchRadius();
+
+    /**
+     * @param searchRadius the searchRadius to set
+     */
+    public void setSearchRadius(double searchRadius);
+
+
+    /**
+     * @return the interpolateBetweenCalibrationPoints
+     */
+    public boolean interpolateBetweenCalibrationPoints();
+
+    /**
+     * @param interpolateBetweenCalibrationPoints the interpolateBetweenCalibrationPoints to set
+     */
+    public void setInterpolateBetweenCalibrationPoints(boolean interpolateBetweenCalibrationPoints);
+
+
+    /**
+     * @return the extrapolateBeforeCalibrationPoints
+     */
+    public boolean extrapolateBeforeCalibrationPoints();
+
+    /**
+     * @param extrapolateBeforeCalibrationPoints the extrapolateBeforeCalibrationPoints to set
+     */
+    public void setExtrapolateBeforeCalibrationPoints(boolean extrapolateBeforeCalibrationPoints);
+
+
+    /**
+     * @return the extrapolateAfterCalibrationPoints
+     */
+    public boolean extrapolateAfterCalibrationPoints();
+
+    /**
+     * @param extrapolateAfterCalibrationPoints the extrapolateAfterCalibrationPoints to set
+     */
+    public void setExtrapolateAfterCalibrationPoints(boolean extrapolateAfterCalibrationPoints);
+
+
+    /**
+     * @return the ignoreSpatialGaps
+     */
+    public boolean ignoreSpatialGaps();
+
+    /**
+     * @param ignoreSpatialGaps the ignoreSpatialGaps to set
+     */
+    public void setIgnoreSpatialGaps(boolean ignoreSpatialGaps);
+
+    /**
+     * @return the includeAll
+     */
+    public boolean includeAll();
+
+    /**
+     * @param includeAll the includeAll to set
+     */
+    public void setIncludeAll(boolean includeAll);
+
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsEditRouteCalibrationSelectIdRouteAlgorithmParams.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsEditRouteCalibrationSelectIdRouteAlgorithmParams.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsEditRouteCalibrationSelectIdRouteAlgorithmParams.java	(revision 950)
@@ -0,0 +1,15 @@
+/*
+ * Copyright 2015 DiSiD Technologies S.L.L. All rights reserved.
+ *
+ * Project  : DiSiD org.gvsig.lrs.lib.api
+ * SVN Id   : $Id$
+ */
+package org.gvsig.lrs.lib.api;
+
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+
+public interface LrsEditRouteCalibrationSelectIdRouteAlgorithmParams extends LrsAlgorithmParams{
+    public FeatureAttributeDescriptor getIdRouteField();
+    public void setIdRouteField(FeatureAttributeDescriptor idRouteField);
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsAlgorithm.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsAlgorithm.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsAlgorithm.java	(revision 950)
@@ -0,0 +1,59 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.lib.api;
+
+import org.gvsig.lrs.lib.api.exceptions.LrsException;
+import org.gvsig.tools.dynobject.DynObject;
+import org.gvsig.tools.service.Service;
+import org.gvsig.tools.task.SimpleTaskStatus;
+
+
+/**
+ * @author fdiaz
+ *
+ */
+public interface LrsAlgorithm extends Service{
+
+    /**
+     * Gets algorithm's parameters.
+     *
+     * @return A DynObject.
+     */
+    public LrsAlgorithmParams getParams();
+
+    /**
+     * Executes the algorithm
+     * @throws LrsException
+     *
+     */
+    public void execute(SimpleTaskStatus taskStatus) throws LrsException;
+
+    /**
+     * Sets parameters
+     *
+     * @param params
+     * @throws IllegalArgumentException
+     */
+    public void setParams(LrsAlgorithmParams params) throws IllegalArgumentException;
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsEditRouteCalibrationAlgorithmParams.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsEditRouteCalibrationAlgorithmParams.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsEditRouteCalibrationAlgorithmParams.java	(revision 950)
@@ -0,0 +1,46 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.lib.api;
+
+import java.util.List;
+import java.util.Map;
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureReference;
+
+/**
+ * @author dmartinez
+ *
+ */
+public interface LrsEditRouteCalibrationAlgorithmParams extends LrsAlgorithmParams {
+    public FeatureAttributeDescriptor getIdRouteField();
+
+    public void setIdRouteField(FeatureAttributeDescriptor idRouteField);
+
+    public String getSelectedRouteName();
+
+    public void setSelectedRouteName(String selectedRouteName);
+
+    public Map<FeatureReference, List<Double>> getModifiedMCoordinates();
+
+    public void setModifiedMCoordinates(Map<FeatureReference, List<Double>> modifiedGeometries);
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsGenerateDynamicSegmentationAlgorithmParams.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsGenerateDynamicSegmentationAlgorithmParams.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsGenerateDynamicSegmentationAlgorithmParams.java	(revision 950)
@@ -0,0 +1,84 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.lib.api;
+
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.feature.NewFeatureStoreParameters;
+
+/**
+ * @author fdiaz
+ *
+ */
+public interface LrsGenerateDynamicSegmentationAlgorithmParams extends LrsAlgorithmParams {
+
+    public FeatureStore getSourceFeatureStore();
+
+
+    public void setSourceFeatureStore(FeatureStore sourceFeatureStore);
+
+
+    public FeatureAttributeDescriptor getIdRouteField();
+
+
+    public void setIdRouteField(FeatureAttributeDescriptor idRouteField);
+
+
+    public NewFeatureStoreParameters getNewFeatureStoreParameters();
+
+
+    public void setNewFeatureStoreParameters(
+        NewFeatureStoreParameters newFeatureStoreParameters);
+
+
+    public FeatureStore getValueTableFeatureStore() ;
+
+
+    public void setValueTableFeatureStore(FeatureStore valueTableFeatureStore);
+
+
+    public FeatureAttributeDescriptor getValueTableIdRouteField();
+
+
+    public void setValueTableIdRouteField(
+        FeatureAttributeDescriptor valueTableIdRouteField);
+
+
+    public FeatureAttributeDescriptor getLandmarkField();
+
+
+    public void setLandmarkField(FeatureAttributeDescriptor landmarkField);
+
+
+    public FeatureAttributeDescriptor getFinalLandmarkField();
+
+
+    public void setFinalLandmarkField(
+        FeatureAttributeDescriptor finalLandmarkField);
+
+
+    public FeatureAttributeDescriptor getValueField();
+
+
+    public void setValueField(FeatureAttributeDescriptor valueField);
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsAlgorithmParams.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsAlgorithmParams.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsAlgorithmParams.java	(revision 950)
@@ -0,0 +1,44 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.lib.api;
+
+
+/**
+ * @author fdiaz
+ *
+ */
+public interface LrsAlgorithmParams {
+
+
+    /**
+     *
+     */
+    String getName();
+
+    /**
+     *
+     */
+    String getDescription();
+
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsSourceOfMeasures.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsSourceOfMeasures.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsSourceOfMeasures.java	(revision 950)
@@ -0,0 +1,56 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.lib.api;
+
+import org.gvsig.tools.ToolsLocator;
+
+
+/**
+ * @author fdiaz
+ *
+ */
+public enum LrsSourceOfMeasures {
+    LENGTH("length",0),
+    ONE_FIELD("one_field",1),
+    TWO_FIELDS("two_fields",2);
+
+    private final String name;
+    private final int value;
+
+    LrsSourceOfMeasures(String name, int value){
+        this.name = name;
+        this.value = value;
+    }
+
+    public String getName(){
+        return this.name;
+    }
+
+    public int getValue(){
+        return this.value;
+    }
+
+    public String toString(){
+        return ToolsLocator.getI18nManager().getTranslation(name);
+    }
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/DistanceUnits.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/DistanceUnits.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/DistanceUnits.java	(revision 950)
@@ -0,0 +1,67 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.lib.api;
+
+import org.gvsig.tools.ToolsLocator;
+
+
+/**
+ * @author fdiaz
+ *
+ */
+public enum DistanceUnits {
+    KILOMETER("Kilometer","Km",1000),
+    METER("meter","m",1),
+    CENTIMETER("centimeter","cm",0.01),
+    MILLIMETER("millimeter","mm",0.001),
+    MILE("mile","mi",1609.344),
+    YARD("yard","Ya",0.9144),
+    FOOT("foot","ft",0.3048),
+    INCH("inch","in",0.0254);
+
+    private final String name;
+    private final String abrev;
+    private final double transToMeter;
+
+    DistanceUnits(String name, String abrev, double transToMeter){
+        this.name = name;
+        this.abrev = abrev;
+        this.transToMeter = transToMeter;
+    }
+
+    public String getName(){
+        return this.name;
+    }
+
+    public String getAbrev(){
+        return this.abrev;
+    }
+
+    public double getTransToMeter(){
+        return this.transToMeter;
+    }
+
+    public String toString(){
+        return ToolsLocator.getI18nManager().getTranslation(name);
+    }
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsAlgorithmsLocator.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsAlgorithmsLocator.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsAlgorithmsLocator.java	(revision 950)
@@ -0,0 +1,105 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.lib.api;
+
+import org.gvsig.tools.locator.AbstractLocator;
+import org.gvsig.tools.locator.Locator;
+import org.gvsig.tools.locator.LocatorException;
+
+
+/**
+ * @author fdiaz
+ *
+ */
+public class LrsAlgorithmsLocator extends AbstractLocator {
+
+    /**
+     * LrsAlgorithms locator name
+     */
+    private static final String LOCATOR_NAME = "LrsAlgorithmsLocator";
+
+    /**
+     * LrsAlgorithms manager name
+     */
+    public static final String MANAGER_NAME = "LrsAlgorithmsManager";
+
+    /**
+     * LrsAlgorithms manager description
+     */
+    private static final String MANAGER_DESCRIPTION =
+        "LrsAlgorithms Manager of gvSIG";
+
+
+    /**
+     * Unique instance
+     */
+    private static final LrsAlgorithmsLocator instance = new LrsAlgorithmsLocator();
+
+    /* (non-Javadoc)
+     * @see org.gvsig.tools.locator.Locator#getLocatorName()
+     */
+    public String getLocatorName() {
+        return LOCATOR_NAME;
+    }
+
+    /**
+     * Registers the Class implementing the LrsAlgorithmsManager interface.
+     *
+     * @param clazz
+     *            implementing the LrsAlgorithmsManager interface
+     */
+    public static void registerLrsAlgorithmsManager(Class clazz){
+        getInstance().register(MANAGER_NAME, MANAGER_DESCRIPTION, clazz);
+    }
+
+    /**
+     * Registers the default Class implementing the LrsAlgorithmsManager interface
+     *
+     * @param clazz
+     *            implementing the LrsAlgorithmsManager interface
+     */
+    public static void registerDefaultLrsAlgorithmsManager(Class clazz){
+        getInstance().registerDefault(MANAGER_NAME, MANAGER_DESCRIPTION, clazz);
+    }
+
+    /**
+     * Return a reference to LrsAlgorithmsManager.
+     *
+     * @return a reference to LrsAlgorithmsManager
+     * @throws LocatorException
+     *             if there is no access to the class or the class
+     *             cannot be instantiated
+     * @see Locator#get(String)
+     */
+    public static LrsAlgorithmsManager getLrsAlgorithmsManager() throws LocatorException {
+        return (LrsAlgorithmsManager) getInstance().get(MANAGER_NAME);
+    }
+
+    /**
+     * @return
+     */
+    public static Locator getInstance() {
+        return instance;
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsCreateRouteAlgorithmParams.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsCreateRouteAlgorithmParams.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsCreateRouteAlgorithmParams.java	(revision 950)
@@ -0,0 +1,137 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.lib.api;
+
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.feature.NewFeatureStoreParameters;
+
+/**
+ * @author fdiaz
+ *
+ */
+public interface LrsCreateRouteAlgorithmParams extends LrsAlgorithmParams {
+
+
+    /**
+     * @return the sourceFeatureStore
+     */
+    public FeatureStore getSourceFeatureStore();
+
+    /**
+     * @param sourceFeatureStore the sourceFeatureStore to set
+     */
+    public void setSourceFeatureStore(FeatureStore sourceFeatureStore);
+
+    /**
+     * @return the idRouteField
+     */
+    public FeatureAttributeDescriptor getIdRouteField();
+
+    /**
+     * @param idRouteField the idRouteField to set
+     */
+    public void setIdRouteField(FeatureAttributeDescriptor idRouteField);
+
+    /**
+     * @return the newFeatureStoreParameters
+     */
+    public NewFeatureStoreParameters getNewFeatureStoreParameters();
+
+    /**
+     * @param newFeatureStoreParameters
+     *            the newFeatureStoreParameters to set
+     */
+    public void setNewFeatureStoreParameters(NewFeatureStoreParameters newFeatureStoreParameters);
+
+    /**
+     * @return the sourceOfMeasures
+     */
+    public LrsSourceOfMeasures getSourceOfMeasures();
+
+    /**
+     * @param sourceOfMeasures the sourceOfMeasures to set
+     */
+    public void setSourceOfMeasures(LrsSourceOfMeasures sourceOfMeasures);
+
+    /**
+     * @return the fromMeasureField
+     */
+    public FeatureAttributeDescriptor getFromMeasureField();
+
+    /**
+     * @param fromMeasureField the fromMeasureField to set
+     */
+    public void setFromMeasureField(FeatureAttributeDescriptor fromMeasureField);
+
+    /**
+     * @return the toMeasureField
+     */
+    public FeatureAttributeDescriptor getToMeasureField();
+
+    /**
+     * @param toMeasureField the toMeasureField to set
+     */
+    public void setToMeasureField(FeatureAttributeDescriptor toMeasureField);
+
+    /**
+     * @return the coordinatePriority
+     */
+    public LrsCoordinatesPriority getCoordinatePriority();
+
+    /**
+     * @param coordinatePriority the coordinatePriority to set
+     */
+    public void setCoordinatePriority(LrsCoordinatesPriority coordinatePriority);
+
+    /**
+     * @return the measureFactor
+     */
+    public double getMeasureFactor();
+
+    /**
+     * @param measureFactor the measureFactor to set
+     */
+    public void setMeasureFactor(double measureFactor);
+
+    /**
+     * @return the measureOffset
+     */
+    public double getMeasureOffset();
+
+    /**
+     * @param measureOffset the measureOffset to set
+     */
+    public void setMeasureOffset(double measureOffset);
+
+    /**
+     * @return the ignoreSpatialGaps
+     */
+    public boolean ignoreSpatialGaps();
+
+    /**
+     * @param ignoreSpatialGaps the ignoreSpatialGaps to set
+     */
+    public void setIgnoreSpatialGaps(boolean ignoreSpatialGaps);
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsAlgorithmsLibrary.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsAlgorithmsLibrary.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsAlgorithmsLibrary.java	(revision 950)
@@ -0,0 +1,57 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.lib.api;
+
+import org.gvsig.tools.library.AbstractLibrary;
+import org.gvsig.tools.library.LibraryException;
+import org.gvsig.tools.locator.ReferenceNotRegisteredException;
+
+
+/**
+ * @author fdiaz
+ *
+ */
+public class LrsAlgorithmsLibrary extends AbstractLibrary {
+
+    /* (non-Javadoc)
+     * @see org.gvsig.tools.library.AbstractLibrary#doInitialize()
+     */
+    @Override
+    protected void doInitialize() throws LibraryException {
+        registerAsAPI(LrsAlgorithmsLibrary.class);
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.tools.library.AbstractLibrary#doPostInitialize()
+     */
+    @Override
+    protected void doPostInitialize() throws LibraryException {
+        // Validate there is any implementation registered.
+        LrsAlgorithmsManager manager = LrsAlgorithmsLocator.getLrsAlgorithmsManager();
+        if (manager == null) {
+            throw new ReferenceNotRegisteredException(
+                LrsAlgorithmsLocator.MANAGER_NAME, LrsAlgorithmsLocator.getInstance());
+        }
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsShowMeasuresAlgorithmParams.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsShowMeasuresAlgorithmParams.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsShowMeasuresAlgorithmParams.java	(revision 950)
@@ -0,0 +1,53 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.lib.api;
+
+
+/**
+ * @author dmartinez
+ *
+ */
+public interface LrsShowMeasuresAlgorithmParams extends LrsAlgorithmParams {
+    public static final Integer LRS_SHOWMEASURES_UNKNOWN_OTHER = 0;
+    public static final Integer LRS_SHOWMEASURES_METER = 1;
+    public static final Integer LRS_SHOWMEASURES_KILOMETER = 2;
+    
+    public static final String LRS_SHOWMEASURES_UNKNOWN_OTHER_LABEL = "_Unknown_slash_other";
+    public static final String LRS_SHOWMEASURES_METER_LABEL = "_m";
+    public static final String LRS_SHOWMEASURES_KILOMETER_LABEL = "_Km";
+    
+    /**
+     * @return the distance
+     */
+    public double getDistance();
+
+    /**
+     * @param distance the distance to set
+     */
+    public void setDistance(double distance);
+    
+    public int getUnits();
+
+    public void setUnits(int units);
+
+}
\ No newline at end of file
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsAlgorithmsManager.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsAlgorithmsManager.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsAlgorithmsManager.java	(revision 950)
@@ -0,0 +1,122 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.lib.api;
+
+import org.cresques.cts.IProjection;
+
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.dal.exception.InitializeException;
+import org.gvsig.fmap.dal.exception.ProviderNotRegisteredException;
+import org.gvsig.fmap.dal.exception.ValidateDataParametersException;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.feature.FeatureType;
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.geom.exception.CreateGeometryException;
+import org.gvsig.fmap.geom.operation.GeometryOperationException;
+import org.gvsig.fmap.geom.operation.GeometryOperationNotSupportedException;
+import org.gvsig.fmap.geom.primitive.Point;
+import org.gvsig.fmap.geom.type.GeometryTypeNotSupportedException;
+import org.gvsig.fmap.geom.type.GeometryTypeNotValidException;
+import org.gvsig.tools.dynobject.DynObject;
+import org.gvsig.tools.locator.LocatorException;
+import org.gvsig.tools.service.Manager;
+
+
+/**
+ * @author fdiaz
+ *
+ */
+public interface LrsAlgorithmsManager extends Manager{
+
+    /**
+     * Creates the appropriate algorithm to the parameters
+     *
+     * @param params
+     * @return LrsAlgorithm
+     */
+    public LrsAlgorithm createLrsAlgorithm(LrsAlgorithmParams params);
+
+    /*
+     * Creates an LrsCreateRouteAlgorithmParams
+     *
+     * @return LrsCreateRouteAlgorithmParams
+     */
+    public LrsCreateRouteAlgorithmParams createLrsCreateRouteAlgorithmParams();
+
+    /*
+     * Creates an LrsCalibrateRouteAlgorithmParams
+     *
+     * @return LrsCalibrateRouteAlgorithmParams
+     */
+    public LrsCalibrateRouteAlgorithmParams createLrsCalibrateRouteAlgorithmParams();
+
+    /*
+     * Creates an LrsEditRouteCalibrationAlgorithmParams
+     *
+     * @return LrsEditRouteCalibrationAlgorithmParams
+     */
+    public LrsEditRouteCalibrationAlgorithmParams createLrsEditRouteCalibrationAlgorithmParams();
+
+    /*
+     * Creates an LrsEditRouteCalibrationSelectIdRouteAlgorithmParams
+     *
+     * @return LrsEditRouteCalibrationSelectIdRouteAlgorithmParams
+     */
+    public LrsEditRouteCalibrationSelectIdRouteAlgorithmParams createLrsEditRouteCalibrationSelectIdRouteAlgorithmParams();
+
+    /*
+     * Creates an LrsEditRouteCalibrationSelectIdRouteAlgorithmParams
+     *
+     * @return LrsEditRouteCalibrationSelectIdRouteAlgorithmParams
+     */
+    public LrsShowMeasuresAlgorithmParams createLrsShowMeasuresAlgorithmParams();
+
+    /*
+     * Creates an LrsGenerateDynamicSegmentationAlgorithmParams
+     *
+     * @return LrsGenerateDynamicSegmentationAlgorithmParams
+     */
+    public LrsGenerateDynamicSegmentationAlgorithmParams createLrsGenerateDynamicSegmentationAlgorithmParams();
+
+    /*
+     * Creates a new shape
+     */
+    public void createNewShape(FeatureType sourceFeatureType,
+        int outputLayerType, String outputLayerPath, IProjection projection) throws ValidateDataParametersException, DataException, GeometryTypeNotSupportedException, GeometryTypeNotValidException;
+
+    public FeatureStore getFeatureStore(String outputLayerPath,
+        IProjection projection) throws DataException, ValidateDataParametersException;
+
+    public MeasuresCalculator createMeasuresCalculator(Geometry geometry, boolean ignoreSpatialGaps);
+
+    public Point getMPointFromGeometry(Geometry geom, double m) throws CreateGeometryException, LocatorException;
+
+    /*
+     * Given a point without m in a M-Geometry, returns the point with the m-value
+     * @param geom
+     * @param pointNoM
+     * @return
+     */
+    public Point getMPointFromGeometry(Geometry geom, Point pointNoM) throws CreateGeometryException, GeometryOperationNotSupportedException, GeometryOperationException;
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsMeasureCalculationMethods.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsMeasureCalculationMethods.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api/LrsMeasureCalculationMethods.java	(revision 950)
@@ -0,0 +1,55 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.lib.api;
+
+import org.gvsig.tools.ToolsLocator;
+
+
+/**
+ * @author dmartinez
+ *
+ */
+public enum LrsMeasureCalculationMethods {
+    DISTANCE("distance",0),
+    MEASURES("measures",1);
+
+    private final String name;
+    private final int value;
+
+    LrsMeasureCalculationMethods(String name, int value){
+        this.name = name;
+        this.value = value;
+    }
+
+    public String getName(){
+        return this.name;
+    }
+
+    public int getValue(){
+        return this.value;
+    }
+
+    public String toString(){
+        return ToolsLocator.getI18nManager().getTranslation(name);
+    }
+}

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib/api
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs/lib
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig/lrs
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org/gvsig
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java/org
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main/java
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/main
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/test/resources
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/test/java
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src/test
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/src
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath


Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/pom.xml
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/pom.xml	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api/pom.xml	(revision 950)
@@ -0,0 +1,40 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+  <artifactId>org.gvsig.lrs.lib.api</artifactId>
+  <name>${project.artifactId}</name>
+  <parent>
+    <groupId>org.gvsig</groupId>
+    <artifactId>org.gvsig.lrs.lib</artifactId>
+    <version>1.0.173</version>
+  </parent>
+
+  <build>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-jar-plugin</artifactId>
+        <configuration>
+        </configuration>
+        <executions>
+          <!-- Generates a jar file only with the test classes -->
+          <execution>
+            <goals>
+              <goal>test-jar</goal>
+            </goals>
+          </execution>
+        </executions>
+      </plugin>
+    </plugins>
+  </build>
+
+  <dependencies>
+    <dependency>
+      <groupId>org.gvsig</groupId>
+      <artifactId>org.gvsig.tools.lib</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.gvsig</groupId>
+      <artifactId>org.gvsig.fmap.dal.api</artifactId>
+    </dependency>
+  </dependencies>
+</project>
\ No newline at end of file

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib/org.gvsig.lrs.lib.api
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath
target

.project



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.lib
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath

.project



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/test/java
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/test/resources
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/test
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath


Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/JLrsAlgorithmParams.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/JLrsAlgorithmParams.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/JLrsAlgorithmParams.java	(revision 950)
@@ -0,0 +1,55 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.swing.api;
+
+import java.awt.event.ActionListener;
+
+import org.gvsig.lrs.lib.api.LrsAlgorithmParams;
+import org.gvsig.lrs.lib.api.exceptions.LrsGettingParametersException;
+import org.gvsig.lrs.lib.api.exceptions.LrsNeededParameterException;
+import org.gvsig.tools.dynobject.DynObject;
+import org.gvsig.tools.swing.api.Component;
+
+
+/**
+ * @author fdiaz
+ *
+ */
+public interface JLrsAlgorithmParams extends Component {
+
+    public LrsAlgorithmParams getParams() throws LrsGettingParametersException, LrsNeededParameterException;
+
+    public void setParams(LrsAlgorithmParams params);
+
+    public void clear();
+
+    public boolean isCanceled();
+
+    public void setVisibleAceptCancel(boolean visible);
+
+    public boolean getVisibleAceptCancel();
+
+    public void addActionListener(ActionListener listener);
+
+    public void removeActionListener(ActionListener listener);
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/LrsAlgorithmsSwingLocator.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/LrsAlgorithmsSwingLocator.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/LrsAlgorithmsSwingLocator.java	(revision 950)
@@ -0,0 +1,106 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.swing.api;
+
+import org.gvsig.tools.locator.AbstractLocator;
+import org.gvsig.tools.locator.Locator;
+import org.gvsig.tools.locator.LocatorException;
+
+
+/**
+ * @author fdiaz
+ *
+ */
+public class LrsAlgorithmsSwingLocator extends AbstractLocator {
+    /**
+     * LrsSwing locator name
+     */
+    private static final String LOCATOR_NAME = "LrsAlgorithmsSwingLocator";
+
+    /**
+     * LrsSwing manager name
+     */
+    public static final String MANAGER_NAME = "LrsAlgorithmsSwingManager";
+
+    /**
+     * LrsSwing manager description
+     */
+    private static final String MANAGER_DESCRIPTION =
+        "Lrs Swing Algorithms Manager of gvSIG";
+
+
+    /**
+     * Unique instance
+     */
+    private static final LrsAlgorithmsSwingLocator instance = new LrsAlgorithmsSwingLocator();
+
+
+    /* (non-Javadoc)
+     * @see org.gvsig.tools.locator.Locator#getLocatorName()
+     */
+    public String getLocatorName() {
+        return LOCATOR_NAME;
+    }
+
+
+    /**
+     * Registers the Class implementing the LrsSwingManager interface.
+     *
+     * @param clazz
+     *            implementing the LrsAlgorthmsSwingManager interface
+     */
+    public static void registerLrsAlgorithmsSwingManager(Class clazz){
+        getInstance().register(MANAGER_NAME, MANAGER_DESCRIPTION, clazz);
+    }
+
+    /**
+     * Registers the default Class implementing the LrsSwingManager interface
+     *
+     * @param clazz
+     *            implementing the LrsAlgorthmsSwingManager interface
+     */
+    public static void registerDefaultLrsAlgorithmsSwingManager(Class clazz){
+        getInstance().registerDefault(MANAGER_NAME, MANAGER_DESCRIPTION, clazz);
+    }
+
+    /**
+     * Return a reference to LrsAlgorithmsSwingManager.
+     *
+     * @return a reference to LrsAlgorithmsSwingManager
+     * @throws LocatorException
+     *             if there is no access to the class or the class
+     *             cannot be instantiated
+     * @see Locator#get(String)
+     */
+    public static LrsAlgorithmsSwingManager getLrsAlgorithmsSwingManager() throws LocatorException {
+        return (LrsAlgorithmsSwingManager)(getInstance().get(MANAGER_NAME));
+    }
+
+    /**
+     * @return
+     */
+    public static Locator getInstance() {
+        return instance;
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/LrsAlgorithmsSwingLibrary.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/LrsAlgorithmsSwingLibrary.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/LrsAlgorithmsSwingLibrary.java	(revision 950)
@@ -0,0 +1,111 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.swing.api;
+
+import java.io.InputStream;
+
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.dynobject.DynStruct;
+import org.gvsig.tools.library.AbstractLibrary;
+import org.gvsig.tools.library.LibraryException;
+import org.gvsig.tools.locator.ReferenceNotRegisteredException;
+import org.gvsig.tools.persistence.PersistenceManager;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+
+/**
+ * @author fdiaz
+ *
+ */
+public class LrsAlgorithmsSwingLibrary extends AbstractLibrary {
+
+	private static final Logger LOG = LoggerFactory.getLogger(LrsAlgorithmsSwingLibrary.class);
+    private static final String DYNCLASS_NAME = "JLrsLastUsedValues";
+	
+	/* (non-Javadoc)
+	 * @see org.gvsig.tools.library.AbstractLibrary#doInitialize()
+	 */
+	@Override
+	protected void doInitialize() throws LibraryException {
+		registerAsAPI(LrsAlgorithmsSwingLibrary.class);
+		
+		registerLrsCalculateMLastUsedValuesDefinition();
+		
+		
+//		DynObjectManager dynManager = ToolsLocator.getDynObjectManager();
+//		InputStream resource = this.getClass().getResourceAsStream("/JLrsCalculateMLastUsedValues.xml");
+//		Map classes = null;
+//		try {
+//			classes = dynManager.importDynClassDefinitions(resource, this.getClass().getClassLoader());
+//		} catch (XmlPullParserException e) {
+//			LOG.warn("Error parsing the resource.", e);
+//		} catch (IOException e) {
+//			LOG.warn("Error opening the resource.", e);
+//		}
+//		Iterator it = classes.entrySet().iterator();
+//		while(it.hasNext()){
+//			Map.Entry entry = (Map.Entry) it.next();
+//			DynClass dynClass = (DynClass) entry.getValue();
+//			if(!dynManager.has(dynClass.getFullName())){
+//				dynManager.add((DynClass) entry.getValue());
+//			}
+//		}
+	}
+	
+	
+	private void registerLrsCalculateMLastUsedValuesDefinition(){
+		String name = "JLrsCalculateMLastUsedValues";
+		PersistenceManager manager = ToolsLocator.getPersistenceManager();
+		DynStruct definition = manager.getDefinition(name);
+		if ( definition == null) {
+			InputStream stream = this.getClass().getResourceAsStream("/JLrsCalculateMLastUsedValues.xml");
+			if( stream == null ) {
+				throw new RuntimeException("Error file not found: JLrsCalculateMLastUsedValues.xml");
+			}
+			definition = manager.addDefinition(
+					this.getClass(),
+					name, 
+					stream,
+					this.getClass().getClassLoader(), 
+					null, 
+					null
+			);
+		}
+	}
+
+	/* (non-Javadoc)
+	 * @see org.gvsig.tools.library.AbstractLibrary#doPostInitialize()
+	 */
+	@Override
+	protected void doPostInitialize() throws LibraryException {
+		// Validate there is any implementation registered.
+		LrsAlgorithmsSwingManager manager = LrsAlgorithmsSwingLocator.getLrsAlgorithmsSwingManager();
+		if (manager == null) {
+			throw new ReferenceNotRegisteredException(
+					LrsAlgorithmsSwingLocator.MANAGER_NAME, LrsAlgorithmsSwingLocator.getInstance());
+		}
+	}
+
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/JLrsCreateRouteAlgorithmParams.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/JLrsCreateRouteAlgorithmParams.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/JLrsCreateRouteAlgorithmParams.java	(revision 950)
@@ -0,0 +1,32 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.swing.api;
+
+
+/**
+ * @author fdiaz
+ *
+ */
+public interface JLrsCreateRouteAlgorithmParams extends JLrsAlgorithmParams {
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/JLrsCalibrateRouteAlgorithmParams.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/JLrsCalibrateRouteAlgorithmParams.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/JLrsCalibrateRouteAlgorithmParams.java	(revision 950)
@@ -0,0 +1,32 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.swing.api;
+
+
+/**
+ * @author fdiaz
+ *
+ */
+public interface JLrsCalibrateRouteAlgorithmParams extends JLrsAlgorithmParams {
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/LrsAlgorithmsSwingManager.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/LrsAlgorithmsSwingManager.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/LrsAlgorithmsSwingManager.java	(revision 950)
@@ -0,0 +1,74 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.swing.api;
+
+import java.util.List;
+
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.lrs.lib.api.LrsCalibrateRouteAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsEditRouteCalibrationAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsEditRouteCalibrationSelectIdRouteAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsGenerateDynamicSegmentationAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsShowMeasuresAlgorithmParams;
+import org.gvsig.lrs.lib.api.exceptions.LrsGettingParametersException;
+import org.gvsig.lrs.lib.api.exceptions.LrsNeededParameterException;
+import org.gvsig.tools.dynobject.DynObject;
+import org.gvsig.tools.service.Manager;
+import org.gvsig.tools.task.TaskStatus;
+
+
+/**
+ * @author fdiaz
+ *
+ */
+public interface LrsAlgorithmsSwingManager extends Manager {
+
+    public JLrsAlgorithmParams createJLrsCreateRouteAlgorithmParameters(FLayers layers, LrsCreateRouteAlgorithmParams parameters) throws LrsNeededParameterException;
+
+    public JLrsProgressDialog createJLrsProgressDialog(TaskStatus taskStatus);
+
+    public JLrsAlgorithmParams createJLrsCalibrateRouteAlgorithmParameters(FLayers layers, LrsCalibrateRouteAlgorithmParams parameters) throws LrsNeededParameterException;
+
+    public JLrsAlgorithmParams createJLrsEditRouteCalibrationSelectIdRouteAlgorithmParameters(FLyrVect layer, LrsEditRouteCalibrationSelectIdRouteAlgorithmParams parameters) throws LrsNeededParameterException;
+
+    public JLrsAlgorithmParams createJLrsEditRouteCalibrationAlgorithmParameters(FLyrVect layer, MapContext mapContext, FeatureAttributeDescriptor selectedIdRoute, LrsEditRouteCalibrationAlgorithmParams parameters) throws LrsNeededParameterException, LrsGettingParametersException;
+
+    public JLrsAlgorithmParams createJLrsShowMeasuresAlgorithmParameters(FLayer layer, LrsShowMeasuresAlgorithmParams parameters) throws LrsNeededParameterException;
+
+    public JLrsAlgorithmParams createJLrsGenerateDynamicSegmentationAlgorithmParameters(FLayers layers, List<FeatureStore> tables, LrsGenerateDynamicSegmentationAlgorithmParams parameters) throws LrsNeededParameterException;
+
+    public JLrsAlgorithmParams createJLrsCalculateMRoutePanel(FLayer layer) throws LrsNeededParameterException;
+
+	public JLrsAlgorithmParams createJLrsCalculateMRoutePanel(FLayer layer, JLrsLastUsedValues params) throws LrsNeededParameterException;
+
+	public JLrsLastUsedValues getJLrsLastUsedValues(DynObject pluginProperties);
+	
+	public JLrsLastUsedValues getJLrsLastUsedValues();
+	
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/JLrsLastUsedValues.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/JLrsLastUsedValues.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/JLrsLastUsedValues.java	(revision 950)
@@ -0,0 +1,19 @@
+package org.gvsig.lrs.swing.api;
+
+import org.gvsig.tools.dynobject.DynObject;
+
+public interface JLrsLastUsedValues{
+	
+	public String getPkInicial();
+	
+	public String getPkFinal();
+	
+	public void setPkInicial(String ini);
+	
+	public void setPkFinal(String fin);
+
+	public void setParams(DynObject pluginProperties);
+	
+	public DynObject getParams();
+
+}

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/JLrsLastUsedValues.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/JLrsProgressDialog.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/JLrsProgressDialog.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/JLrsProgressDialog.java	(revision 950)
@@ -0,0 +1,40 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.swing.api;
+
+import java.awt.event.ActionListener;
+
+import org.gvsig.tools.swing.api.Component;
+
+
+/**
+ * @author fdiaz
+ *
+ */
+public interface JLrsProgressDialog extends Component {
+    public boolean isCanceled();
+
+    public void addActionListener(ActionListener listener);
+
+    public void removeActionListener(ActionListener listener);
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/JLrsEditRouteCalibrationAlgorithmParams.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/JLrsEditRouteCalibrationAlgorithmParams.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/JLrsEditRouteCalibrationAlgorithmParams.java	(revision 950)
@@ -0,0 +1,32 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.swing.api;
+
+
+/**
+ * @author fdiaz
+ *
+ */
+public interface JLrsEditRouteCalibrationAlgorithmParams extends JLrsAlgorithmParams {
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/JLrsGenerateDynamicSegmentationAlgorithmParams.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/JLrsGenerateDynamicSegmentationAlgorithmParams.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api/JLrsGenerateDynamicSegmentationAlgorithmParams.java	(revision 950)
@@ -0,0 +1,32 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.swing.api;
+
+
+/**
+ * @author fdiaz
+ *
+ */
+public interface JLrsGenerateDynamicSegmentationAlgorithmParams extends JLrsAlgorithmParams {
+
+}

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing/api
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs/swing
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig/lrs
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org/gvsig
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java/org
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/java
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath


Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/resources/META-INF/services/org.gvsig.tools.library.Library
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/resources/META-INF/services/org.gvsig.tools.library.Library	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/resources/META-INF/services/org.gvsig.tools.library.Library	(revision 950)
@@ -0,0 +1 @@
+org.gvsig.lrs.swing.api.LrsAlgorithmsSwingLibrary
\ No newline at end of file

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/resources/META-INF/services
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/resources/META-INF
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath


Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/resources/JLrsCalculateMLastUsedValues.xml
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/resources/JLrsCalculateMLastUsedValues.xml	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/resources/JLrsCalculateMLastUsedValues.xml	(revision 950)
@@ -0,0 +1,20 @@
+<?xml version="1.0"?>
+<!--
+Definitions of plugin persistence org.gvsig.exportto.app.extension.  
+ -->
+<definitions>
+  <version>1.0.0</version>
+  <classes>
+    <class name="JLrsCalculateMLastUsedValues">
+      <description>Persistence of the LRS plugin</description>
+      <fields>
+        <field name="pkInicial" type="string" mandatory="false">
+          <description>Initial pk selected by the user</description>
+        </field>
+ 		<field name="pkFinal" type="string" mandatory="false">
+          <description>Final pk selected by the user</description>
+        </field>
+      </fields>
+    </class>
+  </classes>
+</definitions>  

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/resources/JLrsCalculateMLastUsedValues.xml
___________________________________________________________________
Added: svn:mime-type
   + text/plain


Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main/resources
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src/main
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/src
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath


Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/pom.xml
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/pom.xml	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api/pom.xml	(revision 950)
@@ -0,0 +1,24 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+  <parent>
+    <groupId>org.gvsig</groupId>
+    <artifactId>org.gvsig.lrs.swing</artifactId>
+    <version>1.0.173</version>
+  </parent>
+  <artifactId>org.gvsig.lrs.swing.api</artifactId>
+  <name>${project.artifactId}</name>
+  <dependencies>
+    <dependency>
+      <groupId>org.gvsig</groupId>
+      <artifactId>org.gvsig.fmap.mapcontext.api</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.gvsig</groupId>
+      <artifactId>org.gvsig.tools.swing.api</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.gvsig</groupId>
+      <artifactId>org.gvsig.lrs.lib.api</artifactId>
+    </dependency>
+  </dependencies>
+</project>

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.api
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath
target

.project


Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/resources/META-INF/services/org.gvsig.tools.library.Library
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/resources/META-INF/services/org.gvsig.tools.library.Library	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/resources/META-INF/services/org.gvsig.tools.library.Library	(revision 950)
@@ -0,0 +1 @@
+org.gvsig.lrs.swing.impl.DefaultLrsAlgorithmsSwingLibrary

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/resources/META-INF/services
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/resources/META-INF
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/resources
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath


Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/PointLayersComboBoxModel.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/PointLayersComboBoxModel.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/PointLayersComboBoxModel.java	(revision 950)
@@ -0,0 +1,164 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.swing.impl;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.swing.AbstractListModel;
+import javax.swing.ComboBoxModel;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.feature.FeatureType;
+import org.gvsig.fmap.geom.DataTypes;
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.operations.LayerCollection;
+import org.gvsig.fmap.mapcontext.layers.operations.LayersVisitor;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.tools.exception.BaseException;
+import org.gvsig.tools.visitor.VisitCanceledException;
+
+/**
+ * @author dmartinez
+ *
+ */
+public class PointLayersComboBoxModel extends AbstractListModel<FLayer> implements ComboBoxModel<FLayer> {
+
+    /**
+     *
+     */
+    private static final long serialVersionUID = -1271707498886332136L;
+
+    private static final Logger logger = LoggerFactory.getLogger(PointLayersComboBoxModel.class);
+
+    private LayerCollection layers;
+    private List<FLyrVect> vectLayers;
+    private FLayer selectedLayer;
+
+    /**
+     *
+     */
+    public PointLayersComboBoxModel(LayerCollection layers) {
+        this.layers = layers;
+        vectLayers = new ArrayList<FLyrVect>();
+        try {
+            layers.accept(new LayersVisitor() {
+
+                public void visit(Object obj) throws VisitCanceledException, BaseException {
+                    // TODO Auto-generated method stub
+
+                }
+
+                public void visit(FLayer layer) throws BaseException {
+                    if (layer instanceof FLyrVect) {
+                        FLyrVect lyrVect = (FLyrVect) layer;
+                        if (lyrVect.getGeometryType().isTypeOf(Geometry.TYPES.POINT)
+                            || lyrVect.getGeometryType().isTypeOf(Geometry.TYPES.MULTIPOINT)) {
+                            FeatureStore featureStore = lyrVect.getFeatureStore();
+                            try {
+                                FeatureType type = featureStore.getDefaultFeatureType();
+
+                                FeatureAttributeDescriptor[] attributeDescriptors = type.getAttributeDescriptors();
+                                Boolean nonGeometricDataTypeFound=false;
+                                Boolean numericDataTypeFound=false;
+                                Boolean dataTypesFound=false;
+                                Boolean validateNext=true;
+                                for (int i = 0; i < attributeDescriptors.length&&!dataTypesFound; i++) {
+                                    FeatureAttributeDescriptor featureAttributeDescriptor = attributeDescriptors[i];
+                                    validateNext=true;
+                                    if (featureAttributeDescriptor.getDataType().isNumeric()&&!numericDataTypeFound) {
+                                        numericDataTypeFound = true;
+                                        validateNext=false;
+                                    }
+                                    //This is done to avoid to validate twice the same numeric field
+                                    if (validateNext){
+                                        if (featureAttributeDescriptor.getDataType().getType() != DataTypes.GEOMETRY) {
+                                            nonGeometricDataTypeFound = true;
+                                        }
+                                    }
+                                    dataTypesFound=nonGeometricDataTypeFound&&numericDataTypeFound;
+                                }
+                                if(dataTypesFound){
+                                    logger.debug("Correct point layer found");
+                                    vectLayers.add(lyrVect);
+                                    if(lyrVect.isActive()){
+                                        selectedLayer = lyrVect;
+                                    }
+                                }
+                            } catch (DataException e1) {
+                                logger.warn(
+                                    new StringBuilder().append("Error getting default feature type from layer ").append(lyrVect.getName())
+                                        .toString(), e1);
+                            }
+                        }
+                    }
+                }
+            });
+        } catch (BaseException e1) {
+            logger.warn("Can't get linear vector layers", e1);
+        }
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see javax.swing.ListModel#getSize()
+     */
+    public int getSize() {
+        return vectLayers.size(); //.getLayersCount();
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see javax.swing.ListModel#getElementAt(int)
+     */
+    public FLayer getElementAt(int index) {
+        return vectLayers.get(index); //.getLayer(index);
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see javax.swing.ComboBoxModel#setSelectedItem(java.lang.Object)
+     */
+    public void setSelectedItem(final Object anItem) {
+        selectedLayer = (FLayer) anItem;
+        fireContentsChanged(this, -1, -1);
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see javax.swing.ComboBoxModel#getSelectedItem()
+     */
+    public Object getSelectedItem() {
+        return selectedLayer;
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCalculateMRoutePanel.xml
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCalculateMRoutePanel.xml	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCalculateMRoutePanel.xml	(revision 950)
@@ -0,0 +1,510 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<object classname="com.jeta.forms.store.memento.FormPackage">
+ <at name="fileversion">
+  <object classname="com.jeta.forms.store.memento.FormsVersion2">
+   <at name="major">2</at>
+   <at name="minor">0</at>
+   <at name="sub">0</at>
+  </object>
+ </at>
+ <at name="form">
+  <object classname="com.jeta.forms.store.memento.FormMemento">
+   <super classname="com.jeta.forms.store.memento.ComponentMemento">
+    <at name="cellconstraints">
+     <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+      <at name="column">1</at>
+      <at name="row">1</at>
+      <at name="colspan">1</at>
+      <at name="rowspan">1</at>
+      <at name="halign">default</at>
+      <at name="valign">default</at>
+      <at name="insets" object="insets">0,0,0,0</at>
+     </object>
+    </at>
+    <at name="componentclass">com.jeta.forms.gui.form.FormComponent</at>
+   </super>
+   <at name="id">/home/jose/Escritorio/JLrsCalculateMRoutePanel.xml</at>
+   <at name="rowspecs">CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE</at>
+   <at name="colspecs">FILL:DEFAULT:NONE,FILL:DEFAULT:GROW(1.0),FILL:DEFAULT:GROW(1.0),FILL:DEFAULT:NONE,FILL:DEFAULT:NONE,FILL:DEFAULT:GROW(1.0)</at>
+   <at name="components">
+    <object classname="java.util.LinkedList">
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">2</at>
+           <at name="colspan">5</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">Selecciona los campos con los PKs</at>
+            <at name="height">14</at>
+            <at name="width">989</at>
+            <at name="name">pkselectionlabel</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">4</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">Pk inicial:</at>
+            <at name="height">14</at>
+            <at name="width">323</at>
+            <at name="name">pkilabel</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">5</at>
+           <at name="row">4</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">Pk final:</at>
+            <at name="height">14</at>
+            <at name="width">45</at>
+            <at name="name">pkflabel</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">3</at>
+           <at name="row">4</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JComboBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JComboBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="height">20</at>
+            <at name="items">
+             <object classname="com.jeta.forms.store.properties.ItemsProperty">
+              <at name="name">items</at>
+             </object>
+            </at>
+            <at name="width">297</at>
+            <at name="name">pkicombo</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">6</at>
+           <at name="row">4</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JComboBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JComboBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="height">20</at>
+            <at name="items">
+             <object classname="com.jeta.forms.store.properties.ItemsProperty">
+              <at name="name">items</at>
+             </object>
+            </at>
+            <at name="width">296</at>
+            <at name="name">pkfcombo</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">6</at>
+           <at name="colspan">5</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JTable</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JTable</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="height">32</at>
+            <at name="width">987</at>
+            <at name="name">routestable</at>
+            <at name="scollBars">
+             <object classname="com.jeta.forms.store.properties.ScrollBarsProperty">
+              <at name="name">scollBars</at>
+              <at name="verticalpolicy">20</at>
+              <at name="horizontalpolicy">30</at>
+              <at name="border">
+               <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                <super classname="com.jeta.forms.store.properties.BorderProperty">
+                 <at name="name">border</at>
+                </super>
+                <at name="borders">
+                 <object classname="java.util.LinkedList">
+                  <item >
+                   <at name="value">
+                    <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                     <super classname="com.jeta.forms.store.properties.BorderProperty">
+                      <at name="name">border</at>
+                     </super>
+                    </object>
+                   </at>
+                  </item>
+                 </object>
+                </at>
+               </object>
+              </at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+    </object>
+   </at>
+   <at name="properties">
+    <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+     <at name="classname">com.jeta.forms.gui.form.GridView</at>
+     <at name="properties">
+      <object classname="com.jeta.forms.store.support.PropertyMap">
+       <at name="name"></at>
+       <at name="fill">
+        <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+         <at name="name">fill</at>
+        </object>
+       </at>
+       <at name="scollBars">
+        <object classname="com.jeta.forms.store.properties.ScrollBarsProperty">
+         <at name="name">scollBars</at>
+         <at name="verticalpolicy">21</at>
+         <at name="horizontalpolicy">31</at>
+         <at name="border">
+          <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+           <super classname="com.jeta.forms.store.properties.BorderProperty">
+            <at name="name">border</at>
+           </super>
+           <at name="borders">
+            <object classname="java.util.LinkedList">
+             <item >
+              <at name="value">
+               <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                <super classname="com.jeta.forms.store.properties.BorderProperty">
+                 <at name="name">border</at>
+                </super>
+               </object>
+              </at>
+             </item>
+            </object>
+           </at>
+          </object>
+         </at>
+        </object>
+       </at>
+       <at name="border">
+        <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+         <super classname="com.jeta.forms.store.properties.BorderProperty">
+          <at name="name">border</at>
+         </super>
+         <at name="borders">
+          <object classname="java.util.LinkedList"/>
+         </at>
+        </object>
+       </at>
+      </object>
+     </at>
+    </object>
+   </at>
+   <at name="cellpainters">
+    <object classname="com.jeta.forms.store.support.Matrix">
+     <at name="rows">
+      <object classname="[Ljava.lang.Object;" size="7">
+       <at name="item" index="0">
+        <object classname="[Ljava.lang.Object;" size="6"/>
+       </at>
+       <at name="item" index="1">
+        <object classname="[Ljava.lang.Object;" size="6"/>
+       </at>
+       <at name="item" index="2">
+        <object classname="[Ljava.lang.Object;" size="6"/>
+       </at>
+       <at name="item" index="3">
+        <object classname="[Ljava.lang.Object;" size="6"/>
+       </at>
+       <at name="item" index="4">
+        <object classname="[Ljava.lang.Object;" size="6"/>
+       </at>
+       <at name="item" index="5">
+        <object classname="[Ljava.lang.Object;" size="6"/>
+       </at>
+       <at name="item" index="6">
+        <object classname="[Ljava.lang.Object;" size="6"/>
+       </at>
+      </object>
+     </at>
+    </object>
+   </at>
+   <at name="rowgroups">
+    <object classname="com.jeta.forms.store.memento.FormGroupSet">
+     <at name="groups">
+      <object classname="java.util.HashMap"/>
+     </at>
+    </object>
+   </at>
+   <at name="colgroups">
+    <object classname="com.jeta.forms.store.memento.FormGroupSet">
+     <at name="groups">
+      <object classname="java.util.HashMap"/>
+     </at>
+    </object>
+   </at>
+  </object>
+ </at>
+</object>

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCalculateMRoutePanel.xml
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsEditRouteCalibrationParamsView.xml
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsEditRouteCalibrationParamsView.xml	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsEditRouteCalibrationParamsView.xml	(revision 950)
@@ -0,0 +1,1113 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<object classname="com.jeta.forms.store.memento.FormPackage">
+ <at name="fileversion">
+  <object classname="com.jeta.forms.store.memento.FormsVersion2">
+   <at name="major">2</at>
+   <at name="minor">0</at>
+   <at name="sub">0</at>
+  </object>
+ </at>
+ <at name="form">
+  <object classname="com.jeta.forms.store.memento.FormMemento">
+   <super classname="com.jeta.forms.store.memento.ComponentMemento">
+    <at name="cellconstraints">
+     <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+      <at name="column">1</at>
+      <at name="row">1</at>
+      <at name="colspan">1</at>
+      <at name="rowspan">1</at>
+      <at name="halign">default</at>
+      <at name="valign">default</at>
+      <at name="insets" object="insets">0,0,0,0</at>
+     </object>
+    </at>
+    <at name="componentclass">com.jeta.forms.gui.form.FormComponent</at>
+   </super>
+   <at name="id">/home/fdiaz/projects/gvSIG/org.gvsig.lrs/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsEditRouteCalibrationParamsView.xml</at>
+   <at name="rowspecs">CENTER:DEFAULT:NONE,CENTER:MAX(12DLU;DEFAULT):GROW(1.0),CENTER:2DLU:NONE,CENTER:DEFAULT:NONE,CENTER:4DLU:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE</at>
+   <at name="colspecs">FILL:DEFAULT:NONE,FILL:MAX(12DLU;DEFAULT):NONE,FILL:4DLU:NONE,FILL:120PX:NONE,FILL:4DLU:NONE,FILL:120PX:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:MAX(73PX;DEFAULT):GROW(1.0),FILL:4DLU:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:MAX(74PX;DEFAULT):GROW(1.0),FILL:DEFAULT:NONE</at>
+   <at name="components">
+    <object classname="java.util.LinkedList">
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">4</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+            <at name="name">lblIdRouteField</at>
+            <at name="width">96</at>
+            <at name="text">id_route_field</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="height">17</at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">8</at>
+           <at name="row">4</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+            <at name="name">lblMinimum</at>
+            <at name="width">63</at>
+            <at name="text">minimum</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="height">17</at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">12</at>
+           <at name="row">4</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+            <at name="name">lblMaximum</at>
+            <at name="width">67</at>
+            <at name="text">maximum</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="height">17</at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">2</at>
+           <at name="colspan">13</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">fill</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JTable</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JTable</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+            <at name="name">tblLayerInfo</at>
+            <at name="width">1146</at>
+            <at name="scollBars">
+             <object classname="com.jeta.forms.store.properties.ScrollBarsProperty">
+              <at name="name">scollBars</at>
+              <at name="verticalpolicy">20</at>
+              <at name="horizontalpolicy">30</at>
+              <at name="border">
+               <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                <super classname="com.jeta.forms.store.properties.BorderProperty">
+                 <at name="name">border</at>
+                </super>
+                <at name="borders">
+                 <object classname="java.util.LinkedList">
+                  <item >
+                   <at name="value">
+                    <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                     <super classname="com.jeta.forms.store.properties.BorderProperty">
+                      <at name="name">border</at>
+                     </super>
+                    </object>
+                   </at>
+                  </item>
+                 </object>
+                </at>
+               </object>
+              </at>
+             </object>
+            </at>
+            <at name="height">36</at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.FormMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">6</at>
+           <at name="colspan">13</at>
+           <at name="rowspan">1</at>
+           <at name="halign">right</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.FormComponent</at>
+        </super>
+        <at name="id">embedded.1851845979</at>
+        <at name="rowspecs">CENTER:DEFAULT:NONE</at>
+        <at name="colspecs">FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE,FILL:DEFAULT:NONE,FILL:DEFAULT:NONE</at>
+        <at name="components">
+         <object classname="java.util.LinkedList">
+          <item >
+           <at name="value">
+            <object classname="com.jeta.forms.store.memento.BeanMemento">
+             <super classname="com.jeta.forms.store.memento.ComponentMemento">
+              <at name="cellconstraints">
+               <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+                <at name="column">1</at>
+                <at name="row">1</at>
+                <at name="colspan">1</at>
+                <at name="rowspan">1</at>
+                <at name="halign">center</at>
+                <at name="valign">default</at>
+                <at name="insets" object="insets">0,0,0,0</at>
+               </object>
+              </at>
+              <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+             </super>
+             <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+             <at name="beanclass">javax.swing.JButton</at>
+             <at name="beanproperties">
+              <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+               <at name="classname">javax.swing.JButton</at>
+               <at name="properties">
+                <object classname="com.jeta.forms.store.support.PropertyMap">
+                 <at name="border">
+                  <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                   <at name="borders">
+                    <object classname="java.util.LinkedList">
+                     <item >
+                      <at name="value">
+                       <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                        <super classname="com.jeta.forms.store.properties.BorderProperty">
+                         <at name="name">border</at>
+                        </super>
+                       </object>
+                      </at>
+                     </item>
+                    </object>
+                   </at>
+                  </object>
+                 </at>
+                 <at name="actionCommand">_Invert</at>
+                 <at name="name">btnInvert</at>
+                 <at name="width">53</at>
+                 <at name="text">_Invert</at>
+                 <at name="height">22</at>
+                </object>
+               </at>
+              </object>
+             </at>
+            </object>
+           </at>
+          </item>
+          <item >
+           <at name="value">
+            <object classname="com.jeta.forms.store.memento.BeanMemento">
+             <super classname="com.jeta.forms.store.memento.ComponentMemento">
+              <at name="cellconstraints">
+               <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+                <at name="column">5</at>
+                <at name="row">1</at>
+                <at name="colspan">1</at>
+                <at name="rowspan">1</at>
+                <at name="halign">default</at>
+                <at name="valign">default</at>
+                <at name="insets" object="insets">0,0,0,0</at>
+               </object>
+              </at>
+              <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+             </super>
+             <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+             <at name="beanclass">javax.swing.JButton</at>
+             <at name="beanproperties">
+              <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+               <at name="classname">javax.swing.JButton</at>
+               <at name="properties">
+                <object classname="com.jeta.forms.store.support.PropertyMap">
+                 <at name="border">
+                  <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                   <at name="borders">
+                    <object classname="java.util.LinkedList">
+                     <item >
+                      <at name="value">
+                       <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                        <super classname="com.jeta.forms.store.properties.BorderProperty">
+                         <at name="name">border</at>
+                        </super>
+                       </object>
+                      </at>
+                     </item>
+                    </object>
+                   </at>
+                  </object>
+                 </at>
+                 <at name="actionCommand">_Apply</at>
+                 <at name="name">btnRecalibrate</at>
+                 <at name="width">91</at>
+                 <at name="foreground" object="color">63,63,63</at>
+                 <at name="text">_Recalibrate</at>
+                 <at name="height">22</at>
+                </object>
+               </at>
+              </object>
+             </at>
+            </object>
+           </at>
+          </item>
+          <item >
+           <at name="value">
+            <object classname="com.jeta.forms.store.memento.BeanMemento">
+             <super classname="com.jeta.forms.store.memento.ComponentMemento">
+              <at name="cellconstraints">
+               <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+                <at name="column">3</at>
+                <at name="row">1</at>
+                <at name="colspan">1</at>
+                <at name="rowspan">1</at>
+                <at name="halign">default</at>
+                <at name="valign">default</at>
+                <at name="insets" object="insets">0,0,0,0</at>
+               </object>
+              </at>
+              <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+             </super>
+             <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+             <at name="beanclass">javax.swing.JButton</at>
+             <at name="beanproperties">
+              <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+               <at name="classname">javax.swing.JButton</at>
+               <at name="properties">
+                <object classname="com.jeta.forms.store.support.PropertyMap">
+                 <at name="border">
+                  <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                   <at name="borders">
+                    <object classname="java.util.LinkedList">
+                     <item >
+                      <at name="value">
+                       <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                        <super classname="com.jeta.forms.store.properties.BorderProperty">
+                         <at name="name">border</at>
+                        </super>
+                       </object>
+                      </at>
+                     </item>
+                    </object>
+                   </at>
+                  </object>
+                 </at>
+                 <at name="actionCommand">_Apply</at>
+                 <at name="name">btnApply</at>
+                 <at name="width">199</at>
+                 <at name="text">_Recalculate_proportionally</at>
+                 <at name="height">22</at>
+                </object>
+               </at>
+              </object>
+             </at>
+            </object>
+           </at>
+          </item>
+         </object>
+        </at>
+        <at name="properties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.gui.form.GridView</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList"/>
+              </at>
+             </object>
+            </at>
+            <at name="name"/>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="scollBars">
+             <object classname="com.jeta.forms.store.properties.ScrollBarsProperty">
+              <at name="name">scollBars</at>
+              <at name="verticalpolicy">21</at>
+              <at name="horizontalpolicy">31</at>
+              <at name="border">
+               <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                <super classname="com.jeta.forms.store.properties.BorderProperty">
+                 <at name="name">border</at>
+                </super>
+                <at name="borders">
+                 <object classname="java.util.LinkedList">
+                  <item >
+                   <at name="value">
+                    <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                     <super classname="com.jeta.forms.store.properties.BorderProperty">
+                      <at name="name">border</at>
+                     </super>
+                    </object>
+                   </at>
+                  </item>
+                 </object>
+                </at>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+        <at name="cellpainters">
+         <object classname="com.jeta.forms.store.support.Matrix">
+          <at name="rows">
+           <object classname="[Ljava.lang.Object;" size="1">
+            <at name="item" index="0">
+             <object classname="[Ljava.lang.Object;" size="5"/>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+        <at name="rowgroups">
+         <object classname="com.jeta.forms.store.memento.FormGroupSet">
+          <at name="groups">
+           <object classname="java.util.HashMap"/>
+          </at>
+         </object>
+        </at>
+        <at name="colgroups">
+         <object classname="com.jeta.forms.store.memento.FormGroupSet">
+          <at name="groups">
+           <object classname="java.util.HashMap"/>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.FormMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">8</at>
+           <at name="colspan">13</at>
+           <at name="rowspan">1</at>
+           <at name="halign">right</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.FormComponent</at>
+        </super>
+        <at name="id">embedded.1394303138</at>
+        <at name="rowspecs">CENTER:DEFAULT:NONE</at>
+        <at name="colspecs">FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE</at>
+        <at name="components">
+         <object classname="java.util.LinkedList">
+          <item >
+           <at name="value">
+            <object classname="com.jeta.forms.store.memento.BeanMemento">
+             <super classname="com.jeta.forms.store.memento.ComponentMemento">
+              <at name="cellconstraints">
+               <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+                <at name="column">1</at>
+                <at name="row">1</at>
+                <at name="colspan">1</at>
+                <at name="rowspan">1</at>
+                <at name="halign">center</at>
+                <at name="valign">default</at>
+                <at name="insets" object="insets">0,0,0,0</at>
+               </object>
+              </at>
+              <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+             </super>
+             <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+             <at name="beanclass">javax.swing.JButton</at>
+             <at name="beanproperties">
+              <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+               <at name="classname">javax.swing.JButton</at>
+               <at name="properties">
+                <object classname="com.jeta.forms.store.support.PropertyMap">
+                 <at name="border">
+                  <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                   <at name="borders">
+                    <object classname="java.util.LinkedList">
+                     <item >
+                      <at name="value">
+                       <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                        <super classname="com.jeta.forms.store.properties.BorderProperty">
+                         <at name="name">border</at>
+                        </super>
+                       </object>
+                      </at>
+                     </item>
+                    </object>
+                   </at>
+                  </object>
+                 </at>
+                 <at name="actionCommand">_Accept</at>
+                 <at name="name">btnAccept</at>
+                 <at name="width">62</at>
+                 <at name="text">_Accept</at>
+                 <at name="height">22</at>
+                </object>
+               </at>
+              </object>
+             </at>
+            </object>
+           </at>
+          </item>
+          <item >
+           <at name="value">
+            <object classname="com.jeta.forms.store.memento.BeanMemento">
+             <super classname="com.jeta.forms.store.memento.ComponentMemento">
+              <at name="cellconstraints">
+               <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+                <at name="column">3</at>
+                <at name="row">1</at>
+                <at name="colspan">1</at>
+                <at name="rowspan">1</at>
+                <at name="halign">default</at>
+                <at name="valign">default</at>
+                <at name="insets" object="insets">0,0,0,0</at>
+               </object>
+              </at>
+              <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+             </super>
+             <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+             <at name="beanclass">javax.swing.JButton</at>
+             <at name="beanproperties">
+              <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+               <at name="classname">javax.swing.JButton</at>
+               <at name="properties">
+                <object classname="com.jeta.forms.store.support.PropertyMap">
+                 <at name="border">
+                  <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                   <at name="borders">
+                    <object classname="java.util.LinkedList">
+                     <item >
+                      <at name="value">
+                       <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                        <super classname="com.jeta.forms.store.properties.BorderProperty">
+                         <at name="name">border</at>
+                        </super>
+                       </object>
+                      </at>
+                     </item>
+                    </object>
+                   </at>
+                  </object>
+                 </at>
+                 <at name="actionCommand">_Cancel</at>
+                 <at name="name">btnCancel</at>
+                 <at name="width">61</at>
+                 <at name="text">_Cancel</at>
+                 <at name="height">22</at>
+                </object>
+               </at>
+              </object>
+             </at>
+            </object>
+           </at>
+          </item>
+         </object>
+        </at>
+        <at name="properties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.gui.form.GridView</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList"/>
+              </at>
+             </object>
+            </at>
+            <at name="name"/>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="scollBars">
+             <object classname="com.jeta.forms.store.properties.ScrollBarsProperty">
+              <at name="name">scollBars</at>
+              <at name="verticalpolicy">21</at>
+              <at name="horizontalpolicy">31</at>
+              <at name="border">
+               <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                <super classname="com.jeta.forms.store.properties.BorderProperty">
+                 <at name="name">border</at>
+                </super>
+                <at name="borders">
+                 <object classname="java.util.LinkedList">
+                  <item >
+                   <at name="value">
+                    <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                     <super classname="com.jeta.forms.store.properties.BorderProperty">
+                      <at name="name">border</at>
+                     </super>
+                    </object>
+                   </at>
+                  </item>
+                 </object>
+                </at>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+        <at name="cellpainters">
+         <object classname="com.jeta.forms.store.support.Matrix">
+          <at name="rows">
+           <object classname="[Ljava.lang.Object;" size="1">
+            <at name="item" index="0">
+             <object classname="[Ljava.lang.Object;" size="3"/>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+        <at name="rowgroups">
+         <object classname="com.jeta.forms.store.memento.FormGroupSet">
+          <at name="groups">
+           <object classname="java.util.HashMap"/>
+          </at>
+         </object>
+        </at>
+        <at name="colgroups">
+         <object classname="com.jeta.forms.store.memento.FormGroupSet">
+          <at name="groups">
+           <object classname="java.util.HashMap"/>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">4</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JComboBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JComboBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+            <at name="name">cmbRoute</at>
+            <at name="width">116</at>
+            <at name="items">
+             <object classname="com.jeta.forms.store.properties.ItemsProperty">
+              <at name="name">items</at>
+             </object>
+            </at>
+            <at name="height">23</at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">14</at>
+           <at name="row">4</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JTextField</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JTextField</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+            <at name="name">txtMaximum</at>
+            <at name="width">309</at>
+            <at name="height">21</at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">10</at>
+           <at name="row">4</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JTextField</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JTextField</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+            <at name="name">txtMinimum</at>
+            <at name="width">309</at>
+            <at name="height">21</at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">6</at>
+           <at name="row">4</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JComboBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JComboBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+            <at name="name">cmbStretch</at>
+            <at name="width">116</at>
+            <at name="items">
+             <object classname="com.jeta.forms.store.properties.ItemsProperty">
+              <at name="name">items</at>
+             </object>
+            </at>
+            <at name="height">23</at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+    </object>
+   </at>
+   <at name="properties">
+    <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+     <at name="classname">com.jeta.forms.gui.form.GridView</at>
+     <at name="properties">
+      <object classname="com.jeta.forms.store.support.PropertyMap">
+       <at name="border">
+        <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+         <super classname="com.jeta.forms.store.properties.BorderProperty">
+          <at name="name">border</at>
+         </super>
+         <at name="borders">
+          <object classname="java.util.LinkedList"/>
+         </at>
+        </object>
+       </at>
+       <at name="name"/>
+       <at name="fill">
+        <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+         <at name="name">fill</at>
+        </object>
+       </at>
+       <at name="scollBars">
+        <object classname="com.jeta.forms.store.properties.ScrollBarsProperty">
+         <at name="name">scollBars</at>
+         <at name="verticalpolicy">21</at>
+         <at name="horizontalpolicy">31</at>
+         <at name="border">
+          <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+           <super classname="com.jeta.forms.store.properties.BorderProperty">
+            <at name="name">border</at>
+           </super>
+           <at name="borders">
+            <object classname="java.util.LinkedList">
+             <item >
+              <at name="value">
+               <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                <super classname="com.jeta.forms.store.properties.BorderProperty">
+                 <at name="name">border</at>
+                </super>
+               </object>
+              </at>
+             </item>
+            </object>
+           </at>
+          </object>
+         </at>
+        </object>
+       </at>
+      </object>
+     </at>
+    </object>
+   </at>
+   <at name="cellpainters">
+    <object classname="com.jeta.forms.store.support.Matrix">
+     <at name="rows">
+      <object classname="[Ljava.lang.Object;" size="9">
+       <at name="item" index="0">
+        <object classname="[Ljava.lang.Object;" size="15"/>
+       </at>
+       <at name="item" index="1">
+        <object classname="[Ljava.lang.Object;" size="15"/>
+       </at>
+       <at name="item" index="2">
+        <object classname="[Ljava.lang.Object;" size="15"/>
+       </at>
+       <at name="item" index="3">
+        <object classname="[Ljava.lang.Object;" size="15"/>
+       </at>
+       <at name="item" index="4">
+        <object classname="[Ljava.lang.Object;" size="15"/>
+       </at>
+       <at name="item" index="5">
+        <object classname="[Ljava.lang.Object;" size="15"/>
+       </at>
+       <at name="item" index="6">
+        <object classname="[Ljava.lang.Object;" size="15"/>
+       </at>
+       <at name="item" index="7">
+        <object classname="[Ljava.lang.Object;" size="15"/>
+       </at>
+       <at name="item" index="8">
+        <object classname="[Ljava.lang.Object;" size="15"/>
+       </at>
+      </object>
+     </at>
+    </object>
+   </at>
+   <at name="rowgroups">
+    <object classname="com.jeta.forms.store.memento.FormGroupSet">
+     <at name="groups">
+      <object classname="java.util.HashMap"/>
+     </at>
+    </object>
+   </at>
+   <at name="colgroups">
+    <object classname="com.jeta.forms.store.memento.FormGroupSet">
+     <at name="groups">
+      <object classname="java.util.HashMap"/>
+     </at>
+    </object>
+   </at>
+  </object>
+ </at>
+</object>
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsGenerateDynamicSegmentationParamsView.xml
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsGenerateDynamicSegmentationParamsView.xml	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsGenerateDynamicSegmentationParamsView.xml	(revision 950)
@@ -0,0 +1,1475 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<object classname="com.jeta.forms.store.memento.FormPackage">
+ <at name="fileversion">
+  <object classname="com.jeta.forms.store.memento.FormsVersion2">
+   <at name="major">2</at>
+   <at name="minor">0</at>
+   <at name="sub">0</at>
+  </object>
+ </at>
+ <at name="form">
+  <object classname="com.jeta.forms.store.memento.FormMemento">
+   <super classname="com.jeta.forms.store.memento.ComponentMemento">
+    <at name="cellconstraints">
+     <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+      <at name="column">1</at>
+      <at name="row">1</at>
+      <at name="colspan">1</at>
+      <at name="rowspan">1</at>
+      <at name="halign">default</at>
+      <at name="valign">default</at>
+      <at name="insets" object="insets">0,0,0,0</at>
+     </object>
+    </at>
+    <at name="componentclass">com.jeta.forms.gui.form.FormComponent</at>
+   </super>
+   <at name="id">/home/daniel/tmp/abeille/JLrsGenerateDynamicSegmentationParamsView.xml</at>
+   <at name="rowspecs">CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:GROW(1.0),CENTER:2DLU:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE</at>
+   <at name="colspecs">FILL:DEFAULT:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:256PX:GROW(1.0),FILL:DEFAULT:NONE</at>
+   <at name="components">
+    <object classname="java.util.LinkedList">
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">2</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">source</at>
+            <at name="height">14</at>
+            <at name="width">113</at>
+            <at name="name">lblInputLayer</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">2</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JComboBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JComboBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="height">20</at>
+            <at name="items">
+             <object classname="com.jeta.forms.store.properties.ItemsProperty">
+              <at name="name">items</at>
+             </object>
+            </at>
+            <at name="width">790</at>
+            <at name="name">cmbInputLayer</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">3</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">id_route_field</at>
+            <at name="height">14</at>
+            <at name="width">113</at>
+            <at name="name">lblIdRouteField</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">3</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JComboBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JComboBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="height">20</at>
+            <at name="items">
+             <object classname="com.jeta.forms.store.properties.ItemsProperty">
+              <at name="name">items</at>
+             </object>
+            </at>
+            <at name="width">790</at>
+            <at name="name">cmbIdRouteField</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">4</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">table</at>
+            <at name="height">14</at>
+            <at name="width">113</at>
+            <at name="name">lblTable</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">4</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JComboBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JComboBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="height">20</at>
+            <at name="items">
+             <object classname="com.jeta.forms.store.properties.ItemsProperty">
+              <at name="name">items</at>
+             </object>
+            </at>
+            <at name="width">790</at>
+            <at name="name">cmbTable</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">5</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">table_id_route_field</at>
+            <at name="height">14</at>
+            <at name="width">113</at>
+            <at name="name">lblTableIdRouteField</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">5</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JComboBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JComboBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="height">20</at>
+            <at name="items">
+             <object classname="com.jeta.forms.store.properties.ItemsProperty">
+              <at name="name">items</at>
+             </object>
+            </at>
+            <at name="width">790</at>
+            <at name="name">cmbTableIdRouteField</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">6</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">landmark_field</at>
+            <at name="height">14</at>
+            <at name="width">113</at>
+            <at name="name">lblLandmarkField</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">6</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JComboBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JComboBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="height">20</at>
+            <at name="items">
+             <object classname="com.jeta.forms.store.properties.ItemsProperty">
+              <at name="name">items</at>
+             </object>
+            </at>
+            <at name="width">790</at>
+            <at name="name">cmbLandmarkField</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">7</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">final_landmark_field</at>
+            <at name="height">14</at>
+            <at name="width">113</at>
+            <at name="name">lblFinalLandmarkField</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">8</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">value_field</at>
+            <at name="height">14</at>
+            <at name="width">113</at>
+            <at name="name">lblValueField</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">7</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JComboBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JComboBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="height">20</at>
+            <at name="items">
+             <object classname="com.jeta.forms.store.properties.ItemsProperty">
+              <at name="name">items</at>
+             </object>
+            </at>
+            <at name="width">790</at>
+            <at name="name">cmbFinalLandmarkField</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">8</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JComboBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JComboBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="height">20</at>
+            <at name="items">
+             <object classname="com.jeta.forms.store.properties.ItemsProperty">
+              <at name="name">items</at>
+             </object>
+            </at>
+            <at name="width">790</at>
+            <at name="name">cmbValueField</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">9</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">output_file</at>
+            <at name="height">14</at>
+            <at name="width">113</at>
+            <at name="name">lblOutputFile</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.FormMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">9</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.FormComponent</at>
+        </super>
+        <at name="id">embedded.2042752145</at>
+        <at name="rowspecs">CENTER:DEFAULT:NONE</at>
+        <at name="colspecs">FILL:DEFAULT:GROW(1.0),FILL:36PX:NONE</at>
+        <at name="components">
+         <object classname="java.util.LinkedList">
+          <item >
+           <at name="value">
+            <object classname="com.jeta.forms.store.memento.BeanMemento">
+             <super classname="com.jeta.forms.store.memento.ComponentMemento">
+              <at name="cellconstraints">
+               <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+                <at name="column">1</at>
+                <at name="row">1</at>
+                <at name="colspan">1</at>
+                <at name="rowspan">1</at>
+                <at name="halign">default</at>
+                <at name="valign">default</at>
+                <at name="insets" object="insets">0,0,0,0</at>
+               </object>
+              </at>
+              <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+             </super>
+             <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+             <at name="beanclass">javax.swing.JTextField</at>
+             <at name="beanproperties">
+              <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+               <at name="classname">javax.swing.JTextField</at>
+               <at name="properties">
+                <object classname="com.jeta.forms.store.support.PropertyMap">
+                 <at name="horizontalAlignment">2</at>
+                 <at name="height">20</at>
+                 <at name="width">749</at>
+                 <at name="name">txtOutputFile</at>
+                 <at name="border">
+                  <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                   <at name="borders">
+                    <object classname="java.util.LinkedList">
+                     <item >
+                      <at name="value">
+                       <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                        <super classname="com.jeta.forms.store.properties.BorderProperty">
+                         <at name="name">border</at>
+                        </super>
+                       </object>
+                      </at>
+                     </item>
+                    </object>
+                   </at>
+                  </object>
+                 </at>
+                </object>
+               </at>
+              </object>
+             </at>
+            </object>
+           </at>
+          </item>
+          <item >
+           <at name="value">
+            <object classname="com.jeta.forms.store.memento.BeanMemento">
+             <super classname="com.jeta.forms.store.memento.ComponentMemento">
+              <at name="cellconstraints">
+               <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+                <at name="column">2</at>
+                <at name="row">1</at>
+                <at name="colspan">1</at>
+                <at name="rowspan">1</at>
+                <at name="halign">default</at>
+                <at name="valign">default</at>
+                <at name="insets" object="insets">0,0,0,0</at>
+               </object>
+              </at>
+              <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+             </super>
+             <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+             <at name="beanclass">javax.swing.JButton</at>
+             <at name="beanproperties">
+              <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+               <at name="classname">javax.swing.JButton</at>
+               <at name="properties">
+                <object classname="com.jeta.forms.store.support.PropertyMap">
+                 <at name="text">...</at>
+                 <at name="height">22</at>
+                 <at name="opaque">false</at>
+                 <at name="width">32</at>
+                 <at name="name">btnBrowser</at>
+                 <at name="actionCommand">JButton</at>
+                 <at name="border">
+                  <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                   <at name="borders">
+                    <object classname="java.util.LinkedList">
+                     <item >
+                      <at name="value">
+                       <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                        <super classname="com.jeta.forms.store.properties.BorderProperty">
+                         <at name="name">border</at>
+                        </super>
+                       </object>
+                      </at>
+                     </item>
+                    </object>
+                   </at>
+                  </object>
+                 </at>
+                 <at name="rolloverEnabled">true</at>
+                </object>
+               </at>
+              </object>
+             </at>
+            </object>
+           </at>
+          </item>
+         </object>
+        </at>
+        <at name="properties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.gui.form.GridView</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="name"></at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="scollBars">
+             <object classname="com.jeta.forms.store.properties.ScrollBarsProperty">
+              <at name="name">scollBars</at>
+              <at name="verticalpolicy">21</at>
+              <at name="horizontalpolicy">31</at>
+              <at name="border">
+               <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                <super classname="com.jeta.forms.store.properties.BorderProperty">
+                 <at name="name">border</at>
+                </super>
+                <at name="borders">
+                 <object classname="java.util.LinkedList">
+                  <item >
+                   <at name="value">
+                    <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                     <super classname="com.jeta.forms.store.properties.BorderProperty">
+                      <at name="name">border</at>
+                     </super>
+                    </object>
+                   </at>
+                  </item>
+                 </object>
+                </at>
+               </object>
+              </at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList"/>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+        <at name="cellpainters">
+         <object classname="com.jeta.forms.store.support.Matrix">
+          <at name="rows">
+           <object classname="[Ljava.lang.Object;" size="1">
+            <at name="item" index="0">
+             <object classname="[Ljava.lang.Object;" size="2"/>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+        <at name="rowgroups">
+         <object classname="com.jeta.forms.store.memento.FormGroupSet">
+          <at name="groups">
+           <object classname="java.util.HashMap"/>
+          </at>
+         </object>
+        </at>
+        <at name="colgroups">
+         <object classname="com.jeta.forms.store.memento.FormGroupSet">
+          <at name="groups">
+           <object classname="java.util.HashMap"/>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.FormMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">12</at>
+           <at name="colspan">3</at>
+           <at name="rowspan">1</at>
+           <at name="halign">right</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.FormComponent</at>
+        </super>
+        <at name="id">embedded.1704922939</at>
+        <at name="rowspecs">CENTER:DEFAULT:NONE</at>
+        <at name="colspecs">FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE</at>
+        <at name="components">
+         <object classname="java.util.LinkedList">
+          <item >
+           <at name="value">
+            <object classname="com.jeta.forms.store.memento.BeanMemento">
+             <super classname="com.jeta.forms.store.memento.ComponentMemento">
+              <at name="cellconstraints">
+               <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+                <at name="column">1</at>
+                <at name="row">1</at>
+                <at name="colspan">1</at>
+                <at name="rowspan">1</at>
+                <at name="halign">default</at>
+                <at name="valign">default</at>
+                <at name="insets" object="insets">0,0,0,0</at>
+               </object>
+              </at>
+              <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+             </super>
+             <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+             <at name="beanclass">javax.swing.JButton</at>
+             <at name="beanproperties">
+              <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+               <at name="classname">javax.swing.JButton</at>
+               <at name="properties">
+                <object classname="com.jeta.forms.store.support.PropertyMap">
+                 <at name="text">_Accept</at>
+                 <at name="height">22</at>
+                 <at name="width">75</at>
+                 <at name="name">btnAccept</at>
+                 <at name="actionCommand">_Accept</at>
+                 <at name="border">
+                  <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                   <at name="borders">
+                    <object classname="java.util.LinkedList">
+                     <item >
+                      <at name="value">
+                       <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                        <super classname="com.jeta.forms.store.properties.BorderProperty">
+                         <at name="name">border</at>
+                        </super>
+                       </object>
+                      </at>
+                     </item>
+                    </object>
+                   </at>
+                  </object>
+                 </at>
+                </object>
+               </at>
+              </object>
+             </at>
+            </object>
+           </at>
+          </item>
+          <item >
+           <at name="value">
+            <object classname="com.jeta.forms.store.memento.BeanMemento">
+             <super classname="com.jeta.forms.store.memento.ComponentMemento">
+              <at name="cellconstraints">
+               <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+                <at name="column">3</at>
+                <at name="row">1</at>
+                <at name="colspan">1</at>
+                <at name="rowspan">1</at>
+                <at name="halign">default</at>
+                <at name="valign">default</at>
+                <at name="insets" object="insets">0,0,0,0</at>
+               </object>
+              </at>
+              <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+             </super>
+             <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+             <at name="beanclass">javax.swing.JButton</at>
+             <at name="beanproperties">
+              <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+               <at name="classname">javax.swing.JButton</at>
+               <at name="properties">
+                <object classname="com.jeta.forms.store.support.PropertyMap">
+                 <at name="text">_Cancel</at>
+                 <at name="height">22</at>
+                 <at name="width">76</at>
+                 <at name="name">btnCancel</at>
+                 <at name="actionCommand">_Cancel</at>
+                 <at name="border">
+                  <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                   <at name="borders">
+                    <object classname="java.util.LinkedList">
+                     <item >
+                      <at name="value">
+                       <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                        <super classname="com.jeta.forms.store.properties.BorderProperty">
+                         <at name="name">border</at>
+                        </super>
+                       </object>
+                      </at>
+                     </item>
+                    </object>
+                   </at>
+                  </object>
+                 </at>
+                </object>
+               </at>
+              </object>
+             </at>
+            </object>
+           </at>
+          </item>
+         </object>
+        </at>
+        <at name="properties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.gui.form.GridView</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="name"></at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="scollBars">
+             <object classname="com.jeta.forms.store.properties.ScrollBarsProperty">
+              <at name="name">scollBars</at>
+              <at name="verticalpolicy">21</at>
+              <at name="horizontalpolicy">31</at>
+              <at name="border">
+               <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                <super classname="com.jeta.forms.store.properties.BorderProperty">
+                 <at name="name">border</at>
+                </super>
+                <at name="borders">
+                 <object classname="java.util.LinkedList">
+                  <item >
+                   <at name="value">
+                    <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                     <super classname="com.jeta.forms.store.properties.BorderProperty">
+                      <at name="name">border</at>
+                     </super>
+                    </object>
+                   </at>
+                  </item>
+                 </object>
+                </at>
+               </object>
+              </at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList"/>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+        <at name="cellpainters">
+         <object classname="com.jeta.forms.store.support.Matrix">
+          <at name="rows">
+           <object classname="[Ljava.lang.Object;" size="1">
+            <at name="item" index="0">
+             <object classname="[Ljava.lang.Object;" size="3"/>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+        <at name="rowgroups">
+         <object classname="com.jeta.forms.store.memento.FormGroupSet">
+          <at name="groups">
+           <object classname="java.util.HashMap"/>
+          </at>
+         </object>
+        </at>
+        <at name="colgroups">
+         <object classname="com.jeta.forms.store.memento.FormGroupSet">
+          <at name="groups">
+           <object classname="java.util.HashMap"/>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+    </object>
+   </at>
+   <at name="properties">
+    <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+     <at name="classname">com.jeta.forms.gui.form.GridView</at>
+     <at name="properties">
+      <object classname="com.jeta.forms.store.support.PropertyMap">
+       <at name="name"></at>
+       <at name="fill">
+        <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+         <at name="name">fill</at>
+        </object>
+       </at>
+       <at name="scollBars">
+        <object classname="com.jeta.forms.store.properties.ScrollBarsProperty">
+         <at name="name">scollBars</at>
+         <at name="verticalpolicy">21</at>
+         <at name="horizontalpolicy">31</at>
+         <at name="border">
+          <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+           <super classname="com.jeta.forms.store.properties.BorderProperty">
+            <at name="name">border</at>
+           </super>
+           <at name="borders">
+            <object classname="java.util.LinkedList">
+             <item >
+              <at name="value">
+               <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                <super classname="com.jeta.forms.store.properties.BorderProperty">
+                 <at name="name">border</at>
+                </super>
+               </object>
+              </at>
+             </item>
+            </object>
+           </at>
+          </object>
+         </at>
+        </object>
+       </at>
+       <at name="border">
+        <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+         <super classname="com.jeta.forms.store.properties.BorderProperty">
+          <at name="name">border</at>
+         </super>
+         <at name="borders">
+          <object classname="java.util.LinkedList"/>
+         </at>
+        </object>
+       </at>
+      </object>
+     </at>
+    </object>
+   </at>
+   <at name="cellpainters">
+    <object classname="com.jeta.forms.store.support.Matrix">
+     <at name="rows">
+      <object classname="[Ljava.lang.Object;" size="13">
+       <at name="item" index="0">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="1">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="2">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="3">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="4">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="5">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="6">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="7">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="8">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="9">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="10">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="11">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="12">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+      </object>
+     </at>
+    </object>
+   </at>
+   <at name="rowgroups">
+    <object classname="com.jeta.forms.store.memento.FormGroupSet">
+     <at name="groups">
+      <object classname="java.util.HashMap"/>
+     </at>
+    </object>
+   </at>
+   <at name="colgroups">
+    <object classname="com.jeta.forms.store.memento.FormGroupSet">
+     <at name="groups">
+      <object classname="java.util.HashMap"/>
+     </at>
+    </object>
+   </at>
+  </object>
+ </at>
+</object>
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsShowMeasuresParamsController.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsShowMeasuresParamsController.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsShowMeasuresParamsController.java	(revision 950)
@@ -0,0 +1,223 @@
+/*
+ * Copyright 2015 DiSiD Technologies S.L.L. All rights reserved.
+ *
+ * Project  : DiSiD org.gvsig.lrs.swing.impl
+ * SVN Id   : $Id$
+ */
+package org.gvsig.lrs.swing.impl;
+
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.util.Locale;
+import javax.swing.JComponent;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.lrs.lib.api.LrsAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsAlgorithmsLocator;
+import org.gvsig.lrs.lib.api.LrsAlgorithmsManager;
+import org.gvsig.lrs.lib.api.LrsShowMeasuresAlgorithmParams;
+import static org.gvsig.lrs.lib.api.LrsShowMeasuresAlgorithmParams.LRS_SHOWMEASURES_KILOMETER;
+import static org.gvsig.lrs.lib.api.LrsShowMeasuresAlgorithmParams.LRS_SHOWMEASURES_KILOMETER_LABEL;
+import static org.gvsig.lrs.lib.api.LrsShowMeasuresAlgorithmParams.LRS_SHOWMEASURES_METER;
+import static org.gvsig.lrs.lib.api.LrsShowMeasuresAlgorithmParams.LRS_SHOWMEASURES_METER_LABEL;
+import static org.gvsig.lrs.lib.api.LrsShowMeasuresAlgorithmParams.LRS_SHOWMEASURES_UNKNOWN_OTHER;
+import static org.gvsig.lrs.lib.api.LrsShowMeasuresAlgorithmParams.LRS_SHOWMEASURES_UNKNOWN_OTHER_LABEL;
+import org.gvsig.lrs.lib.api.exceptions.LrsGettingParametersException;
+import org.gvsig.lrs.lib.api.exceptions.LrsNeededParameterException;
+import org.gvsig.lrs.swing.api.JLrsAlgorithmParams;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.i18n.I18nManager;
+import org.gvsig.tools.swing.api.ActionListenerSupport;
+import org.gvsig.tools.swing.api.ToolsSwingLocator;
+import org.gvsig.tools.swing.api.ToolsSwingManager;
+import org.gvsig.tools.swing.api.ToolsSwingUtils;
+import org.gvsig.tools.util.LabeledValue;
+import org.gvsig.tools.util.LabeledValueImpl;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public final class JLrsShowMeasuresParamsController extends JLrsShowMeasuresParamsView  implements JLrsAlgorithmParams{
+
+    /**
+     *
+     */
+    private static final Logger logger = LoggerFactory.getLogger(JLrsShowMeasuresParamsController.class);
+
+    private boolean canceled;
+    private final ActionListenerSupport listeners = ToolsSwingLocator.getToolsSwingManager().createActionListenerSupport();
+
+    private final FLayer layer;
+
+    /**
+     * @param layer
+     * @param params
+     * @param layers
+     * @throws LrsNeededParameterException
+     *
+     */
+    public JLrsShowMeasuresParamsController(FLayer layer, LrsAlgorithmParams params) throws LrsNeededParameterException {
+        super();
+        this.layer = layer;
+        initComponents();
+        translate();
+        setParams(params);
+    }
+
+    @Override
+    public void addActionListener(ActionListener listener) {
+        listeners.addActionListener(listener);
+    }
+
+    @Override
+    public void removeActionListener(ActionListener listener) {
+        listeners.removeActionListener(listener);
+    }
+
+    private void translate() {
+        ToolsSwingManager toolsSwingManager = ToolsSwingLocator.getToolsSwingManager();
+        toolsSwingManager.translate(lblDistance);
+        toolsSwingManager.translate(txtDistance);
+        toolsSwingManager.translate(lblUnits);
+        toolsSwingManager.translate(cboUnits);
+
+        toolsSwingManager.translate(btnAccept);
+        toolsSwingManager.translate(btnCancel);
+    }
+
+    /**
+     *
+     * @param locale
+     */
+    public void setLocate(Locale locale) {
+        Locale l = super.getLocale();
+        if (!l.equals(locale)) {
+            translate();
+        }
+        super.setLocale(locale);
+    }
+
+    /**
+     *  Validates one curve M-layer with selected features
+     *  if it is not correct throws an exception
+     * @param layer
+     * @throws LrsNeededParameterException
+     */
+    public static void validateLayer(FLayer layer)throws LrsNeededParameterException {
+        logger.debug("Validating layer for Show Measures");
+        if (layer==null){
+            logger.error("At least a layer is needed");
+            throw new LrsNeededParameterException("at_least_one_layer_needed", null);
+        }
+
+        if (!JLrsUtils.hasMLayersWithSelectedFeatures(layer)){
+            logger.error("Impossible to find the layer needed");
+            throw new LrsNeededParameterException("impossible_to_find_needed_layer",null);
+        }
+
+
+    }
+
+    /**
+     * @throws LrsNeededParameterException
+     */
+    private void initComponents() throws LrsNeededParameterException {
+
+        validateLayer(layer);
+
+        txtDistance.setText(Double.toString(0d));
+
+        this.btnAccept.addActionListener((ActionEvent e) -> {
+            canceled = false;
+            doClose();
+            listeners.fireActionEvent(new ActionEvent(JLrsShowMeasuresParamsController.this, 0, "accept"));
+        });
+        
+        I18nManager i18n = ToolsLocator.getI18nManager();
+
+        this.cboUnits.addItem(new LabeledValueImpl<>(i18n.getTranslation(LRS_SHOWMEASURES_UNKNOWN_OTHER_LABEL), LRS_SHOWMEASURES_UNKNOWN_OTHER));
+        this.cboUnits.addItem(new LabeledValueImpl<>(i18n.getTranslation(LRS_SHOWMEASURES_METER_LABEL), LRS_SHOWMEASURES_METER));
+        this.cboUnits.addItem(new LabeledValueImpl<>(i18n.getTranslation(LRS_SHOWMEASURES_KILOMETER_LABEL), LRS_SHOWMEASURES_KILOMETER));
+
+        this.btnCancel.addActionListener((ActionEvent e) -> {
+            canceled = true;
+            doClose();
+            listeners.fireActionEvent(new ActionEvent(JLrsShowMeasuresParamsController.this, 0, "cancel"));
+        });
+
+        setVisibleAceptCancel(false);
+        canceled = false;
+        
+        ToolsSwingUtils.ensureRowsCols(this, 8, 50);
+
+    }
+
+
+
+    private void doClose() {
+        this.setVisible(false);
+    }
+
+    @Override
+    public boolean isCanceled() {
+        return this.canceled;
+    }
+
+    @Override
+    public void setVisibleAceptCancel(boolean visible) {
+        this.btnAccept.setVisible(visible);
+        this.btnCancel.setVisible(visible);
+    }
+
+    @Override
+    public boolean getVisibleAceptCancel() {
+        return this.btnAccept.isVisible();
+    }
+
+    @Override
+    public JComponent asJComponent() {
+        return this;
+    }
+
+    @Override
+    public LrsAlgorithmParams getParams() throws LrsGettingParametersException, LrsNeededParameterException {
+        LrsAlgorithmsManager manager = LrsAlgorithmsLocator.getLrsAlgorithmsManager();
+        LrsShowMeasuresAlgorithmParams params = manager.createLrsShowMeasuresAlgorithmParams();
+        // Recorrer todo del interfaz y rellenar los parametros
+
+        try {
+            Double distance = Double.valueOf(this.txtDistance.getText());
+            params.setDistance(distance);
+
+            Object item = this.cboUnits.getSelectedItem();
+            if(item instanceof LabeledValue){
+                Integer units = (Integer) ((LabeledValue)item).getValue();
+                params.setUnits(units);
+            }
+            
+        } catch (Exception e) {
+            params.setDistance(1);
+        }
+
+        return params;
+    }
+
+    public void setParams(LrsAlgorithmParams params) {
+        if (params == null) {
+            clear();
+            return;
+        }
+        // Rellena los campos con los valores de params
+        LrsShowMeasuresAlgorithmParams parameters = (LrsShowMeasuresAlgorithmParams) params;
+
+        this.txtDistance.setText(Double.toString(parameters.getDistance()));
+
+    }
+
+    public void clear() {
+
+        this.txtDistance.setText(Double.toString(1.0));
+
+    }
+
+
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/FLayersLayerNameCellRenderer.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/FLayersLayerNameCellRenderer.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/FLayersLayerNameCellRenderer.java	(revision 950)
@@ -0,0 +1,33 @@
+/*
+ * Copyright 2015 DiSiD Technologies S.L.L. All rights reserved.
+ *
+ * Project  : DiSiD org.gvsig.lrs.swing.impl
+ * SVN Id   : $Id$
+ */
+package org.gvsig.lrs.swing.impl;
+
+import java.awt.Component;
+
+import javax.swing.DefaultListCellRenderer;
+import javax.swing.JLabel;
+import javax.swing.JList;
+import javax.swing.ListCellRenderer;
+
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+
+public class FLayersLayerNameCellRenderer implements ListCellRenderer{
+
+
+    protected DefaultListCellRenderer defaultRenderer = new DefaultListCellRenderer();
+
+    public Component getListCellRendererComponent(JList list, Object value, int index, boolean isSelected,
+        boolean cellHasFocus) {
+        JLabel renderer =
+            (JLabel) defaultRenderer.getListCellRendererComponent(list, value, index, isSelected, cellHasFocus);
+        if (value instanceof FLayer) {
+            renderer.setText(((FLayer) value).getName());
+        }
+        return renderer;
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsUtils.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsUtils.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsUtils.java	(revision 950)
@@ -0,0 +1,404 @@
+/*
+ * Copyright 2015 DiSiD Technologies S.L.L. All rights reserved.
+ *
+ * Project  : DiSiD org.gvsig.lrs.swing.impl
+ * SVN Id   : $Id$
+ */
+package org.gvsig.lrs.swing.impl;
+
+import java.io.File;
+import java.util.List;
+
+import javax.swing.JComponent;
+import javax.swing.JOptionPane;
+import javax.swing.JTextField;
+
+import org.apache.commons.io.FileUtils;
+import org.apache.commons.lang3.StringUtils;
+import org.apache.commons.lang3.mutable.MutableBoolean;
+import org.cresques.cts.IProjection;
+
+import org.gvsig.fmap.dal.DALLocator;
+import org.gvsig.fmap.dal.DataManager;
+import org.gvsig.fmap.dal.DataServerExplorer;
+import org.gvsig.fmap.dal.DataServerExplorerParameters;
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.dal.exception.ReadException;
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureSelection;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.feature.FeatureType;
+import org.gvsig.fmap.dal.feature.NewFeatureStoreParameters;
+import org.gvsig.fmap.dal.store.shp.SHPNewStoreParameters;
+import org.gvsig.fmap.geom.DataTypes;
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.geom.type.GeometryType;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.operations.LayerCollection;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.lrs.lib.api.exceptions.LrsNeededParameterException;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.exception.BaseException;
+import org.gvsig.tools.i18n.I18nManager;
+import org.gvsig.tools.swing.api.ToolsSwingLocator;
+import org.gvsig.tools.swing.api.threadsafedialogs.ThreadSafeDialogsManager;
+import org.gvsig.tools.visitor.VisitCanceledException;
+import org.gvsig.tools.visitor.Visitor;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public class JLrsUtils {
+
+    private static final Logger logger = LoggerFactory.getLogger(JLrsUtils.class);
+    /**
+     * Given a pathfile and a projection returns params to create a new feature store
+     * @param outputLayerPathFile
+     * @param projection
+     * @return
+     * @throws Exception
+     */
+    static protected NewFeatureStoreParameters createFeatureStoreParams(String outputLayerPathFile,IProjection projection) throws Exception{
+        String filePath="";
+        if(outputLayerPathFile!=null){
+            filePath=outputLayerPathFile.substring(0,outputLayerPathFile.lastIndexOf(File.separator));
+        }
+        DataManager dataManager = DALLocator.getDataManager();
+        DataServerExplorerParameters eparams =
+            dataManager.createServerExplorerParameters("FilesystemExplorer");
+        eparams.setDynValue("initialpath", filePath);
+        DataServerExplorer serverExplorer =
+            dataManager.openServerExplorer(eparams.getExplorerName(), eparams);
+
+        SHPNewStoreParameters sparams = (SHPNewStoreParameters)serverExplorer.getAddParameters("Shape");
+        sparams.setDynValue("shpfile",outputLayerPathFile);
+
+        sparams.setCRS(projection);
+
+        return sparams;
+    }
+
+
+    /**
+     * Tries to find the correct layers:
+     *   - At least 1 curve layer with at least 1 non-geometrical field
+     * @param LayerCollection layers
+     * @return true if finds the correct layers
+     */
+    public static boolean validateOneCurveLyrOneNonGeomField(LayerCollection layers){
+        boolean correctCurveLayerFound = false;
+
+        for (int i = 0; i < layers.getLayersCount() && !correctCurveLayerFound; i++) {
+            FLayer layer = layers.getLayer(i);
+            if (layer instanceof FLyrVect) {
+                FLyrVect lyrVect = (FLyrVect) layer;
+                try {
+                    if (!correctCurveLayerFound) {
+                        logger.debug(
+                            "Finding a curve layer with at least one non-geometrical field");
+                        correctCurveLayerFound =
+                            CurveLayerFoundWithOneNonGeomField(lyrVect);
+                    }
+                } catch (BaseException e1) {
+                    logger.error("Can't get linear vector layers", e1);
+                }
+            }
+        }
+        return correctCurveLayerFound;
+    }
+
+
+    /**
+     * Tries to find the correct layers:
+     *  - At least 2 layers
+     *  - At least 1 curve layer with M coordinates and at least 1 non-geometrical field
+     *  - At least 1 point layer with at least 1 non-geometrical field and 1 numeric field
+     * @param LayerCollection layers
+     * @return true if finds the correct layers
+     */
+    public static boolean validatedMCurveAndPointLayer(LayerCollection layers){
+        boolean correctCurveLayerFound = false;
+        boolean correctPointLayerFound = false;
+        boolean layersFound=false;
+
+        for (int i = 0; i < layers.getLayersCount() && !layersFound; i++) {
+            FLayer layer = layers.getLayer(i);
+            if (layer instanceof FLyrVect) {
+                FLyrVect lyrVect = (FLyrVect) layer;
+                try {
+                    if (!correctCurveLayerFound) {
+                        logger.debug(
+                            "Finding a M curve layer with at least one non-geometrical field");
+                        GeometryType geometryType = lyrVect.getGeometryType();
+                        if (geometryType != null && (geometryType.isSubTypeOf(Geometry.SUBTYPES.GEOM2DM)
+                            || geometryType.isSubTypeOf(Geometry.SUBTYPES.GEOM3DM))) {
+
+                            correctCurveLayerFound = CurveLayerFoundWithOneNonGeomField(lyrVect);
+                        }
+                    }
+                    if (!correctPointLayerFound) {
+                        logger.debug(
+                            "Finding a point layer with at least one non-geometrical field and a numeric one");
+                        correctPointLayerFound=isPointLayerWithNonGeomAndNumericFields(lyrVect);
+                    }
+                } catch (BaseException e1) {
+                    logger.error("Can't get linear vector layers", e1);
+                }
+            }
+            layersFound=correctCurveLayerFound && correctPointLayerFound;
+        }
+        return correctCurveLayerFound && correctPointLayerFound;
+    }
+
+    /**
+     * Tries to find a curve M-layer with at least one non-geometrical field
+     *
+     * @param layers
+     * @return
+     */
+    public static boolean validateMLayerWithNonGeomField(LayerCollection layers) {
+        final MutableBoolean correctLayerFound=new MutableBoolean(false);
+        if (layers != null) {
+            try {
+                layers.accept(new Visitor() {
+
+                    public void visit(Object obj)
+                        throws VisitCanceledException, BaseException {
+                        FLayer layer = (FLayer) obj;
+                        if(!correctLayerFound.getValue()){
+                            if (
+                                isMlayerWithNonGeomField(layer)) {
+                                correctLayerFound.setValue(true);
+                                throw new VisitCanceledException();
+                            }
+                        }
+                    }
+                });
+            } catch (VisitCanceledException e) {
+                return true;
+            }
+            catch (BaseException e) {
+                logger.warn("Error visiting layer");
+            }
+        }
+        return correctLayerFound.getValue();
+    }
+
+    /**
+     * Tries to find one curve layer with at least one non-geometrical field
+     * @param lyrVect
+     * @return
+     * @throws ReadException
+     */
+    private static boolean CurveLayerFoundWithOneNonGeomField(FLyrVect lyrVect) throws ReadException{
+        boolean correctCurveLayerFound = false;
+        GeometryType geometryType = lyrVect.getGeometryType();
+        if (lyrVect!=null && geometryType!=null && (geometryType.isTypeOf(Geometry.TYPES.CURVE)
+            || geometryType
+                .isTypeOf(Geometry.TYPES.MULTICURVE))) {
+
+            FeatureStore featureStore = lyrVect.getFeatureStore();
+            try {
+                FeatureType type = featureStore.getDefaultFeatureType();
+
+                FeatureAttributeDescriptor[] attributeDescriptors = type.getAttributeDescriptors();
+                for (int i = 0; i < attributeDescriptors.length; i++) {
+                    FeatureAttributeDescriptor featureAttributeDescriptor = attributeDescriptors[i];
+                    if (featureAttributeDescriptor.getDataType().getType() != DataTypes.GEOMETRY) {
+                        logger.debug("Correct curve layer found");
+                        correctCurveLayerFound = true;
+                        return correctCurveLayerFound;
+                    }
+                }
+            } catch (DataException e1) {
+                logger.warn(
+                    new StringBuilder().append("Error getting default feature type from layer ").append(lyrVect.getName())
+                        .toString(), e1);
+            }
+        }
+        return correctCurveLayerFound;
+    }
+
+
+
+    /**
+     * Tries to find one point layer with at least 1 non-geometrical field and 1 numeric field
+     * @param lyrVect
+     * @return
+     * @throws ReadException
+     */
+    private static boolean isPointLayerWithNonGeomAndNumericFields(FLyrVect lyrVect) throws ReadException{
+        boolean correctPointLayerFound=false;
+        GeometryType geometryType = lyrVect.getGeometryType();
+        if (lyrVect!=null && geometryType!=null && (geometryType.isTypeOf(Geometry.TYPES.POINT)
+            || geometryType.isTypeOf(Geometry.TYPES.MULTIPOINT))) {
+            FeatureStore featureStore = lyrVect.getFeatureStore();
+            try {
+                FeatureType type = featureStore.getDefaultFeatureType();
+
+                FeatureAttributeDescriptor[] attributeDescriptors = type.getAttributeDescriptors();
+                Boolean nonGeometricDataTypeFound=false;
+                Boolean numericDataTypeFound=false;
+                Boolean dataTypesFound=false;
+                Boolean validateNext=true;
+                for (int i = 0; i < attributeDescriptors.length&&!dataTypesFound; i++) {
+                    FeatureAttributeDescriptor featureAttributeDescriptor = attributeDescriptors[i];
+                    validateNext=true;
+                    if (featureAttributeDescriptor.getDataType().isNumeric()&&!numericDataTypeFound) {
+                        numericDataTypeFound = true;
+                        validateNext=false;
+                    }
+                    //This is done to avoid to validate twice the same numeric field
+                    if (validateNext){
+                        if (featureAttributeDescriptor.getDataType().getType() != DataTypes.GEOMETRY) {
+                            nonGeometricDataTypeFound = true;
+                        }
+                    }
+                    dataTypesFound=nonGeometricDataTypeFound&&numericDataTypeFound;
+                }
+                if(dataTypesFound){
+                    logger.debug("Correct point layer found");
+                    correctPointLayerFound=true;
+                }
+            } catch (DataException e1) {
+                logger.warn(
+                    new StringBuilder().append("Error getting default feature type from layer ").append(lyrVect.getName())
+                        .toString(), e1);
+            }
+        }
+        return correctPointLayerFound;
+    }
+
+
+    /**
+     * Verifies if it is a curve M-layer with at least one non-geometrical field
+     *
+     * @param FLayer
+     * @return
+     * @throws ReadException
+     */
+    public static boolean isMlayerWithNonGeomField(FLayer layer) {
+        boolean correctLayerFound = false;
+        // Validates is FLyrVect
+        FLyrVect lyrVect = null;
+        if (layer instanceof FLyrVect) {
+            lyrVect = (FLyrVect) layer;
+        } else
+            return false;
+
+        try {
+            if (lyrVect != null) {
+                GeometryType layerGeometryType = lyrVect.getGeometryType();
+                if (layerGeometryType!=null && (
+                    (layerGeometryType.isTypeOf(Geometry.TYPES.CURVE) || layerGeometryType.isTypeOf(Geometry.TYPES.MULTICURVE))
+                    ) && (layerGeometryType.isSubTypeOf(Geometry.SUBTYPES.GEOM2DM) || layerGeometryType
+                        .isSubTypeOf(Geometry.SUBTYPES.GEOM3DM))) {
+                    FeatureStore featureStore = lyrVect.getFeatureStore();
+                    try {
+                        FeatureType type = featureStore.getDefaultFeatureType();
+
+                        FeatureAttributeDescriptor[] attributeDescriptors = type.getAttributeDescriptors();
+                        for (int i = 0; i < attributeDescriptors.length; i++) {
+                            FeatureAttributeDescriptor featureAttributeDescriptor = attributeDescriptors[i];
+                            if (featureAttributeDescriptor.getDataType().getType() != DataTypes.GEOMETRY) {
+                                logger.debug("Correct curve layer found");
+                                return true;
+                            }
+                        }
+
+                    } catch (DataException e1) {
+                        logger.warn(new StringBuilder().append("Error getting default feature type from layer ")
+                            .append(lyrVect.getName()).toString(), e1);
+                    }
+
+                }
+            }
+        } catch (Exception e) {
+            logger.error("Can't get linear vector layers", e);
+        }
+        return correctLayerFound;
+    }
+
+
+    /**
+     * Validates if there is a valid table:
+     * - at least two fields
+     * - one of them is numeric
+     * if can't find any throws an exception
+     *
+     * @throws LrsNeededParameterException
+     * @throws ReadException
+     */
+    public static boolean validateStoreWithFieldsAndOneNumeric (List<FeatureStore> tables) {
+        for (FeatureStore featureStore : tables) {
+            try {
+                FeatureType type = featureStore.getDefaultFeatureType();
+
+                FeatureAttributeDescriptor[] attributeDescriptors =
+                    type.getAttributeDescriptors();
+                if (attributeDescriptors.length >= 2) {
+                    for (int i = 0; i < attributeDescriptors.length; i++) {
+                        FeatureAttributeDescriptor featureAttributeDescriptor =
+                            attributeDescriptors[i];
+                        if (featureAttributeDescriptor.getDataType()
+                            .isNumeric()) {
+                            logger.debug("Correct table found");
+                            return true;
+                        }
+                    }
+                }
+            } catch (DataException e1) {
+                logger.warn("Error getting default feature type");
+            }
+        }
+        return false;
+    }
+
+    /**
+     * Tries to find one curve M-layer with selected Features
+     *
+     * @param FLayer
+     * @return
+     * @throws ReadException
+     */
+    public static boolean hasMLayersWithSelectedFeatures(FLayer layer) {
+        // Validates is FLyrVect
+        FLyrVect lyrVect = null;
+        if (layer instanceof FLyrVect) {
+            lyrVect = (FLyrVect) layer;
+        } else
+            return false;
+
+        try {
+            if (lyrVect != null) {
+
+                GeometryType geometryType = lyrVect.getGeometryType();
+                if (geometryType!=null && (geometryType.isTypeOf(Geometry.TYPES.CURVE) || geometryType.isTypeOf(
+                    Geometry.TYPES.MULTICURVE))
+                    && (geometryType.isSubTypeOf(Geometry.SUBTYPES.GEOM2DM) || geometryType
+                        .isSubTypeOf(Geometry.SUBTYPES.GEOM3DM))) {
+                    // At least a feature must be selected
+                    return hasSelectedFeatures(lyrVect);
+                }
+            }
+        } catch (Exception e) {
+            logger.error("Can't get linear vector layers", e);
+        }
+        return false;
+    }
+
+    private static boolean hasSelectedFeatures(FLyrVect layer) {
+        FeatureStore featureStore=layer.getFeatureStore();
+        if(featureStore!=null){
+            try {
+                FeatureSelection selectedFeatures= featureStore.getFeatureSelection();
+                if ((selectedFeatures.getSize() >0)) {
+                   return true;
+                }
+            } catch (DataException e) {
+                logger.warn("Can't get selected feature", e);
+            }
+        }
+        return false;
+    }
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCreateRouteParamsView.xml
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCreateRouteParamsView.xml	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCreateRouteParamsView.xml	(revision 950)
@@ -0,0 +1,1643 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<object classname="com.jeta.forms.store.memento.FormPackage">
+ <at name="fileversion">
+  <object classname="com.jeta.forms.store.memento.FormsVersion2">
+   <at name="major">2</at>
+   <at name="minor">0</at>
+   <at name="sub">0</at>
+  </object>
+ </at>
+ <at name="form">
+  <object classname="com.jeta.forms.store.memento.FormMemento">
+   <super classname="com.jeta.forms.store.memento.ComponentMemento">
+    <at name="cellconstraints">
+     <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+      <at name="column">1</at>
+      <at name="row">1</at>
+      <at name="colspan">1</at>
+      <at name="rowspan">1</at>
+      <at name="halign">default</at>
+      <at name="valign">default</at>
+      <at name="insets" object="insets">0,0,0,0</at>
+     </object>
+    </at>
+    <at name="componentclass">com.jeta.forms.gui.form.FormComponent</at>
+   </super>
+   <at name="id">/home/daniel/tmp/abeille/JLrsCreateRouteParamsView.xml</at>
+   <at name="rowspecs">CENTER:DEFAULT:NONE,FILL:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:GROW(1.0),CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE</at>
+   <at name="colspecs">FILL:DEFAULT:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:GROW(1.0),FILL:DEFAULT:NONE</at>
+   <at name="components">
+    <object classname="java.util.LinkedList">
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">2</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">source</at>
+            <at name="height">20</at>
+            <at name="width">114</at>
+            <at name="name">lblInputLayer</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">2</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JComboBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JComboBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="height">20</at>
+            <at name="items">
+             <object classname="com.jeta.forms.store.properties.ItemsProperty">
+              <at name="name">items</at>
+             </object>
+            </at>
+            <at name="width">789</at>
+            <at name="name">cmbInputLayer</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">3</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JComboBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JComboBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="height">20</at>
+            <at name="items">
+             <object classname="com.jeta.forms.store.properties.ItemsProperty">
+              <at name="name">items</at>
+             </object>
+            </at>
+            <at name="width">789</at>
+            <at name="name">cmbIdRouteField</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">3</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">id_route_field</at>
+            <at name="height">14</at>
+            <at name="width">114</at>
+            <at name="name">lblIdRouteField</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">4</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">output_file</at>
+            <at name="height">14</at>
+            <at name="width">114</at>
+            <at name="name">lblOutputFile</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">5</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">measure_source</at>
+            <at name="height">14</at>
+            <at name="width">114</at>
+            <at name="name">lblMeasureSource</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">5</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JComboBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JComboBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="height">20</at>
+            <at name="items">
+             <object classname="com.jeta.forms.store.properties.ItemsProperty">
+              <at name="name">items</at>
+             </object>
+            </at>
+            <at name="width">789</at>
+            <at name="name">cmbMeasureSource</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">6</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">from_measure_field</at>
+            <at name="height">14</at>
+            <at name="width">114</at>
+            <at name="name">lblFromMeasureField</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">7</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">to_measure_field</at>
+            <at name="height">14</at>
+            <at name="width">114</at>
+            <at name="name">lblToMeasureField</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">6</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JComboBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JComboBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="height">20</at>
+            <at name="items">
+             <object classname="com.jeta.forms.store.properties.ItemsProperty">
+              <at name="name">items</at>
+             </object>
+            </at>
+            <at name="width">789</at>
+            <at name="name">cmbFromMeasureField</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">7</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JComboBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JComboBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="height">20</at>
+            <at name="items">
+             <object classname="com.jeta.forms.store.properties.ItemsProperty">
+              <at name="name">items</at>
+             </object>
+            </at>
+            <at name="width">789</at>
+            <at name="name">cmbToMeasureField</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">8</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">coordinates_priority</at>
+            <at name="height">14</at>
+            <at name="width">114</at>
+            <at name="name">lblCoordinatesPriority</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">8</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JComboBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JComboBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="height">20</at>
+            <at name="items">
+             <object classname="com.jeta.forms.store.properties.ItemsProperty">
+              <at name="name">items</at>
+             </object>
+            </at>
+            <at name="width">789</at>
+            <at name="name">cmbCoordinatePriority</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">9</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JFormattedTextField</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JFormattedTextField</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="height">20</at>
+            <at name="width">789</at>
+            <at name="name">txtMeasureFactor</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">9</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">measure_factor</at>
+            <at name="height">14</at>
+            <at name="width">114</at>
+            <at name="name">lblMeasureFactor</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">10</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">measure_offset</at>
+            <at name="height">14</at>
+            <at name="width">114</at>
+            <at name="name">lblMeasureOffset</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">10</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JFormattedTextField</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JFormattedTextField</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="height">20</at>
+            <at name="width">789</at>
+            <at name="name">txtMeasureOffset</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">11</at>
+           <at name="colspan">3</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JCheckBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JCheckBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">ignore_spatial_gaps</at>
+            <at name="height">16</at>
+            <at name="width">914</at>
+            <at name="name">chkIgnoreSpatialGaps</at>
+            <at name="actionCommand">JCBIgnoreSpatialGaps</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.FormMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">4</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.FormComponent</at>
+        </super>
+        <at name="id">embedded.1952982194</at>
+        <at name="rowspecs">CENTER:DEFAULT:NONE</at>
+        <at name="colspecs">FILL:DEFAULT:GROW(1.0),FILL:36PX:NONE</at>
+        <at name="components">
+         <object classname="java.util.LinkedList">
+          <item >
+           <at name="value">
+            <object classname="com.jeta.forms.store.memento.BeanMemento">
+             <super classname="com.jeta.forms.store.memento.ComponentMemento">
+              <at name="cellconstraints">
+               <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+                <at name="column">1</at>
+                <at name="row">1</at>
+                <at name="colspan">1</at>
+                <at name="rowspan">1</at>
+                <at name="halign">default</at>
+                <at name="valign">default</at>
+                <at name="insets" object="insets">0,0,0,0</at>
+               </object>
+              </at>
+              <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+             </super>
+             <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+             <at name="beanclass">javax.swing.JTextField</at>
+             <at name="beanproperties">
+              <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+               <at name="classname">javax.swing.JTextField</at>
+               <at name="properties">
+                <object classname="com.jeta.forms.store.support.PropertyMap">
+                 <at name="horizontalAlignment">2</at>
+                 <at name="height">20</at>
+                 <at name="width">748</at>
+                 <at name="name">txtOutputFile</at>
+                 <at name="border">
+                  <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                   <at name="borders">
+                    <object classname="java.util.LinkedList">
+                     <item >
+                      <at name="value">
+                       <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                        <super classname="com.jeta.forms.store.properties.BorderProperty">
+                         <at name="name">border</at>
+                        </super>
+                       </object>
+                      </at>
+                     </item>
+                    </object>
+                   </at>
+                  </object>
+                 </at>
+                </object>
+               </at>
+              </object>
+             </at>
+            </object>
+           </at>
+          </item>
+          <item >
+           <at name="value">
+            <object classname="com.jeta.forms.store.memento.BeanMemento">
+             <super classname="com.jeta.forms.store.memento.ComponentMemento">
+              <at name="cellconstraints">
+               <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+                <at name="column">2</at>
+                <at name="row">1</at>
+                <at name="colspan">1</at>
+                <at name="rowspan">1</at>
+                <at name="halign">default</at>
+                <at name="valign">default</at>
+                <at name="insets" object="insets">0,0,0,0</at>
+               </object>
+              </at>
+              <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+             </super>
+             <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+             <at name="beanclass">javax.swing.JButton</at>
+             <at name="beanproperties">
+              <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+               <at name="classname">javax.swing.JButton</at>
+               <at name="properties">
+                <object classname="com.jeta.forms.store.support.PropertyMap">
+                 <at name="text">...</at>
+                 <at name="height">22</at>
+                 <at name="opaque">false</at>
+                 <at name="width">32</at>
+                 <at name="name">btnBrowser</at>
+                 <at name="actionCommand">JButton</at>
+                 <at name="border">
+                  <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                   <at name="borders">
+                    <object classname="java.util.LinkedList">
+                     <item >
+                      <at name="value">
+                       <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                        <super classname="com.jeta.forms.store.properties.BorderProperty">
+                         <at name="name">border</at>
+                        </super>
+                       </object>
+                      </at>
+                     </item>
+                    </object>
+                   </at>
+                  </object>
+                 </at>
+                 <at name="rolloverEnabled">true</at>
+                </object>
+               </at>
+              </object>
+             </at>
+            </object>
+           </at>
+          </item>
+         </object>
+        </at>
+        <at name="properties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.gui.form.GridView</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="name"></at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="scollBars">
+             <object classname="com.jeta.forms.store.properties.ScrollBarsProperty">
+              <at name="name">scollBars</at>
+              <at name="verticalpolicy">21</at>
+              <at name="horizontalpolicy">31</at>
+              <at name="border">
+               <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                <super classname="com.jeta.forms.store.properties.BorderProperty">
+                 <at name="name">border</at>
+                </super>
+                <at name="borders">
+                 <object classname="java.util.LinkedList">
+                  <item >
+                   <at name="value">
+                    <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                     <super classname="com.jeta.forms.store.properties.BorderProperty">
+                      <at name="name">border</at>
+                     </super>
+                    </object>
+                   </at>
+                  </item>
+                 </object>
+                </at>
+               </object>
+              </at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList"/>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+        <at name="cellpainters">
+         <object classname="com.jeta.forms.store.support.Matrix">
+          <at name="rows">
+           <object classname="[Ljava.lang.Object;" size="1">
+            <at name="item" index="0">
+             <object classname="[Ljava.lang.Object;" size="2"/>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+        <at name="rowgroups">
+         <object classname="com.jeta.forms.store.memento.FormGroupSet">
+          <at name="groups">
+           <object classname="java.util.HashMap"/>
+          </at>
+         </object>
+        </at>
+        <at name="colgroups">
+         <object classname="com.jeta.forms.store.memento.FormGroupSet">
+          <at name="groups">
+           <object classname="java.util.HashMap"/>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.FormMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">13</at>
+           <at name="colspan">3</at>
+           <at name="rowspan">1</at>
+           <at name="halign">right</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.FormComponent</at>
+        </super>
+        <at name="id">embedded.87267659</at>
+        <at name="rowspecs">CENTER:DEFAULT:NONE</at>
+        <at name="colspecs">FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE</at>
+        <at name="components">
+         <object classname="java.util.LinkedList">
+          <item >
+           <at name="value">
+            <object classname="com.jeta.forms.store.memento.BeanMemento">
+             <super classname="com.jeta.forms.store.memento.ComponentMemento">
+              <at name="cellconstraints">
+               <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+                <at name="column">1</at>
+                <at name="row">1</at>
+                <at name="colspan">1</at>
+                <at name="rowspan">1</at>
+                <at name="halign">center</at>
+                <at name="valign">default</at>
+                <at name="insets" object="insets">0,0,0,0</at>
+               </object>
+              </at>
+              <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+             </super>
+             <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+             <at name="beanclass">javax.swing.JButton</at>
+             <at name="beanproperties">
+              <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+               <at name="classname">javax.swing.JButton</at>
+               <at name="properties">
+                <object classname="com.jeta.forms.store.support.PropertyMap">
+                 <at name="text">_Accept</at>
+                 <at name="height">22</at>
+                 <at name="width">75</at>
+                 <at name="name">btnAccept</at>
+                 <at name="actionCommand">_Accept</at>
+                 <at name="border">
+                  <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                   <at name="borders">
+                    <object classname="java.util.LinkedList">
+                     <item >
+                      <at name="value">
+                       <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                        <super classname="com.jeta.forms.store.properties.BorderProperty">
+                         <at name="name">border</at>
+                        </super>
+                       </object>
+                      </at>
+                     </item>
+                    </object>
+                   </at>
+                  </object>
+                 </at>
+                </object>
+               </at>
+              </object>
+             </at>
+            </object>
+           </at>
+          </item>
+          <item >
+           <at name="value">
+            <object classname="com.jeta.forms.store.memento.BeanMemento">
+             <super classname="com.jeta.forms.store.memento.ComponentMemento">
+              <at name="cellconstraints">
+               <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+                <at name="column">3</at>
+                <at name="row">1</at>
+                <at name="colspan">1</at>
+                <at name="rowspan">1</at>
+                <at name="halign">default</at>
+                <at name="valign">default</at>
+                <at name="insets" object="insets">0,0,0,0</at>
+               </object>
+              </at>
+              <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+             </super>
+             <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+             <at name="beanclass">javax.swing.JButton</at>
+             <at name="beanproperties">
+              <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+               <at name="classname">javax.swing.JButton</at>
+               <at name="properties">
+                <object classname="com.jeta.forms.store.support.PropertyMap">
+                 <at name="text">_Cancel</at>
+                 <at name="height">22</at>
+                 <at name="width">76</at>
+                 <at name="name">btnCancel</at>
+                 <at name="actionCommand">_Cancel</at>
+                 <at name="border">
+                  <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                   <at name="borders">
+                    <object classname="java.util.LinkedList">
+                     <item >
+                      <at name="value">
+                       <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                        <super classname="com.jeta.forms.store.properties.BorderProperty">
+                         <at name="name">border</at>
+                        </super>
+                       </object>
+                      </at>
+                     </item>
+                    </object>
+                   </at>
+                  </object>
+                 </at>
+                </object>
+               </at>
+              </object>
+             </at>
+            </object>
+           </at>
+          </item>
+         </object>
+        </at>
+        <at name="properties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.gui.form.GridView</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="name"></at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="scollBars">
+             <object classname="com.jeta.forms.store.properties.ScrollBarsProperty">
+              <at name="name">scollBars</at>
+              <at name="verticalpolicy">21</at>
+              <at name="horizontalpolicy">31</at>
+              <at name="border">
+               <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                <super classname="com.jeta.forms.store.properties.BorderProperty">
+                 <at name="name">border</at>
+                </super>
+                <at name="borders">
+                 <object classname="java.util.LinkedList">
+                  <item >
+                   <at name="value">
+                    <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                     <super classname="com.jeta.forms.store.properties.BorderProperty">
+                      <at name="name">border</at>
+                     </super>
+                    </object>
+                   </at>
+                  </item>
+                 </object>
+                </at>
+               </object>
+              </at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList"/>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+        <at name="cellpainters">
+         <object classname="com.jeta.forms.store.support.Matrix">
+          <at name="rows">
+           <object classname="[Ljava.lang.Object;" size="1">
+            <at name="item" index="0">
+             <object classname="[Ljava.lang.Object;" size="3"/>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+        <at name="rowgroups">
+         <object classname="com.jeta.forms.store.memento.FormGroupSet">
+          <at name="groups">
+           <object classname="java.util.HashMap"/>
+          </at>
+         </object>
+        </at>
+        <at name="colgroups">
+         <object classname="com.jeta.forms.store.memento.FormGroupSet">
+          <at name="groups">
+           <object classname="java.util.HashMap"/>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+    </object>
+   </at>
+   <at name="properties">
+    <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+     <at name="classname">com.jeta.forms.gui.form.GridView</at>
+     <at name="properties">
+      <object classname="com.jeta.forms.store.support.PropertyMap">
+       <at name="name">JLrsCreateRouteParametersPanel</at>
+       <at name="fill">
+        <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+         <at name="name">fill</at>
+        </object>
+       </at>
+       <at name="scollBars">
+        <object classname="com.jeta.forms.store.properties.ScrollBarsProperty">
+         <at name="name">scollBars</at>
+         <at name="verticalpolicy">21</at>
+         <at name="horizontalpolicy">31</at>
+         <at name="border">
+          <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+           <super classname="com.jeta.forms.store.properties.BorderProperty">
+            <at name="name">border</at>
+           </super>
+           <at name="borders">
+            <object classname="java.util.LinkedList">
+             <item >
+              <at name="value">
+               <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                <super classname="com.jeta.forms.store.properties.BorderProperty">
+                 <at name="name">border</at>
+                </super>
+               </object>
+              </at>
+             </item>
+            </object>
+           </at>
+          </object>
+         </at>
+        </object>
+       </at>
+       <at name="border">
+        <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+         <super classname="com.jeta.forms.store.properties.BorderProperty">
+          <at name="name">border</at>
+         </super>
+         <at name="borders">
+          <object classname="java.util.LinkedList"/>
+         </at>
+        </object>
+       </at>
+      </object>
+     </at>
+    </object>
+   </at>
+   <at name="cellpainters">
+    <object classname="com.jeta.forms.store.support.Matrix">
+     <at name="rows">
+      <object classname="[Ljava.lang.Object;" size="14">
+       <at name="item" index="0">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="1">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="2">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="3">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="4">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="5">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="6">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="7">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="8">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="9">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="10">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="11">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="12">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="13">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+      </object>
+     </at>
+    </object>
+   </at>
+   <at name="rowgroups">
+    <object classname="com.jeta.forms.store.memento.FormGroupSet">
+     <at name="groups">
+      <object classname="java.util.HashMap"/>
+     </at>
+    </object>
+   </at>
+   <at name="colgroups">
+    <object classname="com.jeta.forms.store.memento.FormGroupSet">
+     <at name="groups">
+      <object classname="java.util.HashMap"/>
+     </at>
+    </object>
+   </at>
+  </object>
+ </at>
+</object>
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsShowMeasuresParamsView.xml
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsShowMeasuresParamsView.xml	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsShowMeasuresParamsView.xml	(revision 950)
@@ -0,0 +1,594 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<object classname="com.jeta.forms.store.memento.FormPackage">
+ <at name="fileversion">
+  <object classname="com.jeta.forms.store.memento.FormsVersion2">
+   <at name="major">2</at>
+   <at name="minor">0</at>
+   <at name="sub">0</at>
+  </object>
+ </at>
+ <at name="form">
+  <object classname="com.jeta.forms.store.memento.FormMemento">
+   <super classname="com.jeta.forms.store.memento.ComponentMemento">
+    <at name="cellconstraints">
+     <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+      <at name="column">1</at>
+      <at name="row">1</at>
+      <at name="colspan">1</at>
+      <at name="rowspan">1</at>
+      <at name="halign">default</at>
+      <at name="valign">default</at>
+      <at name="insets" object="insets">0,0,0,0</at>
+     </object>
+    </at>
+    <at name="componentclass">com.jeta.forms.gui.form.FormComponent</at>
+   </super>
+   <at name="id">/home/fdiaz/projects/gvSIG/org.gvsig.lrs/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsShowMeasuresParamsView.xml</at>
+   <at name="rowspecs">CENTER:2DLU:NONE,CENTER:DEFAULT:NONE,CENTER:2DLU:NONE,CENTER:DEFAULT:NONE,CENTER:2DLU:NONE,CENTER:DEFAULT:NONE,CENTER:2DLU:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:GROW(1.0),CENTER:DEFAULT:NONE,CENTER:2DLU:NONE</at>
+   <at name="colspecs">FILL:4DLU:NONE,FILL:DEFAULT:GROW(1.0),FILL:4DLU:NONE</at>
+   <at name="components">
+    <object classname="java.util.LinkedList">
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.FormMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">10</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">right</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.FormComponent</at>
+        </super>
+        <at name="id">embedded.735374231</at>
+        <at name="rowspecs">CENTER:DEFAULT:NONE</at>
+        <at name="colspecs">FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE</at>
+        <at name="components">
+         <object classname="java.util.LinkedList">
+          <item >
+           <at name="value">
+            <object classname="com.jeta.forms.store.memento.BeanMemento">
+             <super classname="com.jeta.forms.store.memento.ComponentMemento">
+              <at name="cellconstraints">
+               <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+                <at name="column">1</at>
+                <at name="row">1</at>
+                <at name="colspan">1</at>
+                <at name="rowspan">1</at>
+                <at name="halign">center</at>
+                <at name="valign">default</at>
+                <at name="insets" object="insets">0,0,0,0</at>
+               </object>
+              </at>
+              <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+             </super>
+             <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+             <at name="beanclass">javax.swing.JButton</at>
+             <at name="beanproperties">
+              <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+               <at name="classname">javax.swing.JButton</at>
+               <at name="properties">
+                <object classname="com.jeta.forms.store.support.PropertyMap">
+                 <at name="border">
+                  <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                   <at name="borders">
+                    <object classname="java.util.LinkedList">
+                     <item >
+                      <at name="value">
+                       <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                        <super classname="com.jeta.forms.store.properties.BorderProperty">
+                         <at name="name">border</at>
+                        </super>
+                       </object>
+                      </at>
+                     </item>
+                    </object>
+                   </at>
+                  </object>
+                 </at>
+                 <at name="actionCommand">_Accept</at>
+                 <at name="name">btnAccept</at>
+                 <at name="width">62</at>
+                 <at name="text">_Accept</at>
+                 <at name="height">22</at>
+                </object>
+               </at>
+              </object>
+             </at>
+            </object>
+           </at>
+          </item>
+          <item >
+           <at name="value">
+            <object classname="com.jeta.forms.store.memento.BeanMemento">
+             <super classname="com.jeta.forms.store.memento.ComponentMemento">
+              <at name="cellconstraints">
+               <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+                <at name="column">3</at>
+                <at name="row">1</at>
+                <at name="colspan">1</at>
+                <at name="rowspan">1</at>
+                <at name="halign">default</at>
+                <at name="valign">default</at>
+                <at name="insets" object="insets">0,0,0,0</at>
+               </object>
+              </at>
+              <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+             </super>
+             <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+             <at name="beanclass">javax.swing.JButton</at>
+             <at name="beanproperties">
+              <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+               <at name="classname">javax.swing.JButton</at>
+               <at name="properties">
+                <object classname="com.jeta.forms.store.support.PropertyMap">
+                 <at name="border">
+                  <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                   <at name="borders">
+                    <object classname="java.util.LinkedList">
+                     <item >
+                      <at name="value">
+                       <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                        <super classname="com.jeta.forms.store.properties.BorderProperty">
+                         <at name="name">border</at>
+                        </super>
+                       </object>
+                      </at>
+                     </item>
+                    </object>
+                   </at>
+                  </object>
+                 </at>
+                 <at name="actionCommand">_Cancel</at>
+                 <at name="name">btnCancel</at>
+                 <at name="width">61</at>
+                 <at name="text">_Cancel</at>
+                 <at name="height">22</at>
+                </object>
+               </at>
+              </object>
+             </at>
+            </object>
+           </at>
+          </item>
+         </object>
+        </at>
+        <at name="properties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.gui.form.GridView</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList"/>
+              </at>
+             </object>
+            </at>
+            <at name="name"></at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="scollBars">
+             <object classname="com.jeta.forms.store.properties.ScrollBarsProperty">
+              <at name="name">scollBars</at>
+              <at name="verticalpolicy">21</at>
+              <at name="horizontalpolicy">31</at>
+              <at name="border">
+               <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                <super classname="com.jeta.forms.store.properties.BorderProperty">
+                 <at name="name">border</at>
+                </super>
+                <at name="borders">
+                 <object classname="java.util.LinkedList">
+                  <item >
+                   <at name="value">
+                    <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                     <super classname="com.jeta.forms.store.properties.BorderProperty">
+                      <at name="name">border</at>
+                     </super>
+                    </object>
+                   </at>
+                  </item>
+                 </object>
+                </at>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+        <at name="cellpainters">
+         <object classname="com.jeta.forms.store.support.Matrix">
+          <at name="rows">
+           <object classname="[Ljava.lang.Object;" size="1">
+            <at name="item" index="0">
+             <object classname="[Ljava.lang.Object;" size="3"/>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+        <at name="rowgroups">
+         <object classname="com.jeta.forms.store.memento.FormGroupSet">
+          <at name="groups">
+           <object classname="java.util.HashMap"/>
+          </at>
+         </object>
+        </at>
+        <at name="colgroups">
+         <object classname="com.jeta.forms.store.memento.FormGroupSet">
+          <at name="groups">
+           <object classname="java.util.HashMap"/>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">2</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+            <at name="name">lblUnits</at>
+            <at name="width">1247</at>
+            <at name="text">_Data_units</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="toolTipText">_Units_of_measure_of_the_M_coordinate_of_the_layer</at>
+            <at name="height">17</at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">4</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JComboBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JComboBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+            <at name="name">cboUnits</at>
+            <at name="width">1247</at>
+            <at name="items">
+             <object classname="com.jeta.forms.store.properties.ItemsProperty">
+              <at name="name">items</at>
+             </object>
+            </at>
+            <at name="toolTipText">_Units_of_measure_of_the_M_coordinate_of_the_layer</at>
+            <at name="height">23</at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">6</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+            <at name="name">lblDistance</at>
+            <at name="width">1247</at>
+            <at name="text">distance</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="height">17</at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">8</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JTextField</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JTextField</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+            <at name="name">txtDistance</at>
+            <at name="width">1247</at>
+            <at name="height">21</at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+    </object>
+   </at>
+   <at name="properties">
+    <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+     <at name="classname">com.jeta.forms.gui.form.GridView</at>
+     <at name="properties">
+      <object classname="com.jeta.forms.store.support.PropertyMap">
+       <at name="border">
+        <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+         <super classname="com.jeta.forms.store.properties.BorderProperty">
+          <at name="name">border</at>
+         </super>
+         <at name="borders">
+          <object classname="java.util.LinkedList"/>
+         </at>
+        </object>
+       </at>
+       <at name="name"></at>
+       <at name="fill">
+        <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+         <at name="name">fill</at>
+        </object>
+       </at>
+       <at name="scollBars">
+        <object classname="com.jeta.forms.store.properties.ScrollBarsProperty">
+         <at name="name">scollBars</at>
+         <at name="verticalpolicy">21</at>
+         <at name="horizontalpolicy">31</at>
+         <at name="border">
+          <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+           <super classname="com.jeta.forms.store.properties.BorderProperty">
+            <at name="name">border</at>
+           </super>
+           <at name="borders">
+            <object classname="java.util.LinkedList">
+             <item >
+              <at name="value">
+               <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                <super classname="com.jeta.forms.store.properties.BorderProperty">
+                 <at name="name">border</at>
+                </super>
+               </object>
+              </at>
+             </item>
+            </object>
+           </at>
+          </object>
+         </at>
+        </object>
+       </at>
+      </object>
+     </at>
+    </object>
+   </at>
+   <at name="cellpainters">
+    <object classname="com.jeta.forms.store.support.Matrix">
+     <at name="rows">
+      <object classname="[Ljava.lang.Object;" size="11">
+       <at name="item" index="0">
+        <object classname="[Ljava.lang.Object;" size="3"/>
+       </at>
+       <at name="item" index="1">
+        <object classname="[Ljava.lang.Object;" size="3"/>
+       </at>
+       <at name="item" index="2">
+        <object classname="[Ljava.lang.Object;" size="3"/>
+       </at>
+       <at name="item" index="3">
+        <object classname="[Ljava.lang.Object;" size="3"/>
+       </at>
+       <at name="item" index="4">
+        <object classname="[Ljava.lang.Object;" size="3"/>
+       </at>
+       <at name="item" index="5">
+        <object classname="[Ljava.lang.Object;" size="3"/>
+       </at>
+       <at name="item" index="6">
+        <object classname="[Ljava.lang.Object;" size="3"/>
+       </at>
+       <at name="item" index="7">
+        <object classname="[Ljava.lang.Object;" size="3"/>
+       </at>
+       <at name="item" index="8">
+        <object classname="[Ljava.lang.Object;" size="3"/>
+       </at>
+       <at name="item" index="9">
+        <object classname="[Ljava.lang.Object;" size="3"/>
+       </at>
+       <at name="item" index="10">
+        <object classname="[Ljava.lang.Object;" size="3"/>
+       </at>
+      </object>
+     </at>
+    </object>
+   </at>
+   <at name="rowgroups">
+    <object classname="com.jeta.forms.store.memento.FormGroupSet">
+     <at name="groups">
+      <object classname="java.util.HashMap"/>
+     </at>
+    </object>
+   </at>
+   <at name="colgroups">
+    <object classname="com.jeta.forms.store.memento.FormGroupSet">
+     <at name="groups">
+      <object classname="java.util.HashMap"/>
+     </at>
+    </object>
+   </at>
+  </object>
+ </at>
+</object>
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsEditRouteCalibrationSelectIdRouteView.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsEditRouteCalibrationSelectIdRouteView.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsEditRouteCalibrationSelectIdRouteView.java	(revision 950)
@@ -0,0 +1,162 @@
+package org.gvsig.lrs.swing.impl;
+
+import com.jgoodies.forms.layout.CellConstraints;
+import com.jgoodies.forms.layout.FormLayout;
+import java.awt.BorderLayout;
+import java.awt.ComponentOrientation;
+import java.awt.Container;
+import java.awt.Dimension;
+import javax.swing.Box;
+import javax.swing.ImageIcon;
+import javax.swing.JButton;
+import javax.swing.JComboBox;
+import javax.swing.JFrame;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+
+
+public class JLrsEditRouteCalibrationSelectIdRouteView extends JPanel
+{
+   JLabel lblIdRouteField = new JLabel();
+   JComboBox cmbIdRouteField = new JComboBox();
+   JButton btnAccept = new JButton();
+   JButton btnCancel = new JButton();
+
+   /**
+    * Default constructor
+    */
+   public JLrsEditRouteCalibrationSelectIdRouteView()
+   {
+      initializePanel();
+   }
+
+   /**
+    * Adds fill components to empty cells in the first row and first column of the grid.
+    * This ensures that the grid spacing will be the same as shown in the designer.
+    * @param cols an array of column indices in the first row where fill components should be added.
+    * @param rows an array of row indices in the first column where fill components should be added.
+    */
+   void addFillComponents( Container panel, int[] cols, int[] rows )
+   {
+      Dimension filler = new Dimension(10,10);
+
+      boolean filled_cell_11 = false;
+      CellConstraints cc = new CellConstraints();
+      if ( cols.length > 0 && rows.length > 0 )
+      {
+         if ( cols[0] == 1 && rows[0] == 1 )
+         {
+            /** add a rigid area  */
+            panel.add( Box.createRigidArea( filler ), cc.xy(1,1) );
+            filled_cell_11 = true;
+         }
+      }
+
+      for( int index = 0; index < cols.length; index++ )
+      {
+         if ( cols[index] == 1 && filled_cell_11 )
+         {
+            continue;
+         }
+         panel.add( Box.createRigidArea( filler ), cc.xy(cols[index],1) );
+      }
+
+      for( int index = 0; index < rows.length; index++ )
+      {
+         if ( rows[index] == 1 && filled_cell_11 )
+         {
+            continue;
+         }
+         panel.add( Box.createRigidArea( filler ), cc.xy(1,rows[index]) );
+      }
+
+   }
+
+   /**
+    * Helper method to load an image file from the CLASSPATH
+    * @param imageName the package and name of the file to load relative to the CLASSPATH
+    * @return an ImageIcon instance with the specified image file
+    * @throws IllegalArgumentException if the image resource cannot be loaded.
+    */
+   public ImageIcon loadImage( String imageName )
+   {
+      try
+      {
+         ClassLoader classloader = getClass().getClassLoader();
+         java.net.URL url = classloader.getResource( imageName );
+         if ( url != null )
+         {
+            ImageIcon icon = new ImageIcon( url );
+            return icon;
+         }
+      }
+      catch( Exception e )
+      {
+         e.printStackTrace();
+      }
+      throw new IllegalArgumentException( "Unable to load image: " + imageName );
+   }
+
+   /**
+    * Method for recalculating the component orientation for
+    * right-to-left Locales.
+    * @param orientation the component orientation to be applied
+    */
+   public void applyComponentOrientation( ComponentOrientation orientation )
+   {
+      // Not yet implemented...
+      // I18NUtils.applyComponentOrientation(this, orientation);
+      super.applyComponentOrientation(orientation);
+   }
+
+   public JPanel createPanel()
+   {
+      JPanel jpanel1 = new JPanel();
+      FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:334PX:GROW(1.0),FILL:DEFAULT:NONE","CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:GROW(1.0),CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE");
+      CellConstraints cc = new CellConstraints();
+      jpanel1.setLayout(formlayout1);
+
+      lblIdRouteField.setName("lblIdRouteField");
+      lblIdRouteField.setText("id_route_field");
+      jpanel1.add(lblIdRouteField,cc.xy(2,2));
+
+      cmbIdRouteField.setName("cmbIdRouteField");
+      jpanel1.add(cmbIdRouteField,cc.xy(4,2));
+
+      jpanel1.add(createPanel1(),new CellConstraints(2,4,3,1,CellConstraints.RIGHT,CellConstraints.DEFAULT));
+      addFillComponents(jpanel1,new int[]{ 1,2,3,4,5 },new int[]{ 1,2,3,4,5 });
+      return jpanel1;
+   }
+
+   public JPanel createPanel1()
+   {
+      JPanel jpanel1 = new JPanel();
+      FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE","CENTER:DEFAULT:NONE");
+      CellConstraints cc = new CellConstraints();
+      jpanel1.setLayout(formlayout1);
+
+      btnAccept.setActionCommand("_Accept");
+      btnAccept.setName("btnAccept");
+      btnAccept.setText("_Accept");
+      jpanel1.add(btnAccept,cc.xy(1,1));
+
+      btnCancel.setActionCommand("_Cancel");
+      btnCancel.setName("btnCancel");
+      btnCancel.setText("_Cancel");
+      jpanel1.add(btnCancel,cc.xy(3,1));
+
+      addFillComponents(jpanel1,new int[]{ 2 },new int[0]);
+      return jpanel1;
+   }
+
+   /**
+    * Initializer
+    */
+   protected void initializePanel()
+   {
+      setLayout(new BorderLayout());
+      add(createPanel(), BorderLayout.CENTER);
+   }
+
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/DefaultLrsAlgorithmsSwingManager.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/DefaultLrsAlgorithmsSwingManager.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/DefaultLrsAlgorithmsSwingManager.java	(revision 950)
@@ -0,0 +1,169 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.swing.impl;
+
+import java.util.List;
+
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.FLayers;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.lrs.lib.api.LrsCalibrateRouteAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsEditRouteCalibrationAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsEditRouteCalibrationSelectIdRouteAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsGenerateDynamicSegmentationAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsShowMeasuresAlgorithmParams;
+import org.gvsig.lrs.lib.api.exceptions.LrsGettingParametersException;
+import org.gvsig.lrs.lib.api.exceptions.LrsNeededParameterException;
+import org.gvsig.lrs.swing.api.JLrsAlgorithmParams;
+import org.gvsig.lrs.swing.api.JLrsLastUsedValues;
+import org.gvsig.lrs.swing.api.JLrsProgressDialog;
+import org.gvsig.lrs.swing.api.LrsAlgorithmsSwingManager;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.dynobject.DynObject;
+import org.gvsig.tools.dynobject.DynObjectManager;
+import org.gvsig.tools.service.Service;
+import org.gvsig.tools.service.ServiceException;
+import org.gvsig.tools.task.TaskStatus;
+
+
+/**
+ * @author fdiaz
+ *
+ */
+public class DefaultLrsAlgorithmsSwingManager implements LrsAlgorithmsSwingManager {
+
+    private JLrsLastUsedValues params;
+
+	/* (non-Javadoc)
+     * @see org.gvsig.tools.service.Manager#createServiceParameters(java.lang.String)
+     */
+    public DynObject createServiceParameters(String serviceName) throws ServiceException {
+        // TODO Auto-generated method stub
+        return null;
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.tools.service.Manager#getService(org.gvsig.tools.dynobject.DynObject)
+     */
+    public Service getService(DynObject parameters) throws ServiceException {
+        // TODO Auto-generated method stub
+        return null;
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.swing.api.LrsAlgorithmsSwingManager#createJLrsAlgorithmParameters()
+     */
+    public JLrsAlgorithmParams createJLrsAlgorithmParameters() {
+        // TODO Auto-generated method stub
+        return null;
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.swing.api.LrsAlgorithmsSwingManager#createJLrsAlgorithmParameters(org.gvsig.tools.dynobject.DynObject)
+     */
+    public JLrsAlgorithmParams createJLrsAlgorithmParameters(DynObject parameters) {
+        // TODO Auto-generated method stub
+        return null;
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.swing.api.LrsAlgorithmsSwingManager#createJLrsCreateRouteAlgorithmParameters(org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams)
+     */
+    public JLrsAlgorithmParams createJLrsCreateRouteAlgorithmParameters(FLayers layers, LrsCreateRouteAlgorithmParams parameters) throws LrsNeededParameterException {
+        return new JLrsCreateRouteParamsController(layers, parameters);
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.swing.api.LrsAlgorithmsSwingManager#createJLrsCalibrateRouteAlgorithmParameters(org.gvsig.lrs.lib.api.LrsCalibrateRouteAlgorithmParams)
+     */
+    public JLrsAlgorithmParams createJLrsCalibrateRouteAlgorithmParameters(FLayers layers, LrsCalibrateRouteAlgorithmParams parameters) throws LrsNeededParameterException {
+        return new JLrsCalibrateRouteParamsController(layers, parameters);
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.swing.api.LrsAlgorithmsSwingManager#createJLrsEditRouteCalibrationSelectIdRouteAlgorithmParameters(org.gvsig.lrs.lib.api.LrsEditRouteCalibrationSelectIdRouteAlgorithmParams)
+     */
+    public JLrsAlgorithmParams createJLrsEditRouteCalibrationSelectIdRouteAlgorithmParameters(FLyrVect layer, LrsEditRouteCalibrationSelectIdRouteAlgorithmParams parameters) throws LrsNeededParameterException {
+        return new JLrsEditRouteCalibrationSelectIdRouteController(layer, parameters);
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.swing.api.LrsAlgorithmsSwingManager#createJLrsEditRouteCalibrationAlgorithmParameters(org.gvsig.lrs.lib.api.LrsEditRouteCalibrationAlgorithmParameters)
+     */
+    public JLrsAlgorithmParams createJLrsEditRouteCalibrationAlgorithmParameters(FLyrVect layer, MapContext mapContext, FeatureAttributeDescriptor selectedIdRoute, LrsEditRouteCalibrationAlgorithmParams parameters) throws LrsNeededParameterException, LrsGettingParametersException {
+        return new JLrsEditRouteCalibrationController(layer, mapContext, selectedIdRoute, parameters);
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.swing.api.LrsAlgorithmsSwingManager#createJLrsShowMeasuresAlgorithmParameters(org.gvsig.lrs.lib.api.LrsCalibrateRouteAlgorithmParams)
+     */
+    public JLrsAlgorithmParams createJLrsShowMeasuresAlgorithmParameters(FLayer layer, LrsShowMeasuresAlgorithmParams parameters) throws LrsNeededParameterException {
+        return new JLrsShowMeasuresParamsController(layer, parameters);
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.swing.api.LrsAlgorithmsSwingManager#createJLrsShowMeasuresAlgorithmParameters(org.gvsig.lrs.lib.api.LrsCalibrateRouteAlgorithmParams)
+     */
+    public JLrsAlgorithmParams createJLrsGenerateDynamicSegmentationAlgorithmParameters(FLayers layers, List<FeatureStore> tables, LrsGenerateDynamicSegmentationAlgorithmParams parameters) throws LrsNeededParameterException{
+        return new JLrsGenerateDynamicSegmentationParamsController(layers, tables, parameters);
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.swing.api.LrsAlgorithmsSwingManager#createJLrsProgressDialog(org.gvsig.tools.task.TaskStatus)
+     */
+    public JLrsProgressDialog createJLrsProgressDialog(TaskStatus taskStatus) {
+        return new DefaultProgressDialogController(taskStatus);
+    }
+
+	public JLrsAlgorithmParams createJLrsCalculateMRoutePanel(FLayer layer) throws LrsNeededParameterException {
+		return createJLrsCalculateMRoutePanel(layer, null);
+	}
+
+	public JLrsAlgorithmParams createJLrsCalculateMRoutePanel(FLayer layer, JLrsLastUsedValues params)
+			throws LrsNeededParameterException {
+		if(params == null){
+			DynObjectManager dynmanager = ToolsLocator.getDynObjectManager();
+			params = getJLrsLastUsedValues(dynmanager.createDynObject("JLrsLastUsedValues"));
+		}
+		return new JLrsCalculateMRouteController(layer, params);
+	}
+
+	public JLrsLastUsedValues getJLrsLastUsedValues(DynObject pluginProperties) {
+		if(params == null){
+			params = new DefaultJLrsLastUsedValues(pluginProperties);
+		}
+		else{
+			params.setParams(pluginProperties);
+		}
+		return params;
+	}
+
+	public JLrsLastUsedValues getJLrsLastUsedValues() {
+		return params;
+	}
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/DefaultProgressDialogView.xml
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/DefaultProgressDialogView.xml	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/DefaultProgressDialogView.xml	(revision 950)
@@ -0,0 +1,212 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<object classname="com.jeta.forms.store.memento.FormPackage">
+ <at name="fileversion">
+  <object classname="com.jeta.forms.store.memento.FormsVersion2">
+   <at name="major">2</at>
+   <at name="minor">0</at>
+   <at name="sub">0</at>
+  </object>
+ </at>
+ <at name="form">
+  <object classname="com.jeta.forms.store.memento.FormMemento">
+   <super classname="com.jeta.forms.store.memento.ComponentMemento">
+    <at name="cellconstraints">
+     <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+      <at name="column">1</at>
+      <at name="row">1</at>
+      <at name="colspan">1</at>
+      <at name="rowspan">1</at>
+      <at name="halign">default</at>
+      <at name="valign">default</at>
+      <at name="insets" object="insets">0,0,0,0</at>
+     </object>
+    </at>
+    <at name="componentclass">com.jeta.forms.gui.form.FormComponent</at>
+   </super>
+   <at name="id">/home/paco/tmp/cosa/DefaultProgressDialogView.xml</at>
+   <at name="rowspecs">CENTER:DEFAULT:NONE,CENTER:61DLU:GROW(1.0),CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE</at>
+   <at name="colspecs">FILL:DEFAULT:NONE,FILL:DEFAULT:GROW(1.0),FILL:DEFAULT:NONE,FILL:DEFAULT:NONE</at>
+   <at name="components">
+    <object classname="java.util.LinkedList">
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">2</at>
+           <at name="colspan">2</at>
+           <at name="rowspan">1</at>
+           <at name="halign">fill</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JPanel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JPanel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="height">12</at>
+            <at name="width">720</at>
+            <at name="name">progressBar</at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">3</at>
+           <at name="row">3</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JButton</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JButton</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">_Close</at>
+            <at name="height">22</at>
+            <at name="width">70</at>
+            <at name="name">btnClose</at>
+            <at name="actionCommand">_Close</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+    </object>
+   </at>
+   <at name="properties">
+    <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+     <at name="classname">com.jeta.forms.gui.form.GridView</at>
+     <at name="properties">
+      <object classname="com.jeta.forms.store.support.PropertyMap">
+       <at name="name"></at>
+       <at name="fill">
+        <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+         <at name="name">fill</at>
+        </object>
+       </at>
+       <at name="scollBars">
+        <object classname="com.jeta.forms.store.properties.ScrollBarsProperty">
+         <at name="name">scollBars</at>
+         <at name="verticalpolicy">21</at>
+         <at name="horizontalpolicy">31</at>
+         <at name="border">
+          <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+           <super classname="com.jeta.forms.store.properties.BorderProperty">
+            <at name="name">border</at>
+           </super>
+           <at name="borders">
+            <object classname="java.util.LinkedList">
+             <item >
+              <at name="value">
+               <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                <super classname="com.jeta.forms.store.properties.BorderProperty">
+                 <at name="name">border</at>
+                </super>
+               </object>
+              </at>
+             </item>
+            </object>
+           </at>
+          </object>
+         </at>
+        </object>
+       </at>
+       <at name="border">
+        <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+         <super classname="com.jeta.forms.store.properties.BorderProperty">
+          <at name="name">border</at>
+         </super>
+         <at name="borders">
+          <object classname="java.util.LinkedList"/>
+         </at>
+        </object>
+       </at>
+      </object>
+     </at>
+    </object>
+   </at>
+   <at name="cellpainters">
+    <object classname="com.jeta.forms.store.support.Matrix">
+     <at name="rows">
+      <object classname="[Ljava.lang.Object;" size="4">
+       <at name="item" index="0">
+        <object classname="[Ljava.lang.Object;" size="4"/>
+       </at>
+       <at name="item" index="1">
+        <object classname="[Ljava.lang.Object;" size="4"/>
+       </at>
+       <at name="item" index="2">
+        <object classname="[Ljava.lang.Object;" size="4"/>
+       </at>
+       <at name="item" index="3">
+        <object classname="[Ljava.lang.Object;" size="4"/>
+       </at>
+      </object>
+     </at>
+    </object>
+   </at>
+   <at name="rowgroups">
+    <object classname="com.jeta.forms.store.memento.FormGroupSet">
+     <at name="groups">
+      <object classname="java.util.HashMap"/>
+     </at>
+    </object>
+   </at>
+   <at name="colgroups">
+    <object classname="com.jeta.forms.store.memento.FormGroupSet">
+     <at name="groups">
+      <object classname="java.util.HashMap"/>
+     </at>
+    </object>
+   </at>
+  </object>
+ </at>
+</object>
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/DefaultJLrsLastUsedValues.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/DefaultJLrsLastUsedValues.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/DefaultJLrsLastUsedValues.java	(revision 950)
@@ -0,0 +1,38 @@
+package org.gvsig.lrs.swing.impl;
+
+import org.gvsig.lrs.swing.api.JLrsLastUsedValues;
+import org.gvsig.tools.dynobject.DynObject;
+
+public class DefaultJLrsLastUsedValues implements JLrsLastUsedValues{
+
+	private DynObject values;
+	
+	public DefaultJLrsLastUsedValues(DynObject val){
+		this.values = val;
+	}
+	
+	public String getPkInicial() {
+		return (String) values.getDynValue("pkInicial");
+	}
+
+	public String getPkFinal() {
+		return (String) values.getDynValue("pkFinal");
+	}
+
+	public void setPkInicial(String ini) {
+		values.setDynValue("pkInicial", ini);
+	}
+
+	public void setPkFinal(String fin) {
+		values.setDynValue("pkFinal", fin);
+	}
+
+	public void setParams(DynObject pluginProperties) {
+		this.values = pluginProperties;
+	}
+
+	public DynObject getParams() {
+		return this.values;
+	}
+
+}

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/DefaultJLrsLastUsedValues.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/DistanceUnitsCellRenderer.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/DistanceUnitsCellRenderer.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/DistanceUnitsCellRenderer.java	(revision 950)
@@ -0,0 +1,34 @@
+/*
+ * Copyright 2015 DiSiD Technologies S.L.L. All rights reserved.
+ *
+ * Project  : DiSiD org.gvsig.lrs.swing.impl
+ * SVN Id   : $Id$
+ */
+package org.gvsig.lrs.swing.impl;
+
+import java.awt.Component;
+
+import javax.swing.DefaultListCellRenderer;
+import javax.swing.JLabel;
+import javax.swing.JList;
+import javax.swing.ListCellRenderer;
+
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.lrs.lib.api.DistanceUnits;
+
+public class DistanceUnitsCellRenderer implements ListCellRenderer{
+
+
+    protected DefaultListCellRenderer defaultRenderer = new DefaultListCellRenderer();
+
+    public Component getListCellRendererComponent(JList list, Object value, int index, boolean isSelected,
+        boolean cellHasFocus) {
+        JLabel renderer =
+            (JLabel) defaultRenderer.getListCellRendererComponent(list, value, index, isSelected, cellHasFocus);
+        if (value instanceof DistanceUnits) {
+            renderer.setText(((DistanceUnits) value).getAbrev());
+        }
+        return renderer;
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/FeatureStoresComboBoxModel.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/FeatureStoresComboBoxModel.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/FeatureStoresComboBoxModel.java	(revision 950)
@@ -0,0 +1,127 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.swing.impl;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.swing.AbstractListModel;
+import javax.swing.MutableComboBoxModel;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+
+/**
+ * @author dmartinez
+ *
+ */
+public class FeatureStoresComboBoxModel extends AbstractListModel<FeatureStore> implements MutableComboBoxModel<FeatureStore> {
+
+
+
+    private static final Logger logger = LoggerFactory.getLogger(FeatureStoresComboBoxModel.class);
+
+    private List<FeatureStore> featureStores;
+    private FeatureStore selected;
+
+    /**
+     *
+     */
+    public FeatureStoresComboBoxModel(List<FeatureStore> featureStores) {
+        this.featureStores = featureStores;
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see javax.swing.ListModel#getSize()
+     */
+    public int getSize() {
+        return featureStores.size();
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see javax.swing.ListModel#getElementAt(int)
+     */
+    public FeatureStore getElementAt(int index) {
+        return featureStores.get(index);
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see javax.swing.ComboBoxModel#setSelectedItem(java.lang.Object)
+     */
+    public void setSelectedItem(final Object anItem) {
+        selected = (FeatureStore) anItem;
+        fireContentsChanged(this, -1, -1);
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see javax.swing.ComboBoxModel#getSelectedItem()
+     */
+    public Object getSelectedItem() {
+        return selected;
+    }
+
+    /* (non-Javadoc)
+     * @see javax.swing.MutableComboBoxModel#addElement(java.lang.Object)
+     */
+    public void addElement(FeatureStore item) {
+        featureStores.add(item);
+        fireIntervalAdded(this, featureStores.size()-1, featureStores.size()-1);
+    }
+
+    /* (non-Javadoc)
+     * @see javax.swing.MutableComboBoxModel#removeElement(java.lang.Object)
+     */
+    public void removeElement(Object obj) {
+        int index = featureStores.indexOf(obj);
+        featureStores.remove(obj);
+        fireIntervalRemoved(this, index, index);
+    }
+
+    /* (non-Javadoc)
+     * @see javax.swing.MutableComboBoxModel#insertElementAt(java.lang.Object, int)
+     */
+    public void insertElementAt(FeatureStore item, int index) {
+        featureStores.add(index, item);
+        fireIntervalAdded(this, index, index);
+    }
+
+    /* (non-Javadoc)
+     * @see javax.swing.MutableComboBoxModel#removeElementAt(int)
+     */
+    public void removeElementAt(int index) {
+        featureStores.remove(index);
+        fireIntervalRemoved(this, index, index);
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsEditRouteCalibrationParamsView.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsEditRouteCalibrationParamsView.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsEditRouteCalibrationParamsView.java	(revision 950)
@@ -0,0 +1,228 @@
+package org.gvsig.lrs.swing.impl;
+
+import com.jeta.open.i18n.I18NUtils;
+import com.jgoodies.forms.layout.CellConstraints;
+import com.jgoodies.forms.layout.FormLayout;
+import java.awt.BorderLayout;
+import java.awt.Color;
+import java.awt.ComponentOrientation;
+import java.awt.Container;
+import java.awt.Dimension;
+import javax.swing.Box;
+import javax.swing.ImageIcon;
+import javax.swing.JButton;
+import javax.swing.JComboBox;
+import javax.swing.JFrame;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+import javax.swing.JScrollPane;
+import javax.swing.JTable;
+import javax.swing.JTextField;
+
+
+public class JLrsEditRouteCalibrationParamsView extends JPanel
+{
+   JLabel lblIdRouteField = new JLabel();
+   JLabel lblMinimum = new JLabel();
+   JLabel lblMaximum = new JLabel();
+   JTable tblLayerInfo = new JTable();
+   JButton btnInvert = new JButton();
+   JButton btnRecalibrate = new JButton();
+   JButton btnApply = new JButton();
+   JButton btnAccept = new JButton();
+   JButton btnCancel = new JButton();
+   JComboBox cmbRoute = new JComboBox();
+   JTextField txtMaximum = new JTextField();
+   JTextField txtMinimum = new JTextField();
+   JComboBox cmbStretch = new JComboBox();
+
+   /**
+    * Default constructor
+    */
+   public JLrsEditRouteCalibrationParamsView()
+   {
+      initializePanel();
+   }
+
+   /**
+    * Adds fill components to empty cells in the first row and first column of the grid.
+    * This ensures that the grid spacing will be the same as shown in the designer.
+    * @param cols an array of column indices in the first row where fill components should be added.
+    * @param rows an array of row indices in the first column where fill components should be added.
+    */
+   void addFillComponents( Container panel, int[] cols, int[] rows )
+   {
+      Dimension filler = new Dimension(10,10);
+
+      boolean filled_cell_11 = false;
+      CellConstraints cc = new CellConstraints();
+      if ( cols.length > 0 && rows.length > 0 )
+      {
+         if ( cols[0] == 1 && rows[0] == 1 )
+         {
+            /** add a rigid area  */
+            panel.add( Box.createRigidArea( filler ), cc.xy(1,1) );
+            filled_cell_11 = true;
+         }
+      }
+
+      for( int index = 0; index < cols.length; index++ )
+      {
+         if ( cols[index] == 1 && filled_cell_11 )
+         {
+            continue;
+         }
+         panel.add( Box.createRigidArea( filler ), cc.xy(cols[index],1) );
+      }
+
+      for( int index = 0; index < rows.length; index++ )
+      {
+         if ( rows[index] == 1 && filled_cell_11 )
+         {
+            continue;
+         }
+         panel.add( Box.createRigidArea( filler ), cc.xy(1,rows[index]) );
+      }
+
+   }
+
+   /**
+    * Helper method to load an image file from the CLASSPATH
+    * @param imageName the package and name of the file to load relative to the CLASSPATH
+    * @return an ImageIcon instance with the specified image file
+    * @throws IllegalArgumentException if the image resource cannot be loaded.
+    */
+   public ImageIcon loadImage( String imageName )
+   {
+      try
+      {
+         ClassLoader classloader = getClass().getClassLoader();
+         java.net.URL url = classloader.getResource( imageName );
+         if ( url != null )
+         {
+            ImageIcon icon = new ImageIcon( url );
+            return icon;
+         }
+      }
+      catch( Exception e )
+      {
+         e.printStackTrace();
+      }
+      throw new IllegalArgumentException( "Unable to load image: " + imageName );
+   }
+
+   /**
+    * Method for recalculating the component orientation for 
+    * right-to-left Locales.
+    * @param orientation the component orientation to be applied
+    */
+   public void applyComponentOrientation( ComponentOrientation orientation )
+   {
+      // Not yet implemented...
+      // I18NUtils.applyComponentOrientation(this, orientation);
+      super.applyComponentOrientation(orientation);
+   }
+
+   public JPanel createPanel()
+   {
+      JPanel jpanel1 = new JPanel();
+      FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:NONE,FILL:MAX(12DLU;DEFAULT):NONE,FILL:4DLU:NONE,FILL:120PX:NONE,FILL:4DLU:NONE,FILL:120PX:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:MAX(73PX;DEFAULT):GROW(1.0),FILL:4DLU:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:MAX(74PX;DEFAULT):GROW(1.0),FILL:DEFAULT:NONE","CENTER:DEFAULT:NONE,CENTER:MAX(12DLU;DEFAULT):GROW(1.0),CENTER:2DLU:NONE,CENTER:DEFAULT:NONE,CENTER:4DLU:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE");
+      CellConstraints cc = new CellConstraints();
+      jpanel1.setLayout(formlayout1);
+
+      lblIdRouteField.setName("lblIdRouteField");
+      lblIdRouteField.setText("id_route_field");
+      jpanel1.add(lblIdRouteField,cc.xy(2,4));
+
+      lblMinimum.setName("lblMinimum");
+      lblMinimum.setText("minimum");
+      jpanel1.add(lblMinimum,cc.xy(8,4));
+
+      lblMaximum.setName("lblMaximum");
+      lblMaximum.setText("maximum");
+      jpanel1.add(lblMaximum,cc.xy(12,4));
+
+      tblLayerInfo.setName("tblLayerInfo");
+      JScrollPane jscrollpane1 = new JScrollPane();
+      jscrollpane1.setViewportView(tblLayerInfo);
+      jscrollpane1.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED);
+      jscrollpane1.setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED);
+      jpanel1.add(jscrollpane1,new CellConstraints(2,2,13,1,CellConstraints.DEFAULT,CellConstraints.FILL));
+
+      jpanel1.add(createPanel1(),new CellConstraints(2,6,13,1,CellConstraints.RIGHT,CellConstraints.DEFAULT));
+      jpanel1.add(createPanel2(),new CellConstraints(2,8,13,1,CellConstraints.RIGHT,CellConstraints.DEFAULT));
+      cmbRoute.setName("cmbRoute");
+      jpanel1.add(cmbRoute,cc.xy(4,4));
+
+      txtMaximum.setName("txtMaximum");
+      jpanel1.add(txtMaximum,cc.xy(14,4));
+
+      txtMinimum.setName("txtMinimum");
+      jpanel1.add(txtMinimum,cc.xy(10,4));
+
+      cmbStretch.setName("cmbStretch");
+      jpanel1.add(cmbStretch,cc.xy(6,4));
+
+      addFillComponents(jpanel1,new int[]{ 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15 },new int[]{ 1,2,3,4,5,6,7,8,9 });
+      return jpanel1;
+   }
+
+   public JPanel createPanel1()
+   {
+      JPanel jpanel1 = new JPanel();
+      FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE,FILL:DEFAULT:NONE,FILL:DEFAULT:NONE","CENTER:DEFAULT:NONE");
+      CellConstraints cc = new CellConstraints();
+      jpanel1.setLayout(formlayout1);
+
+      btnInvert.setActionCommand("_Invert");
+      btnInvert.setName("btnInvert");
+      btnInvert.setText("_Invert");
+      jpanel1.add(btnInvert,new CellConstraints(1,1,1,1,CellConstraints.CENTER,CellConstraints.DEFAULT));
+
+      btnRecalibrate.setActionCommand("_Apply");
+      btnRecalibrate.setForeground(new Color(63,63,63));
+      btnRecalibrate.setName("btnRecalibrate");
+      btnRecalibrate.setText("_Recalibrate");
+      jpanel1.add(btnRecalibrate,cc.xy(5,1));
+
+      btnApply.setActionCommand("_Apply");
+      btnApply.setName("btnApply");
+      btnApply.setText("_Recalculate_proportionally");
+      jpanel1.add(btnApply,cc.xy(3,1));
+
+      addFillComponents(jpanel1,new int[]{ 2,4 },new int[0]);
+      return jpanel1;
+   }
+
+   public JPanel createPanel2()
+   {
+      JPanel jpanel1 = new JPanel();
+      FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE","CENTER:DEFAULT:NONE");
+      CellConstraints cc = new CellConstraints();
+      jpanel1.setLayout(formlayout1);
+
+      btnAccept.setActionCommand("_Accept");
+      btnAccept.setName("btnAccept");
+      btnAccept.setText("_Accept");
+      jpanel1.add(btnAccept,new CellConstraints(1,1,1,1,CellConstraints.CENTER,CellConstraints.DEFAULT));
+
+      btnCancel.setActionCommand("_Cancel");
+      btnCancel.setName("btnCancel");
+      btnCancel.setText("_Cancel");
+      jpanel1.add(btnCancel,cc.xy(3,1));
+
+      addFillComponents(jpanel1,new int[]{ 2 },new int[0]);
+      return jpanel1;
+   }
+
+   /**
+    * Initializer
+    */
+   protected void initializePanel()
+   {
+      setLayout(new BorderLayout());
+      add(createPanel(), BorderLayout.CENTER);
+   }
+
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsEditRouteCalibrationSelectIdRouteController.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsEditRouteCalibrationSelectIdRouteController.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsEditRouteCalibrationSelectIdRouteController.java	(revision 950)
@@ -0,0 +1,262 @@
+/*
+ * Copyright 2015 DiSiD Technologies S.L.L. All rights reserved.
+ *
+ * Project  : DiSiD org.gvsig.lrs.swing.impl
+ * SVN Id   : $Id$
+ */
+package org.gvsig.lrs.swing.impl;
+
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.util.Locale;
+
+import javax.swing.JComponent;
+import javax.swing.ListCellRenderer;
+
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.dal.exception.ReadException;
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.feature.FeatureType;
+import org.gvsig.fmap.geom.DataTypes;
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.lrs.lib.api.LrsAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsAlgorithmsLocator;
+import org.gvsig.lrs.lib.api.LrsAlgorithmsManager;
+import org.gvsig.lrs.lib.api.LrsEditRouteCalibrationAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsEditRouteCalibrationSelectIdRouteAlgorithmParams;
+import org.gvsig.lrs.lib.api.exceptions.LrsGettingParametersException;
+import org.gvsig.lrs.lib.api.exceptions.LrsNeededParameterException;
+import org.gvsig.lrs.swing.api.JLrsAlgorithmParams;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.i18n.I18nManager;
+import org.gvsig.tools.swing.api.ActionListenerSupport;
+import org.gvsig.tools.swing.api.ToolsSwingLocator;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public class JLrsEditRouteCalibrationSelectIdRouteController extends
+    JLrsEditRouteCalibrationSelectIdRouteView implements JLrsAlgorithmParams {
+
+    /**
+     *
+     */
+    private static final long serialVersionUID = 7762321351616631999L;
+
+    private static final Logger logger = LoggerFactory
+        .getLogger(JLrsEditRouteCalibrationSelectIdRouteController.class);
+
+    private boolean canceled;
+    private ActionListenerSupport listeners =
+        ToolsSwingLocator.getToolsSwingManager().createActionListenerSupport();
+
+    private FLyrVect layer;
+
+    /**
+     * @param layer
+     * @throws LrsNeededParameterException
+     *
+     */
+    public JLrsEditRouteCalibrationSelectIdRouteController(FLyrVect layer,
+        LrsAlgorithmParams params) throws LrsNeededParameterException {
+        super();
+        this.layer = layer;
+        initComponents();
+        translate();
+        setParams(params);
+    }
+
+    public void addActionListener(ActionListener listener) {
+        listeners.addActionListener(listener);
+    }
+
+    public void removeActionListener(ActionListener listener) {
+        listeners.removeActionListener(listener);
+    }
+
+    private void translate() {
+        I18nManager i18nManager = ToolsLocator.getI18nManager();
+        lblIdRouteField
+            .setText(i18nManager.getTranslation(lblIdRouteField.getText()));
+        btnAccept.setText(i18nManager.getTranslation(btnAccept.getText()));
+        btnCancel.setText(i18nManager.getTranslation(btnCancel.getText()));
+
+    }
+
+    /**
+    *
+    */
+    public void setLocate(Locale locale) {
+        Locale l = super.getLocale();
+        if (!l.equals(locale)) {
+            translate();
+        }
+        super.setLocale(locale);
+    }
+
+    /**
+     * Validates it is an editable curve layer with at least 1 non-geometric
+     * field
+     * if it is not correct throws an exception
+     *
+     * @throws LrsNeededParameterException
+     * @throws ReadException
+     */
+    public static void validateLayer(FLayer layer)
+        throws LrsNeededParameterException {
+        logger.debug("Validating layer for Edit Route");
+        if (layer == null) {
+            logger.error("A layer is needed");
+            throw new LrsNeededParameterException("a_layer_is_needed", null);
+        }
+
+        if (!layer.isEditing()) {
+            logger.error("An editing layer is needed");
+            throw new LrsNeededParameterException("an_editing_layer_is_needed",
+                null);
+        }
+
+        if (!JLrsUtils.isMlayerWithNonGeomField(layer)) {
+            logger.error("Impossible to find the layers needed");
+            throw new LrsNeededParameterException(
+                "impossible_to_find_needed_layer", null);
+        }
+    }
+
+    /**
+     * @throws LrsNeededParameterException
+     */
+    private void initComponents() throws LrsNeededParameterException {
+
+        validateLayer(layer);
+
+        if (layer instanceof FLyrVect) {
+            initCmbIdRouteField((FLyrVect)layer);
+        }
+
+        this.btnAccept.addActionListener(new ActionListener() {
+
+            public void actionPerformed(ActionEvent e) {
+                canceled = false;
+                doClose();
+                listeners.fireActionEvent(new ActionEvent(
+                    JLrsEditRouteCalibrationSelectIdRouteController.this, 0,
+                    "accept"));
+
+            }
+        });
+
+        this.btnCancel.addActionListener(new ActionListener() {
+
+            public void actionPerformed(ActionEvent e) {
+                canceled = true;
+                doClose();
+                listeners.fireActionEvent(new ActionEvent(
+                    JLrsEditRouteCalibrationSelectIdRouteController.this, 0,
+                    "cancel"));
+            }
+        });
+
+        setVisibleAceptCancel(false);
+        canceled = false;
+    }
+
+    private void initCmbIdRouteField(FLyrVect layer){
+        // Modelos de los combos
+        FeatureAttributeDescriptorsComboBoxModel idRouteFieldComboBoxModel =
+            new FeatureAttributeDescriptorsComboBoxModel();
+
+        // Renderer para los combos de attributeDescriptors
+        ListCellRenderer featureAttributeDescriptorCellRenderer =
+            new FLayersAttributeDescriptorCellRenderer();
+        // asignación de renderers y modelos
+        cmbIdRouteField.setRenderer(featureAttributeDescriptorCellRenderer);
+        cmbIdRouteField.setModel(idRouteFieldComboBoxModel);
+
+        FeatureStore featureStore = layer.getFeatureStore();
+        try {
+            FeatureType type = featureStore.getDefaultFeatureType();
+            FeatureAttributeDescriptor[] attributeDescriptors = type.getAttributeDescriptors();
+            for (int i = 0; i < attributeDescriptors.length; i++) {
+                FeatureAttributeDescriptor featureAttributeDescriptor = attributeDescriptors[i];
+                if (featureAttributeDescriptor.getDataType().getType() != DataTypes.GEOMETRY) {
+                    logger.info(new StringBuilder().append("Adding field ")
+                        .append(featureAttributeDescriptor.getName()).toString());
+                    cmbIdRouteField.addItem(featureAttributeDescriptor);
+                }
+            }
+
+        } catch (DataException e1) {
+            logger.warn(
+                new StringBuilder().append("Error getting default feature type from layer ").append(layer.getName())
+                    .toString(), e1);
+        }
+    }
+
+    private void doClose() {
+        this.setVisible(false);
+    }
+
+    public boolean isCanceled() {
+        return this.canceled;
+    }
+
+    public void setVisibleAceptCancel(boolean visible) {
+        this.btnAccept.setVisible(visible);
+        this.btnCancel.setVisible(visible);
+    }
+
+    public boolean getVisibleAceptCancel() {
+        return this.btnAccept.isVisible();
+    }
+
+    public JComponent asJComponent() {
+        return this;
+    }
+
+    public LrsAlgorithmParams getParams()
+        throws LrsGettingParametersException, LrsNeededParameterException {
+        LrsAlgorithmsManager manager =
+            LrsAlgorithmsLocator.getLrsAlgorithmsManager();
+        LrsEditRouteCalibrationSelectIdRouteAlgorithmParams params =
+            manager.createLrsEditRouteCalibrationSelectIdRouteAlgorithmParams();
+            // Recorrer todo del interfaz y rellenar los parametros
+
+        // cmbIdRouteField
+        if (!(this.cmbIdRouteField
+            .getSelectedItem() instanceof FeatureAttributeDescriptor)) {
+            logger.error("Error getting selected item from cmbIdRouteField");
+            throw new LrsGettingParametersException(
+                "error_getting_selected_item_from_cmbIdRouteField", null);
+        }
+        FeatureAttributeDescriptor idRouteField =
+            (FeatureAttributeDescriptor) this.cmbIdRouteField.getSelectedItem();
+        if (idRouteField == null) {
+            throw new LrsNeededParameterException(
+                "need_to_select_a_route_identifier_field", null);
+        }
+        params.setIdRouteField(idRouteField);
+
+        return params;
+    }
+
+    public void setParams(LrsAlgorithmParams params) {
+        if (params == null) {
+            clear();
+            return;
+        }
+        // Rellena los campos con los valores de params
+        LrsEditRouteCalibrationSelectIdRouteAlgorithmParams parameters =
+            (LrsEditRouteCalibrationSelectIdRouteAlgorithmParams) params;
+
+        this.cmbIdRouteField.setSelectedItem(parameters.getIdRouteField());
+
+    }
+
+    public void clear() {
+        this.cmbIdRouteField.setSelectedIndex(0);
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsEditRouteCalibrationController.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsEditRouteCalibrationController.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsEditRouteCalibrationController.java	(revision 950)
@@ -0,0 +1,825 @@
+/*
+ * Copyright 2015 DiSiD Technologies S.L.L. All rights reserved.
+ *
+ * Project  : DiSiD org.gvsig.lrs.swing.impl
+ * SVN Id   : $Id$
+ */
+package org.gvsig.lrs.swing.impl;
+
+import java.awt.Color;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.awt.event.ItemEvent;
+import java.text.MessageFormat;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Locale;
+import java.util.Map;
+import javax.swing.ComboBoxModel;
+import javax.swing.DefaultComboBoxModel;
+import javax.swing.JComponent;
+import javax.swing.SwingUtilities;
+import javax.swing.event.DocumentEvent;
+import javax.swing.event.DocumentListener;
+import javax.swing.event.ListSelectionEvent;
+import javax.swing.event.ListSelectionListener;
+import javax.swing.event.TableModelEvent;
+import javax.swing.table.TableModel;
+import org.cresques.cts.ICoordTrans;
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.dal.exception.ReadException;
+import org.gvsig.fmap.dal.feature.Feature;
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureReference;
+import org.gvsig.fmap.dal.feature.FeatureSelection;
+import org.gvsig.fmap.dal.feature.FeatureSet;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.feature.FeatureType;
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.geom.GeometryLocator;
+import org.gvsig.fmap.geom.GeometryManager;
+import org.gvsig.fmap.geom.exception.CreateGeometryException;
+import org.gvsig.fmap.geom.primitive.Point;
+import org.gvsig.fmap.mapcontext.MapContext;
+import org.gvsig.fmap.mapcontext.MapContextLocator;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.fmap.mapcontext.layers.vectorial.GraphicLayer;
+import org.gvsig.fmap.mapcontext.rendering.symbols.ISymbol;
+import org.gvsig.fmap.mapcontext.rendering.symbols.SymbolManager;
+import org.gvsig.lrs.lib.api.LrsAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsAlgorithmsLocator;
+import org.gvsig.lrs.lib.api.LrsAlgorithmsManager;
+import org.gvsig.lrs.lib.api.LrsEditRouteCalibrationAlgorithmParams;
+import org.gvsig.lrs.lib.api.MeasuresCalculator;
+import org.gvsig.lrs.lib.api.exceptions.LrsGettingParametersException;
+import org.gvsig.lrs.lib.api.exceptions.LrsNeededParameterException;
+import org.gvsig.lrs.swing.api.JLrsAlgorithmParams;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.dispose.DisposableIterator;
+import org.gvsig.tools.dispose.DisposeUtils;
+import org.gvsig.tools.exception.BaseException;
+import org.gvsig.tools.i18n.I18nManager;
+import org.gvsig.tools.swing.api.ActionListenerSupport;
+import org.gvsig.tools.swing.api.ToolsSwingLocator;
+import org.gvsig.tools.util.LabeledValue;
+import org.gvsig.tools.util.LabeledValueImpl;
+import org.gvsig.tools.visitor.VisitCanceledException;
+import org.gvsig.tools.visitor.Visitor;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+public class JLrsEditRouteCalibrationController extends
+    JLrsEditRouteCalibrationParamsView implements JLrsAlgorithmParams {
+
+    /**
+     *
+     */
+    private static final long serialVersionUID = 7762321351616631999L;
+
+    private static final Logger logger = LoggerFactory
+        .getLogger(JLrsEditRouteCalibrationController.class);
+
+    private boolean canceled;
+    private boolean hasWarnings;
+    private List<String> warnings;
+    private final ActionListenerSupport listeners =
+        ToolsSwingLocator.getToolsSwingManager().createActionListenerSupport();
+
+    private final FLyrVect layer;
+    private FeatureAttributeDescriptor fieldIdRoute;
+    private FeatureSet selectedFeatures;
+    private Feature editedFeature;
+    private Double editedFeatureMax;
+    private Double editedFeatureMin;
+    private final MapContext mapContext;
+    GraphicLayer graphics;
+    private int idMarkerSymbol;
+    private int idLineSymbol;
+    
+    private final Map<FeatureReference, List<Double>> mCoordinatesByFeature;
+
+    public static final String EDIT_ROUTECALIBRATION_GRAPHICS_ID = "EditRouteCalibration";
+
+    /**
+     * @param layer
+     * @param mapContext
+     * @param fieldIdRoute
+     * @param params
+     * @throws LrsNeededParameterException
+     * @throws LrsGettingParametersException
+     *
+     */
+    public JLrsEditRouteCalibrationController(FLyrVect layer, MapContext mapContext, FeatureAttributeDescriptor fieldIdRoute,
+        LrsAlgorithmParams params) throws LrsNeededParameterException, LrsGettingParametersException {
+        super();
+        this.layer = layer;
+        this.fieldIdRoute=fieldIdRoute;
+        this.mapContext = mapContext;
+        mCoordinatesByFeature = new HashMap<>();
+        initializeGraphics(mapContext);
+        initComponents();
+        translate();
+        setParams(params);
+
+    }
+
+    /**
+     * @param mapContext
+     */
+    private void initializeGraphics(MapContext mapContext) {
+        this.graphics = mapContext.getGraphicsLayer();
+        SymbolManager symbolManager = MapContextLocator.getSymbolManager();
+
+        ISymbol markerSymbol = symbolManager.createSymbol(Geometry.TYPES.POINT, Color.RED);
+        ISymbol lineSymbol = symbolManager.createSymbol(Geometry.TYPES.CURVE, Color.YELLOW);
+        this.idLineSymbol = this.graphics.addSymbol(lineSymbol);
+        this.idMarkerSymbol = this.graphics.addSymbol(markerSymbol);
+    }
+
+    @Override
+    public void addActionListener(ActionListener listener) {
+        listeners.addActionListener(listener);
+    }
+
+    @Override
+    public void removeActionListener(ActionListener listener) {
+        listeners.removeActionListener(listener);
+    }
+
+    private void translate() {
+        
+        I18nManager i18nManager = ToolsLocator.getI18nManager();
+        lblIdRouteField
+            .setText(i18nManager.getTranslation(lblIdRouteField.getText()));
+        lblMaximum.setText(i18nManager.getTranslation(lblMaximum.getText()));
+        lblMinimum.setText(i18nManager.getTranslation(lblMinimum.getText()));
+        btnInvert.setText(i18nManager.getTranslation(btnInvert.getText()));
+        btnApply.setText(i18nManager.getTranslation(btnApply.getText()));
+        btnAccept.setText(i18nManager.getTranslation(btnAccept.getText()));
+        btnCancel.setText(i18nManager.getTranslation(btnCancel.getText()));
+        btnRecalibrate.setText(i18nManager.getTranslation(btnRecalibrate.getText()));
+    }
+
+    /**
+    *
+     * @param locale
+    */
+    public void setLocate(Locale locale) {
+        Locale l = super.getLocale();
+        if (!l.equals(locale)) {
+            translate();
+        }
+        super.setLocale(locale);
+    }
+
+    /**
+     * Validates it is an editable curve layer with at least 1 non-geometric
+     * field
+     * if it is not correct throws an exception
+     *
+     * @param layer
+     * @throws LrsNeededParameterException
+     */
+    public static void validateLayer(FLayer layer)
+        throws LrsNeededParameterException {
+        logger.debug("Validating layer for Edit Route");
+        if (layer == null) {
+            logger.error("A layer is needed");
+            throw new LrsNeededParameterException("a_layer_is_needed", null);
+        }
+
+        if (!layer.isEditing()) {
+            logger.error("An editing layer is needed");
+            throw new LrsNeededParameterException("an_editing_layer_is_needed",
+                null);
+        }
+
+        if (!JLrsUtils.isMlayerWithNonGeomField(layer)) {
+            logger.error("Impossible to find the layers needed");
+            throw new LrsNeededParameterException(
+                "impossible_to_find_needed_layer", null);
+        }
+    }
+
+    /**
+     * Checks if the selectedIdRoute is contained in the layer
+     *
+     * @throws LrsNeededParameterException
+     * @throws ReadException
+     */
+    public static void validateSelectedIdRoute(FLayer layer, FeatureAttributeDescriptor selectedIdRoute)
+        throws LrsNeededParameterException {
+        logger.debug("Validating selected id route for Edit Route");
+        if (selectedIdRoute == null) {
+            logger.error("A selectedIdRoute is needed");
+            throw new LrsNeededParameterException("a_selectedIdRoute_is_needed", null);
+        }
+
+        if (!isCorrectIdRoute(layer,selectedIdRoute)) {
+            logger.error("Selected id route is not contained in editing layer");
+            throw new LrsNeededParameterException(
+                "route_not_contained", null);
+        }
+    }
+
+    public void validateSelectedFeatures() throws LrsGettingParametersException{
+        //TODO added to Test
+        if (selectedFeatures!=null) return;
+
+        final List<String> routeNames=new ArrayList<>();
+        try {
+            selectedFeatures.accept((Object obj) -> {
+                if(obj instanceof Feature){
+                    Feature feature=(Feature)obj;
+                    if (feature.get(fieldIdRoute.getName()) instanceof String){
+                        String routeName=(String)feature.get(fieldIdRoute.getName());
+                        if (routeNames.contains(routeName)){
+                            logger.error("Duplicate route name found");
+                            throw new LrsGettingParametersException("Duplicate route name found",null);
+                        }else{
+                            routeNames.add(routeName);
+                        }
+                    }
+                }
+            });
+        } catch (BaseException e1) {
+            logger.error("Impossible to validate selected features",e1);
+            throw new LrsGettingParametersException("Impossible to validate selected features", e1);
+        }
+    }
+
+    /**
+     * @throws LrsNeededParameterException
+     * @throws LrsGettingParametersException
+     */
+    private void initComponents() throws LrsNeededParameterException, LrsGettingParametersException {
+
+        validateLayer(layer);
+        validateSelectedIdRoute(layer, fieldIdRoute);
+
+        selectedFeatures=getSelectedFeatures(layer);
+        validateSelectedFeatures();
+
+        String selectedRouteName = initCombosRouteAndStretch();
+
+        routeChanged(selectedRouteName);
+
+        this.btnRecalibrate.addActionListener((ActionEvent e) -> {
+            canceled = false;
+            doRecalibrate();
+        });
+
+        this.btnApply.addActionListener((ActionEvent e) -> {
+            canceled = false;
+            doApply();
+        });
+
+        this.btnInvert.addActionListener((ActionEvent e) -> {
+            canceled = false;
+            doInvert();
+        });
+
+        this.btnAccept.addActionListener((ActionEvent e) -> {
+            canceled = false;
+            validateData();
+            doClose();
+            listeners.fireActionEvent(new ActionEvent(
+                    JLrsEditRouteCalibrationController.this, 0,
+                    "accept"));
+        });
+
+        this.btnCancel.addActionListener((ActionEvent e) -> {
+            canceled = true;
+            doClose();
+            listeners.fireActionEvent(new ActionEvent(
+                    JLrsEditRouteCalibrationController.this, 0,
+                    "cancel"));
+        });
+
+        this.tblLayerInfo.getSelectionModel().addListSelectionListener((ListSelectionEvent e) -> {
+            GeometryManager geomManager = GeometryLocator.getGeometryManager();
+            
+            graphics.removeGraphics(EDIT_ROUTECALIBRATION_GRAPHICS_ID);
+            showEditingRoute();
+            int[] selectedRows = tblLayerInfo.getSelectedRows();
+            for (int i = 0; i < selectedRows.length; i++) {
+                Point point = null;
+                try {
+                    point = (Point) geomManager.create(Geometry.TYPES.POINT, Geometry.SUBTYPES.GEOM2D);
+                    point.setX((Double)tblLayerInfo.getValueAt(selectedRows[i], 2));
+                    point.setY((Double)tblLayerInfo.getValueAt(selectedRows[i], 3));
+                    
+                    ICoordTrans ct = layer.getCoordTrans();
+                    point.reProject(ct);
+                    
+                } catch (CreateGeometryException e1) {
+                    logger.warn("Can't create a point", e);
+                }
+                if(point != null){
+                    graphics.addGraphic(
+                            EDIT_ROUTECALIBRATION_GRAPHICS_ID,
+                            point,
+                            idMarkerSymbol);
+                }
+            }
+            mapContext.invalidate();
+        });
+
+        setVisibleAceptCancel(false);
+        canceled = false;
+    }
+
+    private void reloadMaxMin(EditRouteCalibrationTableModel tableModel){
+        this.txtMaximum.getDocument().addDocumentListener(new DocumentListener() {
+            @Override
+            public void changedUpdate(DocumentEvent e) {
+                enableApply(e);
+            }
+            @Override
+            public void removeUpdate(DocumentEvent e) {
+                enableApply(e);
+            }
+            @Override
+            public void insertUpdate(DocumentEvent e) {
+                enableApply(e);
+            }
+
+            public void enableApply(DocumentEvent e) {
+                try {
+                    e.getType();
+                    Double max = Double.valueOf(txtMaximum.getText());
+                    Double min = Double.valueOf(txtMinimum.getText());
+                } catch (Exception ex) {
+                    btnApply.setEnabled(false);
+                    return;
+                }
+                btnApply.setEnabled(true);
+            }
+          });
+
+        this.txtMinimum.getDocument().addDocumentListener(new DocumentListener() {
+            @Override
+            public void changedUpdate(DocumentEvent e) {
+                enableApply(e);
+            }
+            @Override
+            public void removeUpdate(DocumentEvent e) {
+                enableApply(e);
+            }
+            @Override
+            public void insertUpdate(DocumentEvent e) {
+                enableApply(e);
+            }
+
+            public void enableApply(DocumentEvent e) {
+                try{
+                    Double max = Double.valueOf(txtMaximum.getText());
+                    Double min = Double.valueOf(txtMinimum.getText());
+                }catch(Exception ex){
+                    btnApply.setEnabled(false);
+                    return;
+                }
+                btnApply.setEnabled(true);
+            }
+          });
+
+        editedFeatureMax=tableModel.getMaxValue();
+        editedFeatureMin=tableModel.getMinValue();
+        this.txtMaximum.setText(editedFeatureMax.toString());
+        this.txtMinimum.setText(editedFeatureMin.toString());
+    }
+
+    private void doInvert(){
+        String max = txtMaximum.getText();
+        String min = txtMinimum.getText();
+
+        txtMaximum.setText(min);
+        txtMinimum.setText(max);
+    }
+
+    private void doApply(){
+        reloadTableModel();
+        EditRouteCalibrationTableModel tableModel=(EditRouteCalibrationTableModel)tblLayerInfo.getModel();
+        Object[][] data=tableModel.getData();
+        Double newMax= Double.valueOf(txtMaximum.getText());
+        Double newMin= Double.valueOf(txtMinimum.getText());
+
+        Double oldMin=editedFeatureMin;
+        Double oldMax=editedFeatureMax;
+
+        if (data!=null&&data.length>1){
+            for (int i=0;data.length-1>=i;i++){
+                Double mCoordinate =(Double)data[i][EditRouteCalibrationTableModel.COLUMN_MCOORDINATE];
+                Double newMCoordinate=calculateNewM(oldMax, oldMin, newMax, newMin, mCoordinate);
+                data[i][EditRouteCalibrationTableModel.COLUMN_MCOORDINATE]=newMCoordinate;
+            }
+        }
+        tableModel.setData(data);
+        this.tblLayerInfo.setModel(tableModel);
+        this.tblLayerInfo.invalidate();
+        this.tblLayerInfo.repaint();
+        fetchCoordinates();
+    }
+
+    private void doRecalibrate(){
+        reloadTableModel();
+        EditRouteCalibrationTableModel tableModel=(EditRouteCalibrationTableModel)tblLayerInfo.getModel();
+        Object[][] data=tableModel.getData();
+        Double newMax= Double.valueOf(txtMaximum.getText());
+        Double newMin= Double.valueOf(txtMinimum.getText());
+
+        LrsAlgorithmsManager lrsAlgMng = LrsAlgorithmsLocator.getLrsAlgorithmsManager();
+        MeasuresCalculator mcalc = lrsAlgMng.createMeasuresCalculator(this.editedFeature.getDefaultGeometry(), false);
+        mcalc.setFirstMeasure(newMin);
+        mcalc.setLastMeasure(newMax);
+        mcalc.calculate();
+        Geometry mgeom = mcalc.getResult();
+        
+        reloadTableModel(mgeom);
+
+        fetchCoordinates();
+    }
+
+
+    private double calculateNewM(double oldMax, double oldMin, double newMax, double newMin, double mCoordinate){
+        double result;
+        if (oldMax==oldMin){
+            return Double.POSITIVE_INFINITY;
+        }
+        result=((newMax-newMin)*(mCoordinate-oldMin)/(oldMax-oldMin))+newMin;
+
+        return result;
+    }
+
+
+    private void cellUpdated(int row){
+        EditRouteCalibrationTableModel tableModel=(EditRouteCalibrationTableModel)tblLayerInfo.getModel();
+        Object[][] data=tableModel.getData();
+        Double newValue=tableModel.getValueUpdated();
+
+        data[row][EditRouteCalibrationTableModel.COLUMN_MCOORDINATE]=newValue;
+
+        tableModel.setData(data);
+        this.tblLayerInfo.setModel(tableModel);
+        this.tblLayerInfo.invalidate();
+        this.tblLayerInfo.repaint();
+    }
+
+    private String initCombosRouteAndStretch() {
+        final List<String> routeNames=new ArrayList<>();
+        try {
+            selectedFeatures.accept((Object obj) -> {
+                if(obj instanceof Feature){
+                    Feature feature=(Feature)obj;
+                    if (feature.get(fieldIdRoute.getName()) instanceof String){
+                        String routeName=(String)feature.get(fieldIdRoute.getName());
+                        if (!routeNames.contains(routeName)){
+                            routeNames.add(routeName);
+                        }
+                    }
+                }
+            });
+        } catch (BaseException e1) {
+            logger.error("Impossible to obtain route names to fill ComboBox",e1);
+        }
+
+        cmbStretch.addItemListener((ItemEvent event) -> {
+            if (event.getStateChange() == ItemEvent.SELECTED) {
+                LabeledValue item = (LabeledValue) event.getItem();
+                SwingUtilities.invokeLater(() -> {stretchChanged((FeatureReference) item.getValue());});
+            }
+        });
+        
+        String[] routeNamesArray = routeNames.toArray(new String[0]);
+        ComboBoxModel<String> routeModel =
+            new DefaultComboBoxModel<>(routeNamesArray);
+        cmbRoute.setModel(routeModel);
+
+        cmbRoute.addItemListener((ItemEvent event) -> {
+            if (event.getStateChange() == ItemEvent.SELECTED) {
+                String item = (String) event.getItem();
+                SwingUtilities.invokeLater(() -> {routeChanged((String)item);});
+            }
+        });
+
+
+        return (String)cmbRoute.getSelectedItem();
+    }
+
+
+    private void routeChanged(String selectedRouteName) {
+
+        final String routeName = selectedRouteName;
+
+        DefaultComboBoxModel<LabeledValue> stretchComboModel = new DefaultComboBoxModel<>();
+        I18nManager i18n = ToolsLocator.getI18nManager();
+        DisposableIterator it = null;
+        try {
+            it = selectedFeatures.fastIterator();
+            int i = 1;
+            while (it.hasNext()) {
+                Feature feature = (Feature) it.next();
+                if (feature.get(fieldIdRoute.getName()) instanceof String
+                    && routeName.equals((String) feature.get(fieldIdRoute.getName()))) {
+                    LabeledValue<FeatureReference> item = new LabeledValueImpl(
+                            i18n.getTranslation("_Stretch_{0}",new String[] {String.valueOf(i)}),
+                            feature.getReference()
+                    );
+                    stretchComboModel.addElement(item);
+                    i++;
+                }
+            }
+            if (stretchComboModel.getSize() > 0) {
+                cmbStretch.setEnabled(true);
+                cmbStretch.setModel(stretchComboModel);
+                cmbStretch.setSelectedIndex(0);
+                stretchChanged(
+                        (FeatureReference) ((LabeledValue)(cmbStretch.getItemAt(0))).getValue()
+                );
+
+            } else {
+                cmbStretch.setEnabled(false);
+            }
+        } catch (DataException e) {
+            logger.error("Error getting table info", e);
+        } finally {
+            if (it != null) {
+                it.dispose();
+            }
+        }
+    }
+
+    private void stretchChanged(FeatureReference featRef) {
+        fetchCoordinates();
+        try {
+            editedFeature = featRef.getFeature().getCopy();
+        } catch (DataException ex) {
+            logger.error("Error getting table info", ex);
+        }
+
+        FeatureStore store; // = null;
+        FeatureSelection selection; // = null;
+        try {
+            store = layer.getFeatureStore();
+            selection = store.createFeatureSelection();
+            selection.select(editedFeature);
+            store.setSelection(selection);
+        } catch (DataException ex) {
+            logger.warn("Error getting table info", ex);
+        } finally {
+//            DisposeUtils.disposeQuietly(selection);
+//            DisposeUtils.disposeQuietly(store);
+        }
+        reloadTableModel();
+        reloadMaxMin((EditRouteCalibrationTableModel) tblLayerInfo.getModel());
+
+        graphics.removeGraphics(EDIT_ROUTECALIBRATION_GRAPHICS_ID);
+        showEditingRoute();
+        mapContext.invalidate();
+
+    }
+
+    /**
+     *
+     */
+    private void showEditingRoute() {
+        if (editedFeature != null) {
+            Geometry geom = editedFeature.getDefaultGeometry().cloneGeometry();
+            ICoordTrans ct = layer.getCoordTrans();
+            geom.reProject(ct);
+            graphics.addGraphic(EDIT_ROUTECALIBRATION_GRAPHICS_ID, geom, idLineSymbol);
+        }
+    }
+
+    private void reloadTableModel(){
+        reloadTableModel(editedFeature.getDefaultGeometry());
+    }
+    
+    private void reloadTableModel(Geometry geometry){
+        EditRouteCalibrationTableModel tableModel;
+        tableModel =null;
+        try {
+            if (editedFeature!=null){
+                tableModel = new EditRouteCalibrationTableModel(
+                        editedFeature.getString(fieldIdRoute.getName()), 
+                        geometry, 
+                        this.mCoordinatesByFeature.get(editedFeature.getReference()));
+                tableModel.addTableModelListener((TableModelEvent e) -> {
+                    cellUpdated(e.getFirstRow());
+                });
+            }
+        } catch (BaseException e) {
+            logger.error("Error getting table info",e);
+        }
+
+        tblLayerInfo.setModel(tableModel);
+        this.tblLayerInfo.invalidate();
+    }
+
+    private void doClose() {
+        DisposeUtils.disposeQuietly(this.selectedFeatures);
+        graphics.removeGraphics(EDIT_ROUTECALIBRATION_GRAPHICS_ID);
+        mapContext.invalidate();
+        this.setVisible(false);
+    }
+
+    public void close(){
+        this.doClose();
+    }
+
+    private void validateData(){
+        hasWarnings=true;
+        EditRouteCalibrationTableModel tableModel=(EditRouteCalibrationTableModel)tblLayerInfo.getModel();
+        Object[][] data=tableModel.getData();
+        I18nManager i18nManager = ToolsLocator.getI18nManager();
+        warnings=new ArrayList<>();
+
+        if (data==null){
+            warnings.add(i18nManager.getTranslation("warn_Not_data_found_in_table"));
+            return;
+        }
+        if (data.length<2){
+            warnings.add(i18nManager.getTranslation("warn_Not_enough_data_found_in_table"));
+        }
+        for (int i=0;data.length-1>=i;i++){
+            Double mCoordinate=(Double)data[i][EditRouteCalibrationTableModel.COLUMN_MCOORDINATE];
+            if(mCoordinate.compareTo(new Double(0))<0){
+                warnings.add(MessageFormat.format(i18nManager.getTranslation("warn_Negative_value_at_row"), i+1));
+            }
+            if(i>0 && i+1<data.length-1){
+                Double preMCoordinate=(Double)data[i-1][EditRouteCalibrationTableModel.COLUMN_MCOORDINATE];
+                Double postMCoordinate=(Double)data[i+1][EditRouteCalibrationTableModel.COLUMN_MCOORDINATE];
+                boolean orderedUpwardsPre=mCoordinate.compareTo(preMCoordinate)>=0;
+                boolean orderedUpwardsPost=postMCoordinate.compareTo(mCoordinate)>=0;
+                //if both,pre and post, are ordered upwards or downwards, it is correct
+                if(orderedUpwardsPre!=orderedUpwardsPost){
+                    warnings.add(MessageFormat.format(i18nManager.getTranslation("warn_Out_of_sequence_value_at_row"), i+1));
+                }
+            }
+
+            for (int j=i+1;data.length-2>=j;j++){
+                Double auxMCoordinate=(Double)data[j][EditRouteCalibrationTableModel.COLUMN_MCOORDINATE];
+                if(mCoordinate.equals(auxMCoordinate)){
+                    warnings.add(MessageFormat.format(i18nManager.getTranslation("warn_Repeated_value_at_row"), i+1,j+1));
+                }
+            }
+        }
+
+        if(warnings.isEmpty()){
+            hasWarnings=false;
+        }
+    }
+
+    public boolean hasWarnings(){
+        return this.hasWarnings;
+    }
+
+    public List<String> getWarnings(){
+        return this.warnings;
+    }
+
+    @Override
+    public boolean isCanceled() {
+        return this.canceled;
+    }
+
+    @Override
+    public void setVisibleAceptCancel(boolean visible) {
+        this.btnAccept.setVisible(visible);
+        this.btnCancel.setVisible(visible);
+    }
+
+    @Override
+    public boolean getVisibleAceptCancel() {
+        return this.btnAccept.isVisible();
+    }
+
+    @Override
+    public JComponent asJComponent() {
+        return this;
+    }
+
+    @Override
+    public LrsAlgorithmParams getParams()
+        throws LrsGettingParametersException, LrsNeededParameterException {
+        fetchCoordinates();
+        LrsAlgorithmsManager manager =
+            LrsAlgorithmsLocator.getLrsAlgorithmsManager();
+        LrsEditRouteCalibrationAlgorithmParams params =
+            manager.createLrsEditRouteCalibrationAlgorithmParams();
+            // Recorrer todo del interfaz y rellenar los parametros
+
+        params.setIdRouteField(fieldIdRoute);
+        params.setSelectedRouteName((String)cmbRoute.getSelectedItem());
+
+        params.setModifiedMCoordinates(this.mCoordinatesByFeature);
+
+        return params;
+    }
+
+    @Override
+    public void setParams(LrsAlgorithmParams params) {
+        if (params == null) {
+            clear();
+            return;
+        }
+        // Rellena los campos con los valores de params
+        LrsEditRouteCalibrationAlgorithmParams parameters =
+            (LrsEditRouteCalibrationAlgorithmParams) params;
+
+        if (parameters.getSelectedRouteName()!=null){
+            this.cmbRoute.setSelectedItem(parameters.getSelectedRouteName());
+        }
+        if (parameters.getIdRouteField()!=null &&
+            parameters.getIdRouteField() instanceof FeatureAttributeDescriptor){
+            this.fieldIdRoute=parameters.getIdRouteField();
+        }
+    }
+
+    @Override
+    public void clear() {
+        if (cmbRoute!=null){
+            this.cmbRoute.setSelectedItem(0);
+        }
+    }
+
+
+    /**
+     * Returns true if selectedIdRoute is contained in layer
+     * @param layer
+     * @param selectedIdRoute
+     * @return
+     */
+    private static boolean isCorrectIdRoute(FLayer layer, FeatureAttributeDescriptor selectedIdRoute){
+     // Validates is FLyrVect
+        FLyrVect lyrVect;
+        if (layer == null || !(layer instanceof FLyrVect)) {
+            return false;
+        }
+        lyrVect = (FLyrVect) layer;
+        try {
+            FeatureStore featureStore = lyrVect.getFeatureStore();
+            try {
+                FeatureType type = featureStore.getDefaultFeatureType();
+                FeatureAttributeDescriptor[] attributeDescriptors
+                        = type.getAttributeDescriptors();
+                for (int i = 0; i < attributeDescriptors.length; i++) {
+                    FeatureAttributeDescriptor featureAttributeDescriptor
+                            = attributeDescriptors[i];
+                    if (featureAttributeDescriptor.equals(selectedIdRoute)) {
+                        logger.debug("SelectedIdRoute founded in layer");
+                        return true;
+                    }
+                }
+            } catch (DataException e1) {
+                logger.warn(new StringBuilder()
+                        .append(
+                                "Error getting default feature type from layer ")
+                        .append(lyrVect.getName()).toString(), e1);
+            }
+        } catch (Exception e) {
+            logger.error("Can't get linear vector layers", e);
+        }
+        return false;
+    }
+
+    private static FeatureSet getSelectedFeatures(FLayer layer) {
+        FLyrVect lyrVect = null;
+        if (layer instanceof FLyrVect) {
+            lyrVect = (FLyrVect) layer;
+        } else
+            return null;
+        FeatureStore featureStore=lyrVect.getFeatureStore();
+        if(featureStore!=null){
+            try {
+                FeatureSelection selectedFeatures= featureStore.getFeatureSelection();
+                if (selectedFeatures!=null && !selectedFeatures.isEmpty()){
+                    DisposeUtils.bind(selectedFeatures);
+                    return selectedFeatures;
+                }else{
+                    //If there is not selected features, all features are used
+                    return featureStore.getFeatureSet();
+                }
+            } catch (DataException e) {
+                logger.warn("Can't get selected features", e);
+            }
+        }
+        return null;
+    }
+    
+    private void fetchCoordinates() {
+        TableModel tableModel = tblLayerInfo.getModel();
+        if(!(tableModel instanceof EditRouteCalibrationTableModel)){
+            return;
+        }
+        Object[][] data=((EditRouteCalibrationTableModel)tableModel).getData();
+        List<Double> mValues = new ArrayList<>();
+        for (Object[] line : data) {
+            Double mValue=(Double)line[4];
+            mValues.add(mValue);
+        }
+        this.mCoordinatesByFeature.put(editedFeature.getReference(), mValues);
+    }
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/FeatureAttributeDescriptorsComboBoxModel.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/FeatureAttributeDescriptorsComboBoxModel.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/FeatureAttributeDescriptorsComboBoxModel.java	(revision 950)
@@ -0,0 +1,130 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.swing.impl;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.swing.AbstractListModel;
+import javax.swing.MutableComboBoxModel;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+
+/**
+ * @author fdiaz
+ *
+ */
+public class FeatureAttributeDescriptorsComboBoxModel extends AbstractListModel<FeatureAttributeDescriptor> implements MutableComboBoxModel<FeatureAttributeDescriptor> {
+
+
+
+    private static final Logger logger = LoggerFactory.getLogger(FeatureAttributeDescriptorsComboBoxModel.class);
+
+    private List<FeatureAttributeDescriptor> descriptors;
+    private FeatureAttributeDescriptor selected;
+
+    /**
+     *
+     */
+    public FeatureAttributeDescriptorsComboBoxModel() {
+        descriptors = new ArrayList<FeatureAttributeDescriptor>();
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see javax.swing.ListModel#getSize()
+     */
+    public int getSize() {
+        return descriptors.size();
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see javax.swing.ListModel#getElementAt(int)
+     */
+    public FeatureAttributeDescriptor getElementAt(int index) {
+        return descriptors.get(index);
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see javax.swing.ComboBoxModel#setSelectedItem(java.lang.Object)
+     */
+    public void setSelectedItem(final Object anItem) {
+        selected = (FeatureAttributeDescriptor) anItem;
+        fireContentsChanged(this, -1, -1);
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see javax.swing.ComboBoxModel#getSelectedItem()
+     */
+    public Object getSelectedItem() {
+        return selected;
+    }
+
+    /* (non-Javadoc)
+     * @see javax.swing.MutableComboBoxModel#addElement(java.lang.Object)
+     */
+    public void addElement(FeatureAttributeDescriptor item) {
+        descriptors.add(item);
+        fireIntervalAdded(this, descriptors.size()-1, descriptors.size()-1);
+
+    }
+
+    /* (non-Javadoc)
+     * @see javax.swing.MutableComboBoxModel#removeElement(java.lang.Object)
+     */
+    public void removeElement(Object obj) {
+        int index = descriptors.indexOf(obj);
+        descriptors.remove(obj);
+        fireIntervalRemoved(this, index, index);
+
+    }
+
+    /* (non-Javadoc)
+     * @see javax.swing.MutableComboBoxModel#insertElementAt(java.lang.Object, int)
+     */
+    public void insertElementAt(FeatureAttributeDescriptor item, int index) {
+        descriptors.add(index, item);
+        fireIntervalAdded(this, index, index);
+
+    }
+
+    /* (non-Javadoc)
+     * @see javax.swing.MutableComboBoxModel#removeElementAt(int)
+     */
+    public void removeElementAt(int index) {
+        descriptors.remove(index);
+        fireIntervalRemoved(this, index, index);
+
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCreateRouteParamsView.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCreateRouteParamsView.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCreateRouteParamsView.java	(revision 950)
@@ -0,0 +1,265 @@
+package org.gvsig.lrs.swing.impl;
+
+import com.jgoodies.forms.layout.CellConstraints;
+import com.jgoodies.forms.layout.FormLayout;
+import java.awt.BorderLayout;
+import java.awt.ComponentOrientation;
+import java.awt.Container;
+import java.awt.Dimension;
+import javax.swing.Box;
+import javax.swing.ImageIcon;
+import javax.swing.JButton;
+import javax.swing.JCheckBox;
+import javax.swing.JComboBox;
+import javax.swing.JFormattedTextField;
+import javax.swing.JFrame;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+import javax.swing.JTextField;
+
+
+public class JLrsCreateRouteParamsView extends JPanel
+{
+   JPanel JLrsCreateRouteParametersPanel = new JPanel();
+   JLabel lblInputLayer = new JLabel();
+   JComboBox cmbInputLayer = new JComboBox();
+   JComboBox cmbIdRouteField = new JComboBox();
+   JLabel lblIdRouteField = new JLabel();
+   JLabel lblOutputFile = new JLabel();
+   JLabel lblMeasureSource = new JLabel();
+   JComboBox cmbMeasureSource = new JComboBox();
+   JLabel lblFromMeasureField = new JLabel();
+   JLabel lblToMeasureField = new JLabel();
+   JComboBox cmbFromMeasureField = new JComboBox();
+   JComboBox cmbToMeasureField = new JComboBox();
+   JLabel lblCoordinatesPriority = new JLabel();
+   JComboBox cmbCoordinatePriority = new JComboBox();
+   JFormattedTextField txtMeasureFactor = new JFormattedTextField();
+   JLabel lblMeasureFactor = new JLabel();
+   JLabel lblMeasureOffset = new JLabel();
+   JFormattedTextField txtMeasureOffset = new JFormattedTextField();
+   JCheckBox chkIgnoreSpatialGaps = new JCheckBox();
+   JTextField txtOutputFile = new JTextField();
+   JButton btnBrowser = new JButton();
+   JButton btnAccept = new JButton();
+   JButton btnCancel = new JButton();
+
+   /**
+    * Default constructor
+    */
+   public JLrsCreateRouteParamsView()
+   {
+      initializePanel();
+   }
+
+   /**
+    * Adds fill components to empty cells in the first row and first column of the grid.
+    * This ensures that the grid spacing will be the same as shown in the designer.
+    * @param cols an array of column indices in the first row where fill components should be added.
+    * @param rows an array of row indices in the first column where fill components should be added.
+    */
+   void addFillComponents( Container panel, int[] cols, int[] rows )
+   {
+      Dimension filler = new Dimension(10,10);
+
+      boolean filled_cell_11 = false;
+      CellConstraints cc = new CellConstraints();
+      if ( cols.length > 0 && rows.length > 0 )
+      {
+         if ( cols[0] == 1 && rows[0] == 1 )
+         {
+            /** add a rigid area  */
+            panel.add( Box.createRigidArea( filler ), cc.xy(1,1) );
+            filled_cell_11 = true;
+         }
+      }
+
+      for( int index = 0; index < cols.length; index++ )
+      {
+         if ( cols[index] == 1 && filled_cell_11 )
+         {
+            continue;
+         }
+         panel.add( Box.createRigidArea( filler ), cc.xy(cols[index],1) );
+      }
+
+      for( int index = 0; index < rows.length; index++ )
+      {
+         if ( rows[index] == 1 && filled_cell_11 )
+         {
+            continue;
+         }
+         panel.add( Box.createRigidArea( filler ), cc.xy(1,rows[index]) );
+      }
+
+   }
+
+   /**
+    * Helper method to load an image file from the CLASSPATH
+    * @param imageName the package and name of the file to load relative to the CLASSPATH
+    * @return an ImageIcon instance with the specified image file
+    * @throws IllegalArgumentException if the image resource cannot be loaded.
+    */
+   public ImageIcon loadImage( String imageName )
+   {
+      try
+      {
+         ClassLoader classloader = getClass().getClassLoader();
+         java.net.URL url = classloader.getResource( imageName );
+         if ( url != null )
+         {
+            ImageIcon icon = new ImageIcon( url );
+            return icon;
+         }
+      }
+      catch( Exception e )
+      {
+         e.printStackTrace();
+      }
+      throw new IllegalArgumentException( "Unable to load image: " + imageName );
+   }
+
+   /**
+    * Method for recalculating the component orientation for
+    * right-to-left Locales.
+    * @param orientation the component orientation to be applied
+    */
+   public void applyComponentOrientation( ComponentOrientation orientation )
+   {
+      // Not yet implemented...
+      // I18NUtils.applyComponentOrientation(this, orientation);
+      super.applyComponentOrientation(orientation);
+   }
+
+   public JPanel createJLrsCreateRouteParametersPanel()
+   {
+      JLrsCreateRouteParametersPanel.setName("JLrsCreateRouteParametersPanel");
+      FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:GROW(1.0),FILL:DEFAULT:NONE","CENTER:DEFAULT:NONE,FILL:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:GROW(1.0),CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE");
+      CellConstraints cc = new CellConstraints();
+      JLrsCreateRouteParametersPanel.setLayout(formlayout1);
+
+      lblInputLayer.setName("lblInputLayer");
+      lblInputLayer.setText("source");
+      JLrsCreateRouteParametersPanel.add(lblInputLayer,cc.xy(2,2));
+
+      cmbInputLayer.setName("cmbInputLayer");
+      JLrsCreateRouteParametersPanel.add(cmbInputLayer,cc.xy(4,2));
+
+      cmbIdRouteField.setName("cmbIdRouteField");
+      JLrsCreateRouteParametersPanel.add(cmbIdRouteField,cc.xy(4,3));
+
+      lblIdRouteField.setName("lblIdRouteField");
+      lblIdRouteField.setText("id_route_field");
+      JLrsCreateRouteParametersPanel.add(lblIdRouteField,cc.xy(2,3));
+
+      lblOutputFile.setName("lblOutputFile");
+      lblOutputFile.setText("output_file");
+      JLrsCreateRouteParametersPanel.add(lblOutputFile,cc.xy(2,4));
+
+      lblMeasureSource.setName("lblMeasureSource");
+      lblMeasureSource.setText("measure_source");
+      JLrsCreateRouteParametersPanel.add(lblMeasureSource,cc.xy(2,5));
+
+      cmbMeasureSource.setName("cmbMeasureSource");
+      JLrsCreateRouteParametersPanel.add(cmbMeasureSource,cc.xy(4,5));
+
+      lblFromMeasureField.setName("lblFromMeasureField");
+      lblFromMeasureField.setText("from_measure_field");
+      JLrsCreateRouteParametersPanel.add(lblFromMeasureField,cc.xy(2,6));
+
+      lblToMeasureField.setName("lblToMeasureField");
+      lblToMeasureField.setText("to_measure_field");
+      JLrsCreateRouteParametersPanel.add(lblToMeasureField,cc.xy(2,7));
+
+      cmbFromMeasureField.setName("cmbFromMeasureField");
+      JLrsCreateRouteParametersPanel.add(cmbFromMeasureField,cc.xy(4,6));
+
+      cmbToMeasureField.setName("cmbToMeasureField");
+      JLrsCreateRouteParametersPanel.add(cmbToMeasureField,cc.xy(4,7));
+
+      lblCoordinatesPriority.setName("lblCoordinatesPriority");
+      lblCoordinatesPriority.setText("coordinates_priority");
+      JLrsCreateRouteParametersPanel.add(lblCoordinatesPriority,cc.xy(2,8));
+
+      cmbCoordinatePriority.setName("cmbCoordinatePriority");
+      JLrsCreateRouteParametersPanel.add(cmbCoordinatePriority,cc.xy(4,8));
+
+      txtMeasureFactor.setName("txtMeasureFactor");
+      JLrsCreateRouteParametersPanel.add(txtMeasureFactor,cc.xy(4,9));
+
+      lblMeasureFactor.setName("lblMeasureFactor");
+      lblMeasureFactor.setText("measure_factor");
+      JLrsCreateRouteParametersPanel.add(lblMeasureFactor,cc.xy(2,9));
+
+      lblMeasureOffset.setName("lblMeasureOffset");
+      lblMeasureOffset.setText("measure_offset");
+      JLrsCreateRouteParametersPanel.add(lblMeasureOffset,cc.xy(2,10));
+
+      txtMeasureOffset.setName("txtMeasureOffset");
+      JLrsCreateRouteParametersPanel.add(txtMeasureOffset,cc.xy(4,10));
+
+      chkIgnoreSpatialGaps.setActionCommand("JCBIgnoreSpatialGaps");
+      chkIgnoreSpatialGaps.setName("chkIgnoreSpatialGaps");
+      chkIgnoreSpatialGaps.setText("ignore_spatial_gaps");
+      JLrsCreateRouteParametersPanel.add(chkIgnoreSpatialGaps,cc.xywh(2,11,3,1));
+
+      JLrsCreateRouteParametersPanel.add(createPanel(),cc.xy(4,4));
+      JLrsCreateRouteParametersPanel.add(createPanel1(),new CellConstraints(2,13,3,1,CellConstraints.RIGHT,CellConstraints.DEFAULT));
+      addFillComponents(JLrsCreateRouteParametersPanel,new int[]{ 1,2,3,4,5 },new int[]{ 1,2,3,4,5,6,7,8,9,10,11,12,13,14 });
+      return JLrsCreateRouteParametersPanel;
+   }
+
+   public JPanel createPanel()
+   {
+      JPanel jpanel1 = new JPanel();
+      FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:GROW(1.0),FILL:36PX:NONE","CENTER:DEFAULT:NONE");
+      CellConstraints cc = new CellConstraints();
+      jpanel1.setLayout(formlayout1);
+
+      txtOutputFile.setName("txtOutputFile");
+      txtOutputFile.setHorizontalAlignment(JTextField.LEFT);
+      jpanel1.add(txtOutputFile,cc.xy(1,1));
+
+      btnBrowser.setActionCommand("JButton");
+      btnBrowser.setName("btnBrowser");
+      btnBrowser.setOpaque(false);
+      btnBrowser.setRolloverEnabled(true);
+      btnBrowser.setText("...");
+      jpanel1.add(btnBrowser,cc.xy(2,1));
+
+      addFillComponents(jpanel1,new int[0],new int[0]);
+      return jpanel1;
+   }
+
+   public JPanel createPanel1()
+   {
+      JPanel jpanel1 = new JPanel();
+      FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE","CENTER:DEFAULT:NONE");
+      CellConstraints cc = new CellConstraints();
+      jpanel1.setLayout(formlayout1);
+
+      btnAccept.setActionCommand("_Accept");
+      btnAccept.setName("btnAccept");
+      btnAccept.setText("_Accept");
+      jpanel1.add(btnAccept,new CellConstraints(1,1,1,1,CellConstraints.CENTER,CellConstraints.DEFAULT));
+
+      btnCancel.setActionCommand("_Cancel");
+      btnCancel.setName("btnCancel");
+      btnCancel.setText("_Cancel");
+      jpanel1.add(btnCancel,cc.xy(3,1));
+
+      addFillComponents(jpanel1,new int[]{ 2 },new int[0]);
+      return jpanel1;
+   }
+
+   /**
+    * Initializer
+    */
+   protected void initializePanel()
+   {
+      setLayout(new BorderLayout());
+      add(createJLrsCreateRouteParametersPanel(), BorderLayout.CENTER);
+   }
+
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCalculateMRouteView.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCalculateMRouteView.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCalculateMRouteView.java	(revision 950)
@@ -0,0 +1,158 @@
+package org.gvsig.lrs.swing.impl;
+
+import java.awt.BorderLayout;
+import java.awt.ComponentOrientation;
+import java.awt.Container;
+import java.awt.Dimension;
+
+import javax.swing.Box;
+import javax.swing.ImageIcon;
+import javax.swing.JComboBox;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+
+import org.gvsig.fmap.mapcontrol.dal.feature.swing.FeatureTablePanel;
+
+import com.jgoodies.forms.layout.CellConstraints;
+import com.jgoodies.forms.layout.FormLayout;
+
+
+public class JLrsCalculateMRouteView extends JPanel
+{
+   JPanel jLrsCalculateMRoutePanel = new JPanel();
+   JLabel jroutesselected = new JLabel();
+   JLabel pkilabel = new JLabel();
+   JLabel pkflabel = new JLabel();
+   JComboBox pkicombo = new JComboBox();
+   JComboBox pkfcombo = new JComboBox();
+   FeatureTablePanel routestable = null;
+
+   /**
+    * Default constructor
+    */
+   public JLrsCalculateMRouteView()
+   {
+      initializePanel();
+   }
+
+   /**
+    * Adds fill components to empty cells in the first row and first column of the grid.
+    * This ensures that the grid spacing will be the same as shown in the designer.
+    * @param cols an array of column indices in the first row where fill components should be added.
+    * @param rows an array of row indices in the first column where fill components should be added.
+    */
+   void addFillComponents( Container panel, int[] cols, int[] rows )
+   {
+      Dimension filler = new Dimension(10,10);
+
+      boolean filled_cell_11 = false;
+      CellConstraints cc = new CellConstraints();
+      if ( cols.length > 0 && rows.length > 0 )
+      {
+         if ( cols[0] == 1 && rows[0] == 1 )
+         {
+            /** add a rigid area  */
+            panel.add( Box.createRigidArea( filler ), cc.xy(1,1) );
+            filled_cell_11 = true;
+         }
+      }
+
+      for( int index = 0; index < cols.length; index++ )
+      {
+         if ( cols[index] == 1 && filled_cell_11 )
+         {
+            continue;
+         }
+         panel.add( Box.createRigidArea( filler ), cc.xy(cols[index],1) );
+      }
+
+      for( int index = 0; index < rows.length; index++ )
+      {
+         if ( rows[index] == 1 && filled_cell_11 )
+         {
+            continue;
+         }
+         panel.add( Box.createRigidArea( filler ), cc.xy(1,rows[index]) );
+      }
+
+   }
+
+   /**
+    * Helper method to load an image file from the CLASSPATH
+    * @param imageName the package and name of the file to load relative to the CLASSPATH
+    * @return an ImageIcon instance with the specified image file
+    * @throws IllegalArgumentException if the image resource cannot be loaded.
+    */
+   public ImageIcon loadImage( String imageName )
+   {
+      try
+      {
+         ClassLoader classloader = getClass().getClassLoader();
+         java.net.URL url = classloader.getResource( imageName );
+         if ( url != null )
+         {
+            ImageIcon icon = new ImageIcon( url );
+            return icon;
+         }
+      }
+      catch( Exception e )
+      {
+         e.printStackTrace();
+      }
+      throw new IllegalArgumentException( "Unable to load image: " + imageName );
+   }
+
+   /**
+    * Method for recalculating the component orientation for
+    * right-to-left Locales.
+    * @param orientation the component orientation to be applied
+    */
+   public void applyComponentOrientation( ComponentOrientation orientation )
+   {
+      // Not yet implemented...
+      // I18NUtils.applyComponentOrientation(this, orientation);
+      super.applyComponentOrientation(orientation);
+   }
+
+   public JPanel createJLrsCalculateMRoutePanel()
+   {
+	  jLrsCalculateMRoutePanel.setName("JLrsCreateRouteParametersPanel");
+      FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:NONE,FILL:DEFAULT:GROW(1.0),FILL:DEFAULT:GROW(1.0),FILL:DEFAULT:NONE,FILL:DEFAULT:GROW(1.0),FILL:DEFAULT:NONE","FILL:DEFAULT:NONE,FILL:DEFAULT:NONE,FILL:DEFAULT:NONE,FILL:DEFAULT:NONE,FILL:DEFAULT:NONE,FILL:DEFAULT:GROW(1.0),FILL:DEFAULT:NONE");
+      CellConstraints cc = new CellConstraints();
+      jLrsCalculateMRoutePanel.setLayout(formlayout1);
+
+      jroutesselected.setName("jroutesselected");
+      jroutesselected.setText("pk_selected");
+      jLrsCalculateMRoutePanel.add(jroutesselected,cc.xyw(1,1,5));
+      
+      pkilabel.setName("pkilabel");
+      pkilabel.setText("pk_inicial");
+      jLrsCalculateMRoutePanel.add(pkilabel,cc.xy(1,3));
+      
+      pkflabel.setName("pkflabel");
+      pkflabel.setText("pk_final");
+      jLrsCalculateMRoutePanel.add(pkflabel,cc.xy(4,3));
+
+      pkicombo.setName("pkicombo");
+      jLrsCalculateMRoutePanel.add(pkicombo,cc.xy(2,3));
+
+      pkfcombo.setName("pkfcombo");
+      jLrsCalculateMRoutePanel.add(pkfcombo,cc.xy(5,3));
+      
+      
+      addFillComponents(jLrsCalculateMRoutePanel,new int[]{ 1,2,3,4,5,6 },new int[]{ 1,2,3,4,5,6,7});
+      return jLrsCalculateMRoutePanel;
+   }
+
+
+   /**
+    * Initializer
+    */
+   protected void initializePanel()
+   {
+      setLayout(new BorderLayout());
+      add(createJLrsCalculateMRoutePanel(), BorderLayout.CENTER);
+   }
+
+
+}

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCalculateMRouteView.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/FLayersAttributeDescriptorCellRenderer.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/FLayersAttributeDescriptorCellRenderer.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/FLayersAttributeDescriptorCellRenderer.java	(revision 950)
@@ -0,0 +1,36 @@
+/*
+ * Copyright 2015 DiSiD Technologies S.L.L. All rights reserved.
+ *
+ * Project  : DiSiD org.gvsig.lrs.swing.impl
+ * SVN Id   : $Id$
+ */
+package org.gvsig.lrs.swing.impl;
+
+import java.awt.Component;
+
+import javax.swing.DefaultListCellRenderer;
+import javax.swing.JLabel;
+import javax.swing.JList;
+import javax.swing.ListCellRenderer;
+
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+
+public class FLayersAttributeDescriptorCellRenderer implements ListCellRenderer{
+
+
+    protected DefaultListCellRenderer defaultRenderer = new DefaultListCellRenderer();
+
+    public Component getListCellRendererComponent(JList list, Object value, int index, boolean isSelected,
+        boolean cellHasFocus) {
+        JLabel renderer =
+            (JLabel) defaultRenderer.getListCellRendererComponent(list, value, index, isSelected, cellHasFocus);
+        if (value instanceof FeatureAttributeDescriptor) {
+            renderer.setText(((FeatureAttributeDescriptor) value).getName());
+        }
+        if (value == null) {
+            renderer.setText("");
+        }
+        return renderer;
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/FLayersComboBoxModel.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/FLayersComboBoxModel.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/FLayersComboBoxModel.java	(revision 950)
@@ -0,0 +1,126 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.swing.impl;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.swing.AbstractListModel;
+import javax.swing.ComboBoxModel;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.operations.LayerCollection;
+import org.gvsig.fmap.mapcontext.layers.operations.LayersVisitor;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.tools.exception.BaseException;
+import org.gvsig.tools.visitor.VisitCanceledException;
+
+/**
+ * @author fdiaz
+ *
+ */
+public class FLayersComboBoxModel extends AbstractListModel<FLayer> implements ComboBoxModel<FLayer> {
+
+    /**
+     *
+     */
+    private static final long serialVersionUID = -1271707498886332136L;
+
+    private static final Logger logger = LoggerFactory.getLogger(FLayersComboBoxModel.class);
+
+    private List<FLyrVect> vectLayers;
+    private FLayer selectedLayer;
+
+    /**
+     *
+     */
+    public FLayersComboBoxModel(LayerCollection layers) {
+        vectLayers = new ArrayList<FLyrVect>();
+        try {
+            layers.accept(new LayersVisitor() {
+
+                public void visit(Object obj) throws VisitCanceledException, BaseException {
+                    // TODO Auto-generated method stub
+
+                }
+
+                public void visit(FLayer layer) throws BaseException {
+                    if (layer instanceof FLyrVect) {
+                        FLyrVect lyrVect = (FLyrVect) layer;
+                        if (lyrVect.getGeometryType().isTypeOf(Geometry.TYPES.CURVE)
+                            || lyrVect.getGeometryType().isTypeOf(Geometry.TYPES.MULTICURVE)) {
+                            vectLayers.add(lyrVect);
+                            if(lyrVect.isActive()){
+                                selectedLayer = lyrVect;
+                            }
+                        }
+                    }
+                }
+            });
+        } catch (BaseException e1) {
+            logger.warn("Can't get linear vector layers", e1);
+        }
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see javax.swing.ListModel#getSize()
+     */
+    public int getSize() {
+        return vectLayers.size(); //.getLayersCount();
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see javax.swing.ListModel#getElementAt(int)
+     */
+    public FLayer getElementAt(int index) {
+        return vectLayers.get(index); //.getLayer(index);
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see javax.swing.ComboBoxModel#setSelectedItem(java.lang.Object)
+     */
+    public void setSelectedItem(final Object anItem) {
+        selectedLayer = (FLayer) anItem;
+        fireContentsChanged(this, -1, -1);
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see javax.swing.ComboBoxModel#getSelectedItem()
+     */
+    public Object getSelectedItem() {
+        return selectedLayer;
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/DefaultProgressDialogView.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/DefaultProgressDialogView.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/DefaultProgressDialogView.java	(revision 950)
@@ -0,0 +1,137 @@
+package org.gvsig.lrs.swing.impl;
+
+import com.jgoodies.forms.layout.CellConstraints;
+import com.jgoodies.forms.layout.FormLayout;
+import java.awt.BorderLayout;
+import java.awt.ComponentOrientation;
+import java.awt.Container;
+import java.awt.Dimension;
+import javax.swing.Box;
+import javax.swing.ImageIcon;
+import javax.swing.JButton;
+import javax.swing.JFrame;
+import javax.swing.JPanel;
+
+
+public class DefaultProgressDialogView extends JPanel
+{
+   JPanel progressBar = new JPanel();
+   JButton btnClose = new JButton();
+
+   /**
+    * Default constructor
+    */
+   public DefaultProgressDialogView()
+   {
+      initializePanel();
+   }
+
+   /**
+    * Adds fill components to empty cells in the first row and first column of the grid.
+    * This ensures that the grid spacing will be the same as shown in the designer.
+    * @param cols an array of column indices in the first row where fill components should be added.
+    * @param rows an array of row indices in the first column where fill components should be added.
+    */
+   void addFillComponents( Container panel, int[] cols, int[] rows )
+   {
+      Dimension filler = new Dimension(10,10);
+
+      boolean filled_cell_11 = false;
+      CellConstraints cc = new CellConstraints();
+      if ( cols.length > 0 && rows.length > 0 )
+      {
+         if ( cols[0] == 1 && rows[0] == 1 )
+         {
+            /** add a rigid area  */
+            panel.add( Box.createRigidArea( filler ), cc.xy(1,1) );
+            filled_cell_11 = true;
+         }
+      }
+
+      for( int index = 0; index < cols.length; index++ )
+      {
+         if ( cols[index] == 1 && filled_cell_11 )
+         {
+            continue;
+         }
+         panel.add( Box.createRigidArea( filler ), cc.xy(cols[index],1) );
+      }
+
+      for( int index = 0; index < rows.length; index++ )
+      {
+         if ( rows[index] == 1 && filled_cell_11 )
+         {
+            continue;
+         }
+         panel.add( Box.createRigidArea( filler ), cc.xy(1,rows[index]) );
+      }
+
+   }
+
+   /**
+    * Helper method to load an image file from the CLASSPATH
+    * @param imageName the package and name of the file to load relative to the CLASSPATH
+    * @return an ImageIcon instance with the specified image file
+    * @throws IllegalArgumentException if the image resource cannot be loaded.
+    */
+   public ImageIcon loadImage( String imageName )
+   {
+      try
+      {
+         ClassLoader classloader = getClass().getClassLoader();
+         java.net.URL url = classloader.getResource( imageName );
+         if ( url != null )
+         {
+            ImageIcon icon = new ImageIcon( url );
+            return icon;
+         }
+      }
+      catch( Exception e )
+      {
+         e.printStackTrace();
+      }
+      throw new IllegalArgumentException( "Unable to load image: " + imageName );
+   }
+
+   /**
+    * Method for recalculating the component orientation for
+    * right-to-left Locales.
+    * @param orientation the component orientation to be applied
+    */
+   public void applyComponentOrientation( ComponentOrientation orientation )
+   {
+      // Not yet implemented...
+      // I18NUtils.applyComponentOrientation(this, orientation);
+      super.applyComponentOrientation(orientation);
+   }
+
+   public JPanel createPanel()
+   {
+      JPanel jpanel1 = new JPanel();
+      FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:NONE,FILL:DEFAULT:GROW(1.0),FILL:DEFAULT:NONE,FILL:DEFAULT:NONE","CENTER:DEFAULT:NONE,CENTER:61DLU:GROW(1.0),CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE");
+      CellConstraints cc = new CellConstraints();
+      jpanel1.setLayout(formlayout1);
+
+      progressBar.setName("progressBar");
+      jpanel1.add(progressBar,new CellConstraints(2,2,2,1,CellConstraints.FILL,CellConstraints.DEFAULT));
+
+      btnClose.setActionCommand("_Close");
+      btnClose.setName("btnClose");
+      btnClose.setText("_Close");
+      jpanel1.add(btnClose,cc.xy(3,3));
+
+      addFillComponents(jpanel1,new int[]{ 1,2,3,4 },new int[]{ 1,2,3,4 });
+      return jpanel1;
+   }
+
+   /**
+    * Initializer
+    */
+   protected void initializePanel()
+   {
+      setLayout(new BorderLayout());
+      add(createPanel(), BorderLayout.CENTER);
+   }
+
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCreateRouteParamsController.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCreateRouteParamsController.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCreateRouteParamsController.java	(revision 950)
@@ -0,0 +1,517 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.swing.impl;
+
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.awt.event.ItemEvent;
+import java.awt.event.ItemListener;
+import java.io.File;
+import java.util.Locale;
+
+import javax.swing.ComboBoxModel;
+import javax.swing.DefaultComboBoxModel;
+import javax.swing.JComponent;
+import javax.swing.JOptionPane;
+import javax.swing.ListCellRenderer;
+
+import org.apache.commons.io.FileUtils;
+import org.apache.commons.lang3.StringUtils;
+import org.cresques.cts.IProjection;
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.feature.FeatureType;
+import org.gvsig.fmap.dal.feature.NewFeatureStoreParameters;
+import org.gvsig.fmap.dal.store.shp.SHPNewStoreParameters;
+import org.gvsig.fmap.geom.DataTypes;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+//import org.gvsig.fmap.mapcontext.layers.FLayers;
+import org.gvsig.fmap.mapcontext.layers.operations.LayerCollection;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.lrs.lib.api.LrsAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsAlgorithmsLocator;
+import org.gvsig.lrs.lib.api.LrsAlgorithmsManager;
+import org.gvsig.lrs.lib.api.LrsCoordinatesPriority;
+import org.gvsig.lrs.lib.api.LrsCreateRouteAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsSourceOfMeasures;
+import org.gvsig.lrs.lib.api.exceptions.LrsGettingParametersException;
+import org.gvsig.lrs.lib.api.exceptions.LrsNeededParameterException;
+import org.gvsig.lrs.swing.api.JLrsAlgorithmParams;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.i18n.I18nManager;
+import org.gvsig.tools.swing.api.ActionListenerSupport;
+import org.gvsig.tools.swing.api.ToolsSwingLocator;
+import org.gvsig.tools.swing.api.threadsafedialogs.ThreadSafeDialogsManager;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * @author fdiaz
+ *
+ */
+public class JLrsCreateRouteParamsController extends JLrsCreateRouteParamsView implements JLrsAlgorithmParams {
+
+    /**
+     *
+     */
+    private static final long serialVersionUID = 273909136196706713L;
+
+    private static final Logger logger = LoggerFactory.getLogger(JLrsCreateRouteParamsController.class);
+
+    private boolean canceled;
+    private ActionListenerSupport listeners = ToolsSwingLocator.getToolsSwingManager().createActionListenerSupport();
+
+    private LayerCollection layers;
+
+    /**
+     * @param layers
+     * @throws LrsNeededParameterException
+     *
+     */
+    public JLrsCreateRouteParamsController(LayerCollection layers, LrsAlgorithmParams params) throws LrsNeededParameterException {
+        super();
+        this.layers = layers;
+        initComponents();
+        translate();
+        setParams(params);
+    }
+
+    public void addActionListener(ActionListener listener) {
+        listeners.addActionListener(listener);
+    }
+
+    public void removeActionListener(ActionListener listener) {
+        listeners.removeActionListener(listener);
+    }
+
+    private void translate() {
+        I18nManager i18nManager = ToolsLocator.getI18nManager();
+
+        lblInputLayer.setText(i18nManager.getTranslation(lblInputLayer.getText()));
+        lblIdRouteField.setText(i18nManager.getTranslation(lblIdRouteField.getText()));
+        lblOutputFile.setText(i18nManager.getTranslation(lblOutputFile.getText()));
+        lblMeasureSource.setText(i18nManager.getTranslation(lblMeasureSource.getText()));
+        lblFromMeasureField.setText(i18nManager.getTranslation(lblFromMeasureField.getText()));
+        lblToMeasureField.setText(i18nManager.getTranslation(lblToMeasureField.getText()));
+        lblCoordinatesPriority.setText(i18nManager.getTranslation(lblCoordinatesPriority.getText()));
+        lblMeasureFactor.setText(i18nManager.getTranslation(lblMeasureFactor.getText()));
+        lblMeasureOffset.setText(i18nManager.getTranslation(lblMeasureOffset.getText()));
+        chkIgnoreSpatialGaps.setText(i18nManager.getTranslation(chkIgnoreSpatialGaps.getText()));
+        btnBrowser.setText("\u2026");
+        btnAccept.setText(i18nManager.getTranslation(btnAccept.getText()));
+        btnCancel.setText(i18nManager.getTranslation(btnCancel.getText()));
+
+    }
+
+    /**
+     *
+     */
+    public void setLocate(Locale locale) {
+        Locale l = super.getLocale();
+        if (!l.equals(locale)) {
+            translate();
+        }
+        super.setLocale(locale);
+    }
+
+    /**
+     * Validates the layers:
+     *  - At least 1 curve layer with at least 1 non-geometrical field
+     *  if they are not correct throws an exception
+     * @throws LrsNeededParameterException
+     */
+    public static void validateLayers(LayerCollection layers)throws LrsNeededParameterException {
+        logger.debug("Validating layers for Create Route");
+        if (layers==null||layers.getLayersCount()<1){
+            logger.error("Al least one layer is needed");
+            throw new LrsNeededParameterException("at_least_one_layer_needed", null);
+        }
+
+        if (!JLrsUtils.validateOneCurveLyrOneNonGeomField(layers)){
+            logger.error("Impossible to find the layer needed");
+            throw new LrsNeededParameterException("impossible_to_find_needed_layer",null);
+        }
+    }
+
+    /**
+     * @throws LrsNeededParameterException
+     */
+    private void initComponents() throws LrsNeededParameterException {
+
+        validateLayers(layers);
+
+        // Modelos de los combos
+        FLayersComboBoxModel inputLayerModel = new FLayersComboBoxModel(this.layers);
+        FeatureAttributeDescriptorsComboBoxModel idRouteFieldComboBoxModel =
+            new FeatureAttributeDescriptorsComboBoxModel();
+        FeatureAttributeDescriptorsComboBoxModel fromMeasureFieldComboBoxModel =
+            new FeatureAttributeDescriptorsComboBoxModel();
+        FeatureAttributeDescriptorsComboBoxModel toMeasureFieldComboBoxModel =
+            new FeatureAttributeDescriptorsComboBoxModel();
+
+        // Renderer para los combos de attributeDescriptors
+        ListCellRenderer featureAttributeDescriptorCellRenderer = new FLayersAttributeDescriptorCellRenderer();
+        // asignación de renderers y modelos
+        cmbIdRouteField.setRenderer(featureAttributeDescriptorCellRenderer);
+        cmbFromMeasureField.setRenderer(featureAttributeDescriptorCellRenderer);
+        cmbToMeasureField.setRenderer(featureAttributeDescriptorCellRenderer);
+        cmbIdRouteField.setModel(idRouteFieldComboBoxModel);
+        cmbFromMeasureField.setModel(fromMeasureFieldComboBoxModel);
+        cmbToMeasureField.setModel(toMeasureFieldComboBoxModel);
+
+        // renderer para el combo de capas
+        ListCellRenderer layerNameCellRenderer=new FLayersLayerNameCellRenderer();
+        // renderer para el combo de capas
+        cmbInputLayer.setRenderer(layerNameCellRenderer);
+
+        // asignación modelo al combo de capas
+        cmbInputLayer.setModel(inputLayerModel);
+        // listener del combo de capas para que actualice el resto de
+        // componentes
+        cmbInputLayer.addItemListener(new ItemListener() {
+
+            public void itemStateChanged(ItemEvent e) {
+                Object item = e.getItem();
+                if (item instanceof FLyrVect) {
+                    FLyrVect layer = (FLyrVect) item;
+                    updateLayer(layer);
+                }
+            }
+        });
+
+        ComboBoxModel<LrsSourceOfMeasures> measureSourceModel =
+            new DefaultComboBoxModel<LrsSourceOfMeasures>(LrsSourceOfMeasures.values());
+
+        cmbMeasureSource.setModel(measureSourceModel);
+        cmbMeasureSource.addItemListener(new ItemListener() {
+
+            public void itemStateChanged(ItemEvent event) {
+                if (event.getStateChange() == ItemEvent.SELECTED) {
+                    LrsSourceOfMeasures item = (LrsSourceOfMeasures) event.getItem();
+                    updateSourceOfMeasures(item);
+                }
+            }
+        });
+
+        ComboBoxModel<LrsCoordinatesPriority> coordinatePriorityModel =
+            new DefaultComboBoxModel<LrsCoordinatesPriority>(LrsCoordinatesPriority.values());
+
+        cmbCoordinatePriority.setModel(coordinatePriorityModel);
+
+        txtMeasureFactor.setValue(new Double(1));
+        txtMeasureOffset.setValue(new Double(0));
+
+        this.btnBrowser.addActionListener(new ActionListener() {
+
+            public void actionPerformed(ActionEvent e) {
+                doSelectOuputFile();
+            }
+        });
+
+        this.btnAccept.addActionListener(new ActionListener() {
+
+            public void actionPerformed(ActionEvent e) {
+                canceled = false;
+                doClose();
+                listeners.fireActionEvent(new ActionEvent(JLrsCreateRouteParamsController.this, 0, "accept"));
+
+            }
+        });
+
+        this.btnCancel.addActionListener(new ActionListener() {
+
+            public void actionPerformed(ActionEvent e) {
+                canceled = true;
+                doClose();
+                listeners.fireActionEvent(new ActionEvent(JLrsCreateRouteParamsController.this, 0, "cancel"));
+            }
+        });
+
+        setVisibleAceptCancel(false);
+        canceled = false;
+    }
+
+    private void doSelectOuputFile() {
+        final I18nManager i18nManager = ToolsLocator.getI18nManager();
+        ThreadSafeDialogsManager manager = ToolsSwingLocator.getThreadSafeDialogsManager();
+        File[] files = manager.showSaveFileDialog(i18nManager.getTranslation("output_file"), null);
+        if (files != null && files.length > 0) {
+            File file = files[0];
+            String absolutePath = file.getAbsolutePath();
+            if(!StringUtils.endsWithIgnoreCase(absolutePath, ".shp")){
+                absolutePath = new StringBuilder().append(absolutePath).append(".shp").toString();
+            }
+            File outputFile = FileUtils.getFile(absolutePath);
+            if(outputFile.exists()) {
+                int resp = JOptionPane.showOptionDialog(
+                    this.asJComponent(),
+                    i18nManager.getTranslation("file_already_exists_do_you_want_overwrite_it"),
+                    i18nManager.getTranslation("output_file"),
+                    JOptionPane.OK_CANCEL_OPTION,
+                    JOptionPane.QUESTION_MESSAGE,
+                    null,
+                    null,
+                    JOptionPane.OK_OPTION);
+                if (resp == JOptionPane.OK_OPTION){
+                    this.txtOutputFile.setText(absolutePath);
+                } else {
+                    doSelectOuputFile();
+                }
+            } else {
+                this.txtOutputFile.setText(absolutePath);
+            }
+        }
+
+    }
+
+    private void doClose() {
+        this.setVisible(false);
+    }
+
+    public boolean isCanceled() {
+        return this.canceled;
+    }
+
+    public void setVisibleAceptCancel(boolean visible) {
+        this.btnAccept.setVisible(visible);
+        this.btnCancel.setVisible(visible);
+    }
+
+    public boolean getVisibleAceptCancel() {
+        return this.btnAccept.isVisible();
+    }
+
+    public JComponent asJComponent() {
+        return this;
+    }
+
+    public LrsAlgorithmParams getParams() throws LrsGettingParametersException, LrsNeededParameterException {
+        LrsAlgorithmsManager manager = LrsAlgorithmsLocator.getLrsAlgorithmsManager();
+        LrsCreateRouteAlgorithmParams params = manager.createLrsCreateRouteAlgorithmParams();
+        // Recorrer todo del interfaz y rellenar los parametros
+
+      //cmbInputLayer
+        if (!(this.cmbInputLayer.getSelectedItem() instanceof FLyrVect)){
+            logger.error("Error getting selected item from cmbInputLayer");
+            throw new LrsGettingParametersException("error_getting_selected_item_from_cmbInputLayer", null);
+        }
+        FLyrVect fLyrVect = (FLyrVect) this.cmbInputLayer.getSelectedItem();
+        IProjection projection= fLyrVect.getProjection();
+        if (!(fLyrVect.getFeatureStore() instanceof FeatureStore)){
+            logger.error("Error getting selected item from cmbInputLayer");
+            throw new LrsGettingParametersException("error_getting_selected_item_from_cmbInputLayer", null);
+        }
+        FeatureStore sourceFeatureStore = (FeatureStore)fLyrVect.getFeatureStore();
+        if (sourceFeatureStore == null) {
+            throw new LrsNeededParameterException("need_to_select_a_source_layer", null);
+        }
+        params.setSourceFeatureStore(sourceFeatureStore);
+
+        //cmbIdRouteField
+        if (!(this.cmbIdRouteField.getSelectedItem() instanceof FeatureAttributeDescriptor)){
+            logger.error("Error getting selected item from cmbIdRouteField");
+            throw new LrsGettingParametersException("error_getting_selected_item_from_cmbIdRouteField", null);
+        }
+        FeatureAttributeDescriptor idRouteField = (FeatureAttributeDescriptor) this.cmbIdRouteField.getSelectedItem();
+        if (idRouteField == null) {
+            throw new LrsNeededParameterException("need_to_select_a_route_identifier_field", null);
+        }
+        params.setIdRouteField(idRouteField);
+
+        //OutputStore
+        String outputLayerPathFile = this.txtOutputFile.getText();
+        if(StringUtils.isEmpty(outputLayerPathFile)){
+            throw new LrsNeededParameterException("need_to_fill_the_target_path", null);
+        }
+        try {
+            NewFeatureStoreParameters newFeatureStoreParams=JLrsUtils.createFeatureStoreParams(outputLayerPathFile, projection);
+            params.setNewFeatureStoreParameters(newFeatureStoreParams);
+        } catch (Exception e) {
+            throw new LrsNeededParameterException("error_creating_outputStore", e);
+        }
+
+        LrsSourceOfMeasures measureSources = (LrsSourceOfMeasures) this.cmbMeasureSource.getSelectedItem();
+        FeatureAttributeDescriptor fromMeasureField = (FeatureAttributeDescriptor) this.cmbFromMeasureField.getSelectedItem();
+        FeatureAttributeDescriptor toMeasureField = (FeatureAttributeDescriptor) this.cmbToMeasureField.getSelectedItem();
+        params.setSourceOfMeasures(measureSources);
+        switch (measureSources) {
+        case ONE_FIELD:
+            if (fromMeasureField == null) {
+                throw new LrsNeededParameterException("need_to_select_a_length_measure_field", null);
+            }
+            params.setFromMeasureField((FeatureAttributeDescriptor) this.cmbFromMeasureField.getSelectedItem());
+            params.setToMeasureField(null);
+            break;
+        case TWO_FIELDS:
+            if (fromMeasureField == null) {
+                throw new LrsNeededParameterException("need_to_select_a_from_measure_field", null);
+            }
+            params.setFromMeasureField((FeatureAttributeDescriptor) this.cmbFromMeasureField.getSelectedItem());
+            if (toMeasureField == null) {
+                throw new LrsNeededParameterException("need_to_select_a_to_measure_field", null);
+            }
+            params.setToMeasureField((FeatureAttributeDescriptor) this.cmbToMeasureField.getSelectedItem());
+            break;
+        case LENGTH:
+        default:
+            params.setFromMeasureField(null);
+            params.setToMeasureField(null);
+            break;
+        }
+        params.setCoordinatePriority((LrsCoordinatesPriority) this.cmbCoordinatePriority.getSelectedItem());
+
+        Object measureFactor = this.txtMeasureFactor.getValue();
+        if (measureFactor!=null && measureFactor instanceof Double){
+            params.setMeasureFactor((Double)measureFactor);
+        }else {
+            params.setMeasureFactor(0);
+        }
+        Object measureOffset = this.txtMeasureOffset.getValue();
+        if (measureOffset!=null && measureOffset instanceof Double){
+            params.setMeasureOffset((Double)measureOffset);
+        }else {
+            params.setMeasureOffset(0);
+        }
+
+        params.setIgnoreSpatialGaps(this.chkIgnoreSpatialGaps.isSelected());
+
+        return params;
+    }
+
+    public void setParams(LrsAlgorithmParams params) {
+        if (params == null) {
+            clear();
+            return;
+        }
+        // Rellena los campos con los valores de params
+        LrsCreateRouteAlgorithmParams parameters = (LrsCreateRouteAlgorithmParams) params;
+
+        this.cmbMeasureSource.setSelectedItem(parameters.getSourceOfMeasures());
+        this.cmbCoordinatePriority.setSelectedItem(parameters.getCoordinatePriority());
+
+        FeatureStore sourceFeatureStore = parameters.getSourceFeatureStore();
+        if(layers!=null && sourceFeatureStore!=null){
+            FLayer layer = layers.getLayer(sourceFeatureStore.getName());
+            this.cmbInputLayer.setSelectedItem(layer);
+        }
+
+        NewFeatureStoreParameters newFeatureStoreParameters = parameters.getNewFeatureStoreParameters();
+        if(newFeatureStoreParameters instanceof SHPNewStoreParameters){
+            this.txtOutputFile.setText(((SHPNewStoreParameters)newFeatureStoreParameters).getSHPFile().getAbsolutePath());
+        }
+
+        this.cmbIdRouteField.setSelectedItem(parameters.getIdRouteField());
+        this.cmbFromMeasureField.setSelectedItem(parameters.getFromMeasureField());
+        this.cmbToMeasureField.setSelectedItem(parameters.getToMeasureField());
+        this.txtMeasureFactor.setValue(parameters.getMeasureFactor());
+        this.txtMeasureOffset.setValue(parameters.getMeasureOffset());
+
+    }
+
+    public void clear() {
+        this.txtOutputFile.setText("");
+        this.txtMeasureFactor.setValue(1.0);
+        this.txtMeasureOffset.setValue(0.0);
+        this.cmbMeasureSource.setSelectedIndex(0);
+        this.cmbFromMeasureField.setEnabled(false);
+        this.cmbToMeasureField.setEnabled(false);
+        this.cmbCoordinatePriority.setSelectedIndex(0);
+        Object inputLayerSelected = this.cmbInputLayer.getSelectedItem();
+        if (inputLayerSelected != null) {
+            this.updateLayer((FLyrVect) inputLayerSelected);
+        }
+        Object measureSourceSelected = this.cmbMeasureSource.getSelectedItem();
+        if (measureSourceSelected != null) {
+            this.updateSourceOfMeasures((LrsSourceOfMeasures) measureSourceSelected);
+        }
+
+    }
+
+    private void updateLayer(FLyrVect layer) {
+        logger.info(new StringBuilder().append("Setting layer ").append(layer.getName()).toString());
+        FeatureStore featureStore = layer.getFeatureStore();
+        try {
+            FeatureType type = featureStore.getDefaultFeatureType();
+            // Se renuevan los combos de attributeDescriptors
+            FeatureAttributeDescriptorsComboBoxModel idRouteFieldComboBoxModel =
+                new FeatureAttributeDescriptorsComboBoxModel();
+            FeatureAttributeDescriptorsComboBoxModel fromMeasureFieldComboBoxModel =
+                new FeatureAttributeDescriptorsComboBoxModel();
+            FeatureAttributeDescriptorsComboBoxModel toMeasureFieldComboBoxModel =
+                new FeatureAttributeDescriptorsComboBoxModel();
+
+            this.cmbIdRouteField.setModel(idRouteFieldComboBoxModel);
+            this.cmbFromMeasureField.setModel(fromMeasureFieldComboBoxModel);
+            this.cmbToMeasureField.setModel(toMeasureFieldComboBoxModel);
+
+            FeatureAttributeDescriptor[] attributeDescriptors = type.getAttributeDescriptors();
+            for (int i = 0; i < attributeDescriptors.length; i++) {
+                FeatureAttributeDescriptor featureAttributeDescriptor = attributeDescriptors[i];
+                if (featureAttributeDescriptor.getDataType().getType() != DataTypes.GEOMETRY) {
+                    logger.info(new StringBuilder().append("Adding field ")
+                        .append(featureAttributeDescriptor.getName()).toString());
+
+                    JLrsCreateRouteParamsController.this.cmbIdRouteField.addItem(featureAttributeDescriptor);
+                    if (featureAttributeDescriptor.getDataType().isNumeric()) {
+                        JLrsCreateRouteParamsController.this.cmbFromMeasureField.addItem(featureAttributeDescriptor);
+                        JLrsCreateRouteParamsController.this.cmbToMeasureField.addItem(featureAttributeDescriptor);
+                    }
+                }
+            }
+            this.cmbIdRouteField.invalidate();
+            this.cmbFromMeasureField.invalidate();
+            this.cmbToMeasureField.invalidate();
+
+        } catch (DataException e1) {
+            logger.warn(
+                new StringBuilder().append("Error getting default feature type from layer ").append(layer.getName())
+                    .toString(), e1);
+        }
+    }
+
+    private void updateSourceOfMeasures(LrsSourceOfMeasures item) {
+        switch (item) {
+        case LENGTH:
+            cmbFromMeasureField.setEnabled(false);
+            cmbToMeasureField.setEnabled(false);
+            cmbCoordinatePriority.setEnabled(true);
+            chkIgnoreSpatialGaps.setEnabled(true);
+            break;
+        case ONE_FIELD:
+            cmbFromMeasureField.setEnabled(true);
+            cmbToMeasureField.setEnabled(false);
+            cmbCoordinatePriority.setEnabled(true);
+            chkIgnoreSpatialGaps.setEnabled(true);
+            break;
+        case TWO_FIELDS:
+            cmbFromMeasureField.setEnabled(true);
+            cmbToMeasureField.setEnabled(true);
+            cmbCoordinatePriority.setEnabled(false);
+            chkIgnoreSpatialGaps.setEnabled(false);
+            break;
+        default:
+            break;
+        }
+    }
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCalculateMRouteController.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCalculateMRouteController.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCalculateMRouteController.java	(revision 950)
@@ -0,0 +1,253 @@
+/*
+ * Copyright 2015 DiSiD Technologies S.L.L. All rights reserved.
+ *
+ * Project  : DiSiD org.gvsig.lrs.swing.impl
+ * SVN Id   : $Id$
+ */
+package org.gvsig.lrs.swing.impl;
+
+import java.awt.Dimension;
+import java.awt.Rectangle;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.util.Locale;
+
+import javax.swing.JComponent;
+import javax.swing.ListCellRenderer;
+
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.feature.FeatureType;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.operations.LayerCollection;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.fmap.mapcontrol.dal.feature.swing.FeatureTablePanel;
+import org.gvsig.lrs.lib.api.LrsAlgorithmParams;
+import org.gvsig.lrs.lib.api.exceptions.LrsGettingParametersException;
+import org.gvsig.lrs.lib.api.exceptions.LrsNeededParameterException;
+import org.gvsig.lrs.swing.api.JLrsAlgorithmParams;
+import org.gvsig.lrs.swing.api.JLrsLastUsedValues;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.exception.BaseException;
+import org.gvsig.tools.i18n.I18nManager;
+import org.gvsig.tools.swing.api.ActionListenerSupport;
+import org.gvsig.tools.swing.api.ToolsSwingLocator;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import com.jgoodies.forms.layout.CellConstraints;
+
+public class JLrsCalculateMRouteController extends JLrsCalculateMRouteView  implements JLrsAlgorithmParams{
+
+    /**
+     *
+     */
+    private static final long serialVersionUID = -9145489136943076981L;
+
+    private static final Logger logger = LoggerFactory.getLogger(JLrsCalculateMRouteController.class);
+
+    private boolean canceled;
+    private ActionListenerSupport listeners = ToolsSwingLocator.getToolsSwingManager().createActionListenerSupport();
+
+    private FLayer layer;
+    
+    private JLrsLastUsedValues params;
+
+    /**
+     * @param layer
+     * @throws LrsNeededParameterException
+     * @throws  
+     *
+     */
+    public JLrsCalculateMRouteController(FLayer layer,  JLrsLastUsedValues jLrsLastUsedValues) throws LrsNeededParameterException {
+        super();
+        this.layer = layer;
+        this.params = jLrsLastUsedValues;
+        initComponents();
+        translate();
+    }
+
+    public void addActionListener(ActionListener listener) {
+        listeners.addActionListener(listener);
+    }
+
+    public void removeActionListener(ActionListener listener) {
+        listeners.removeActionListener(listener);
+    }
+
+    private void translate() {
+        I18nManager i18nManager = ToolsLocator.getI18nManager();
+        jroutesselected
+            .setText(i18nManager.getTranslation(jroutesselected.getText()));
+        pkilabel.setText(i18nManager.getTranslation(pkilabel.getText())+"  ");
+        pkflabel.setText(i18nManager.getTranslation(pkflabel.getText())+"  ");
+
+    }
+
+    /**
+     *
+     */
+    public void setLocate(Locale locale) {
+        Locale l = super.getLocale();
+        if (!l.equals(locale)) {
+            translate();
+        }
+        super.setLocale(locale);
+    }
+    
+    
+
+    /**
+     * Validates the layers:
+     *  - At least 2 layers
+     *  - At least 1 curve layer with at least 1 non-geometric field
+     *  - At least 1 point layer with at least 1 non-geometric field and 1 numeric field
+     *  if they are not correct throws an exception
+     * @throws LrsNeededParameterException
+     */
+    public static void validateLayers(LayerCollection layers)throws LrsNeededParameterException {
+        logger.debug("Validating layers for Calibrate Route");
+        if (layers==null||layers.getLayersCount()<2){
+            logger.error("Two or more layers are needed");
+            throw new LrsNeededParameterException("two_or_more_layers_are_needed", null);
+        }
+
+        if (!JLrsUtils.validatedMCurveAndPointLayer(layers)){
+            logger.error("Impossible to find the layers needed");
+            throw new LrsNeededParameterException("impossible_to_find_needed_layers",null);
+        }
+    }
+
+    /**
+     * @throws LrsNeededParameterException
+     * @throws DataException 
+     */
+    private void initComponents() throws LrsNeededParameterException {
+
+//        validateLayers(layers);
+
+//        FeatureAttributeDescriptorsComboBoxModel idRouteFieldInitialComboBoxModel =
+//            new FeatureAttributeDescriptorsComboBoxModel();
+//        FeatureAttributeDescriptorsComboBoxModel idRouteFieldFinalComboBoxModel =
+//                new FeatureAttributeDescriptorsComboBoxModel();
+//
+//        // Renderer para los combos de attributeDescriptors
+//        ListCellRenderer featureAttributeDescriptorCellRenderer = new FLayersAttributeDescriptorCellRenderer();
+//        // asignación de renderers y modelos
+//        pkicombo.setRenderer(featureAttributeDescriptorCellRenderer);
+//        pkicombo.setModel(idRouteFieldInitialComboBoxModel);
+//        
+//        pkfcombo.setRenderer(featureAttributeDescriptorCellRenderer);
+//        pkfcombo.setModel(idRouteFieldFinalComboBoxModel);
+//        
+        
+        pkicombo.addActionListener(new ActionListener() {
+			@Override
+			public void actionPerformed(ActionEvent e) {
+				String desc = (String) pkicombo.getSelectedItem();
+				if(desc != null){
+					logger.debug("Selected pk-initial combo option: " + desc);
+					params.setPkInicial(desc);
+				}
+			}
+		});
+        
+        pkfcombo.addActionListener(new ActionListener() {
+			@Override
+			public void actionPerformed(ActionEvent e) {
+				String desc = (String) pkfcombo.getSelectedItem();
+				if(desc != null){
+					logger.debug("Selected pk-final combo option: " + desc);
+					params.setPkFinal(desc);
+				}
+			}
+		});
+        
+        if (layer instanceof FLyrVect) {
+        	FLyrVect lyrVect = (FLyrVect) layer;
+        	FeatureStore featStore = lyrVect.getFeatureStore();
+        	try {
+        		FeatureType featType = featStore.getDefaultFeatureType();
+        		FeatureAttributeDescriptor[] descrips = featType.getAttributeDescriptors();
+        		for(int i=0; i<descrips.length; i++){
+        			FeatureAttributeDescriptor featureAttributeDescriptor = descrips[i];
+        			if (featureAttributeDescriptor.getDataType().isNumeric()) {
+        				pkicombo.addItem(featureAttributeDescriptor.getName());
+        				pkfcombo.addItem(featureAttributeDescriptor.getName());
+        			}
+        		}
+
+        		if(params != null){
+        			pkicombo.setSelectedItem(params.getPkInicial());
+        			pkfcombo.setSelectedItem(params.getPkFinal());
+        		}
+
+        		routestable = new FeatureTablePanel(featStore);
+        		//routestable.setSelectionUp(true);
+        		
+        		//int selectIdx = routestable.getTable().getSelectedRow();
+        		//routestable.getTable().getSelectionModel().setSelectionInterval(selectIdx, selectIdx);
+        		//routestable.getTable().scrollRectToVisible(new Rectangle(routestable.getTable().getCellRect(selectIdx, 0, true)));
+
+        		CellConstraints cc = new CellConstraints();
+        		routestable.setName("routestable");
+        		jLrsCalculateMRoutePanel.add(routestable,cc.xyw(1,5,5));
+
+
+        	} catch (BaseException e) {
+        		throw new LrsNeededParameterException(e);
+        	}
+
+
+        }
+
+
+        canceled = false;
+    }
+
+
+
+    public boolean isCanceled() {
+        return this.canceled;
+    }
+
+
+    public JComponent asJComponent() {
+        return this;
+    }
+
+
+    @Override
+    public Dimension getPreferredSize() {
+        return new Dimension(650, 350);
+    }
+
+	public LrsAlgorithmParams getParams() throws LrsGettingParametersException, LrsNeededParameterException {
+		// TODO Auto-generated method stub
+		return null;
+	}
+
+	public void setParams(LrsAlgorithmParams params) {
+		// TODO Auto-generated method stub
+		
+	}
+
+	public void clear() {
+		// TODO Auto-generated method stub
+		
+	}
+
+	public void setVisibleAceptCancel(boolean visible) {
+		// TODO Auto-generated method stub
+		
+	}
+
+	public boolean getVisibleAceptCancel() {
+		// TODO Auto-generated method stub
+		return false;
+	}
+
+
+
+}

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCalculateMRouteController.java
___________________________________________________________________
Added: svn:mime-type
   + text/plain

Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/DefaultLrsAlgorithmsSwingLibrary.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/DefaultLrsAlgorithmsSwingLibrary.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/DefaultLrsAlgorithmsSwingLibrary.java	(revision 950)
@@ -0,0 +1,56 @@
+/**
+ * gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+
+package org.gvsig.lrs.swing.impl;
+
+import org.gvsig.lrs.swing.api.LrsAlgorithmsSwingLibrary;
+import org.gvsig.lrs.swing.api.LrsAlgorithmsSwingLocator;
+import org.gvsig.tools.library.AbstractLibrary;
+import org.gvsig.tools.library.LibraryException;
+
+
+/**
+ * @author fdiaz</a>
+ *
+ */
+public class DefaultLrsAlgorithmsSwingLibrary extends AbstractLibrary {
+
+
+
+	@Override
+    public void doRegistration() {
+        registerAsImplementationOf(LrsAlgorithmsSwingLibrary.class);
+    }
+
+    @Override
+    protected void doInitialize() throws LibraryException {
+        LrsAlgorithmsSwingLocator.registerLrsAlgorithmsSwingManager(DefaultLrsAlgorithmsSwingManager.class);
+    }
+
+    @Override
+    protected void doPostInitialize() throws LibraryException {
+
+	}
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/FLayersMComboBoxModel.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/FLayersMComboBoxModel.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/FLayersMComboBoxModel.java	(revision 950)
@@ -0,0 +1,130 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.swing.impl;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.swing.AbstractListModel;
+import javax.swing.ComboBoxModel;
+
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.operations.LayerCollection;
+import org.gvsig.fmap.mapcontext.layers.operations.LayersVisitor;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.tools.exception.BaseException;
+import org.gvsig.tools.visitor.VisitCanceledException;
+
+/**
+ * @author fdiaz
+ *
+ */
+public class FLayersMComboBoxModel extends AbstractListModel<FLayer> implements ComboBoxModel<FLayer> {
+
+    /**
+     *
+     */
+    private static final long serialVersionUID = 3596872067610443726L;
+
+    private static final Logger logger = LoggerFactory.getLogger(FLayersMComboBoxModel.class);
+
+    private List<FLyrVect> vectLayers;
+    private FLayer selectedLayer;
+
+    /**
+     *
+     */
+    public FLayersMComboBoxModel(LayerCollection layers) {
+        vectLayers = new ArrayList<FLyrVect>();
+        try {
+            layers.accept(new LayersVisitor() {
+
+                public void visit(Object obj) throws VisitCanceledException, BaseException {
+                    // TODO Auto-generated method stub
+
+                }
+
+                public void visit(FLayer layer) throws BaseException {
+                    if (layer instanceof FLyrVect) {
+                        FLyrVect lyrVect = (FLyrVect) layer;
+                        if ((lyrVect.getGeometryType().isTypeOf(Geometry.TYPES.CURVE)
+                            || lyrVect.getGeometryType().isTypeOf(Geometry.TYPES.MULTICURVE))
+                            &&
+                            (lyrVect.getGeometryType().isSubTypeOf(Geometry.SUBTYPES.GEOM2DM)
+                                || lyrVect.getGeometryType().isSubTypeOf(Geometry.SUBTYPES.GEOM3DM))
+                            ) {
+                            vectLayers.add(lyrVect);
+                            if(lyrVect.isActive()){
+                                selectedLayer = lyrVect;
+                            }
+                        }
+                    }
+                }
+            });
+        } catch (BaseException e1) {
+            logger.warn("Can't get linear vector layers", e1);
+        }
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see javax.swing.ListModel#getSize()
+     */
+    public int getSize() {
+        return vectLayers.size(); //.getLayersCount();
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see javax.swing.ListModel#getElementAt(int)
+     */
+    public FLayer getElementAt(int index) {
+        return vectLayers.get(index); //.getLayer(index);
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see javax.swing.ComboBoxModel#setSelectedItem(java.lang.Object)
+     */
+    public void setSelectedItem(final Object anItem) {
+        selectedLayer = (FLayer) anItem;
+        fireContentsChanged(this, -1, -1);
+    }
+
+    /*
+     * (non-Javadoc)
+     *
+     * @see javax.swing.ComboBoxModel#getSelectedItem()
+     */
+    public Object getSelectedItem() {
+        return selectedLayer;
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/DefaultProgressDialogController.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/DefaultProgressDialogController.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/DefaultProgressDialogController.java	(revision 950)
@@ -0,0 +1,144 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.swing.impl;
+
+import java.awt.BorderLayout;
+import java.awt.Dimension;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.util.Locale;
+
+import javax.swing.JComponent;
+
+import org.gvsig.lrs.swing.api.JLrsProgressDialog;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.i18n.I18nManager;
+import org.gvsig.tools.swing.api.ActionListenerSupport;
+import org.gvsig.tools.swing.api.ToolsSwingLocator;
+import org.gvsig.tools.swing.api.task.JTaskStatus;
+import org.gvsig.tools.swing.api.task.TaskStatusSwingManager;
+import org.gvsig.tools.task.TaskStatus;
+
+
+/**
+ * @author fdiaz
+ *
+ */
+public class DefaultProgressDialogController extends DefaultProgressDialogView implements JLrsProgressDialog {
+
+
+    /**
+     *
+     */
+    private static final long serialVersionUID = -209468236996921114L;
+    private TaskStatus taskStatus;
+    private ActionListenerSupport listeners = ToolsSwingLocator.getToolsSwingManager().createActionListenerSupport();
+
+    private boolean canceled;
+
+
+    /**
+     *
+     */
+    public DefaultProgressDialogController(TaskStatus taskStatus) {
+        super();
+        this.taskStatus = taskStatus;
+        initComponents();
+        translate();
+
+    }
+
+    private void initComponents() {
+        setPreferredSize(new Dimension(400, 150));
+        TaskStatusSwingManager jTaskManager = ToolsSwingLocator.getTaskStatusSwingManager();
+        this.progressBar.setLayout(new BorderLayout());
+        JTaskStatus jTaskStatus = jTaskManager.createJTaskStatus();
+        jTaskStatus.bind(this.taskStatus);
+        jTaskStatus.setShowCancelButton(false);
+        jTaskStatus.setShowRemoveTaskButton(false);
+
+        this.progressBar.add(jTaskStatus, BorderLayout.CENTER);
+
+        this.btnClose.addActionListener(new ActionListener() {
+            public void actionPerformed(ActionEvent e) {
+                canceled = false;
+                if (!DefaultProgressDialogController.this.taskStatus.isRunning()) {
+                    doClose();
+                    listeners.fireActionEvent(new ActionEvent(DefaultProgressDialogController.this, 0, "close"));
+                }
+            }
+        });
+        canceled = false;
+    }
+
+    private void translate() {
+        I18nManager i18nManager = ToolsLocator.getI18nManager();
+        btnClose.setText(i18nManager.getTranslation(btnClose.getText()));
+
+    }
+    /* (non-Javadoc)
+     * @see org.gvsig.tools.swing.api.Component#asJComponent()
+     */
+    public JComponent asJComponent() {
+        return this;
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.swing.api.JLrsProgressDialog#isCanceled()
+     */
+    public boolean isCanceled() {
+        // TODO Auto-generated method stub
+        return false;
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.swing.api.JLrsProgressDialog#addActionListener(java.awt.event.ActionListener)
+     */
+    public void addActionListener(ActionListener listener) {
+        listeners.addActionListener(listener);
+    }
+
+    /* (non-Javadoc)
+     * @see org.gvsig.lrs.swing.api.JLrsProgressDialog#removeActionListener(java.awt.event.ActionListener)
+     */
+    public void removeActionListener(ActionListener listener) {
+        listeners.removeActionListener(listener);
+    }
+
+
+    private void doClose() {
+        this.setVisible(false);
+    }
+
+    /**
+    *
+    */
+   public void setLocate(Locale locale) {
+       Locale l = super.getLocale();
+       if (!l.equals(locale)) {
+           translate();
+       }
+       super.setLocale(locale);
+   }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCalibrateRouteParamsView.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCalibrateRouteParamsView.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCalibrateRouteParamsView.java	(revision 950)
@@ -0,0 +1,294 @@
+package org.gvsig.lrs.swing.impl;
+
+import com.jgoodies.forms.layout.CellConstraints;
+import com.jgoodies.forms.layout.FormLayout;
+import java.awt.BorderLayout;
+import java.awt.ComponentOrientation;
+import java.awt.Container;
+import java.awt.Dimension;
+import javax.swing.Box;
+import javax.swing.ImageIcon;
+import javax.swing.JButton;
+import javax.swing.JCheckBox;
+import javax.swing.JComboBox;
+import javax.swing.JFrame;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+import javax.swing.JTextField;
+
+
+public class JLrsCalibrateRouteParamsView extends JPanel
+{
+   JLabel lblInputLayer = new JLabel();
+   JComboBox cmbInputLayer = new JComboBox();
+   JLabel lblIdRouteField = new JLabel();
+   JComboBox cmbIdRouteField = new JComboBox();
+   JLabel lblMeasureField = new JLabel();
+   JComboBox cmbMeasureField = new JComboBox();
+   JLabel lblOutputFile = new JLabel();
+   JComboBox cmbCalibratePointLayer = new JComboBox();
+   JLabel lblCalibratePointLayer = new JLabel();
+   JComboBox cmbCalibrationPointIdRouteField = new JComboBox();
+   JLabel lblCalibrationPointIdRouteField = new JLabel();
+   JComboBox cmbMeasureCalcMethod = new JComboBox();
+   JLabel lblMeasureCalcMethod = new JLabel();
+   JCheckBox chkInterpolateBetweenCalibrationPoints = new JCheckBox();
+   JCheckBox chkExtrapolateBeforeCalibrationPoints = new JCheckBox();
+   JCheckBox chkExtrapolateAfterCalibrationPoints = new JCheckBox();
+   JCheckBox chkIgnoreSpatialGaps = new JCheckBox();
+   JCheckBox chkIncludeAll = new JCheckBox();
+   JLabel lblSearchRadius = new JLabel();
+   JTextField txtOutputFile = new JTextField();
+   JButton btnBrowser = new JButton();
+   JComboBox cmbMeasureUnits = new JComboBox();
+   JTextField txtSearchRadius = new JTextField();
+   JButton btnAccept = new JButton();
+   JButton btnCancel = new JButton();
+
+   /**
+    * Default constructor
+    */
+   public JLrsCalibrateRouteParamsView()
+   {
+      initializePanel();
+   }
+
+   /**
+    * Adds fill components to empty cells in the first row and first column of the grid.
+    * This ensures that the grid spacing will be the same as shown in the designer.
+    * @param cols an array of column indices in the first row where fill components should be added.
+    * @param rows an array of row indices in the first column where fill components should be added.
+    */
+   void addFillComponents( Container panel, int[] cols, int[] rows )
+   {
+      Dimension filler = new Dimension(10,10);
+
+      boolean filled_cell_11 = false;
+      CellConstraints cc = new CellConstraints();
+      if ( cols.length > 0 && rows.length > 0 )
+      {
+         if ( cols[0] == 1 && rows[0] == 1 )
+         {
+            /** add a rigid area  */
+            panel.add( Box.createRigidArea( filler ), cc.xy(1,1) );
+            filled_cell_11 = true;
+         }
+      }
+
+      for( int index = 0; index < cols.length; index++ )
+      {
+         if ( cols[index] == 1 && filled_cell_11 )
+         {
+            continue;
+         }
+         panel.add( Box.createRigidArea( filler ), cc.xy(cols[index],1) );
+      }
+
+      for( int index = 0; index < rows.length; index++ )
+      {
+         if ( rows[index] == 1 && filled_cell_11 )
+         {
+            continue;
+         }
+         panel.add( Box.createRigidArea( filler ), cc.xy(1,rows[index]) );
+      }
+
+   }
+
+   /**
+    * Helper method to load an image file from the CLASSPATH
+    * @param imageName the package and name of the file to load relative to the CLASSPATH
+    * @return an ImageIcon instance with the specified image file
+    * @throws IllegalArgumentException if the image resource cannot be loaded.
+    */
+   public ImageIcon loadImage( String imageName )
+   {
+      try
+      {
+         ClassLoader classloader = getClass().getClassLoader();
+         java.net.URL url = classloader.getResource( imageName );
+         if ( url != null )
+         {
+            ImageIcon icon = new ImageIcon( url );
+            return icon;
+         }
+      }
+      catch( Exception e )
+      {
+         e.printStackTrace();
+      }
+      throw new IllegalArgumentException( "Unable to load image: " + imageName );
+   }
+
+   /**
+    * Method for recalculating the component orientation for
+    * right-to-left Locales.
+    * @param orientation the component orientation to be applied
+    */
+   public void applyComponentOrientation( ComponentOrientation orientation )
+   {
+      // Not yet implemented...
+      // I18NUtils.applyComponentOrientation(this, orientation);
+      super.applyComponentOrientation(orientation);
+   }
+
+   public JPanel createPanel()
+   {
+      JPanel jpanel1 = new JPanel();
+      FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:GROW(1.0),FILL:DEFAULT:NONE,FILL:DEFAULT:NONE","CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:GROW(1.0),BOTTOM:DEFAULT:NONE,CENTER:DEFAULT:NONE");
+      CellConstraints cc = new CellConstraints();
+      jpanel1.setLayout(formlayout1);
+
+      lblInputLayer.setName("lblInputLayer");
+      lblInputLayer.setText("source");
+      jpanel1.add(lblInputLayer,cc.xy(2,2));
+
+      cmbInputLayer.setName("cmbInputLayer");
+      jpanel1.add(cmbInputLayer,cc.xywh(4,2,2,1));
+
+      lblIdRouteField.setName("lblIdRouteField");
+      lblIdRouteField.setText("id_route_field");
+      jpanel1.add(lblIdRouteField,cc.xy(2,3));
+
+      cmbIdRouteField.setName("cmbIdRouteField");
+      jpanel1.add(cmbIdRouteField,cc.xywh(4,3,2,1));
+
+      lblMeasureField.setName("lblMeasureField");
+      lblMeasureField.setText("measures_field");
+      jpanel1.add(lblMeasureField,cc.xy(2,6));
+
+      cmbMeasureField.setName("cmbMeasureField");
+      jpanel1.add(cmbMeasureField,cc.xywh(4,6,2,1));
+
+      lblOutputFile.setName("lblOutputFile");
+      lblOutputFile.setText("output_file");
+      jpanel1.add(lblOutputFile,cc.xy(2,7));
+
+      cmbCalibratePointLayer.setName("cmbCalibratePointLayer");
+      jpanel1.add(cmbCalibratePointLayer,cc.xywh(4,4,2,1));
+
+      lblCalibratePointLayer.setName("lblCalibratePointLayer");
+      lblCalibratePointLayer.setText("calibrate_point_layer");
+      jpanel1.add(lblCalibratePointLayer,cc.xy(2,4));
+
+      cmbCalibrationPointIdRouteField.setName("cmbCalibrationPointIdRouteField");
+      jpanel1.add(cmbCalibrationPointIdRouteField,cc.xywh(4,5,2,1));
+
+      lblCalibrationPointIdRouteField.setName("lblCalibrationPointIdRouteField");
+      lblCalibrationPointIdRouteField.setText("id_calibration_point_route_field");
+      jpanel1.add(lblCalibrationPointIdRouteField,cc.xy(2,5));
+
+      cmbMeasureCalcMethod.setName("cmbMeasureCalcMethod");
+      jpanel1.add(cmbMeasureCalcMethod,cc.xywh(4,8,2,1));
+
+      lblMeasureCalcMethod.setName("lblMeasureCalcMethod");
+      lblMeasureCalcMethod.setText("measure_calc_method");
+      jpanel1.add(lblMeasureCalcMethod,cc.xy(2,8));
+
+      chkInterpolateBetweenCalibrationPoints.setActionCommand("JCBIgnoreSpatialGaps");
+      chkInterpolateBetweenCalibrationPoints.setName("chkInterpolateBetweenCalibrationPoints");
+      chkInterpolateBetweenCalibrationPoints.setText("interpolate_between_calibration_points");
+      jpanel1.add(chkInterpolateBetweenCalibrationPoints,cc.xywh(2,10,4,1));
+
+      chkExtrapolateBeforeCalibrationPoints.setActionCommand("JCBIgnoreSpatialGaps");
+      chkExtrapolateBeforeCalibrationPoints.setName("chkExtrapolateBeforeCalibrationPoints");
+      chkExtrapolateBeforeCalibrationPoints.setText("extrapolate_before_calibration_points");
+      jpanel1.add(chkExtrapolateBeforeCalibrationPoints,cc.xywh(2,11,4,1));
+
+      chkExtrapolateAfterCalibrationPoints.setActionCommand("JCBIgnoreSpatialGaps");
+      chkExtrapolateAfterCalibrationPoints.setName("chkExtrapolateAfterCalibrationPoints");
+      chkExtrapolateAfterCalibrationPoints.setText("extrapolate_after_calibration_points");
+      jpanel1.add(chkExtrapolateAfterCalibrationPoints,cc.xywh(2,12,4,1));
+
+      chkIgnoreSpatialGaps.setActionCommand("JCBIgnoreSpatialGaps");
+      chkIgnoreSpatialGaps.setName("chkIgnoreSpatialGaps");
+      chkIgnoreSpatialGaps.setText("ignore_spatial_gaps");
+      jpanel1.add(chkIgnoreSpatialGaps,cc.xywh(2,13,4,1));
+
+      chkIncludeAll.setActionCommand("JCBIgnoreSpatialGaps");
+      chkIncludeAll.setName("chkIncludeAll");
+      chkIncludeAll.setText("include_all");
+      jpanel1.add(chkIncludeAll,cc.xywh(2,14,4,1));
+
+      lblSearchRadius.setName("lblSearchRadius");
+      lblSearchRadius.setText("search_radius");
+      jpanel1.add(lblSearchRadius,cc.xy(2,9));
+
+      jpanel1.add(createPanel1(),cc.xywh(4,7,2,1));
+      jpanel1.add(createPanel2(),cc.xywh(4,9,2,1));
+      jpanel1.add(createPanel3(),new CellConstraints(2,16,4,1,CellConstraints.RIGHT,CellConstraints.DEFAULT));
+      addFillComponents(jpanel1,new int[]{ 1,2,3,4,5,6 },new int[]{ 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17 });
+      return jpanel1;
+   }
+
+   public JPanel createPanel1()
+   {
+      JPanel jpanel1 = new JPanel();
+      FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:GROW(1.0),FILL:36PX:NONE","CENTER:DEFAULT:NONE");
+      CellConstraints cc = new CellConstraints();
+      jpanel1.setLayout(formlayout1);
+
+      txtOutputFile.setName("txtOutputFile");
+      txtOutputFile.setHorizontalAlignment(JTextField.LEFT);
+      jpanel1.add(txtOutputFile,cc.xy(1,1));
+
+      btnBrowser.setActionCommand("JButton");
+      btnBrowser.setName("btnBrowser");
+      btnBrowser.setOpaque(false);
+      btnBrowser.setRolloverEnabled(true);
+      btnBrowser.setText("...");
+      jpanel1.add(btnBrowser,cc.xy(2,1));
+
+      addFillComponents(jpanel1,new int[0],new int[0]);
+      return jpanel1;
+   }
+
+   public JPanel createPanel2()
+   {
+      JPanel jpanel1 = new JPanel();
+      FormLayout formlayout1 = new FormLayout("FILL:20DLU:GROW(1.0),FILL:DEFAULT:NONE","CENTER:DEFAULT:NONE");
+      CellConstraints cc = new CellConstraints();
+      jpanel1.setLayout(formlayout1);
+
+      cmbMeasureUnits.setName("cmbMeasureUnits");
+      jpanel1.add(cmbMeasureUnits,cc.xy(2,1));
+
+      txtSearchRadius.setName("txtSearchRadius");
+      jpanel1.add(txtSearchRadius,cc.xy(1,1));
+
+      addFillComponents(jpanel1,new int[0],new int[0]);
+      return jpanel1;
+   }
+
+   public JPanel createPanel3()
+   {
+      JPanel jpanel1 = new JPanel();
+      FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE","CENTER:DEFAULT:NONE");
+      CellConstraints cc = new CellConstraints();
+      jpanel1.setLayout(formlayout1);
+
+      btnAccept.setActionCommand("_Accept");
+      btnAccept.setName("btnAccept");
+      btnAccept.setText("_Accept");
+      jpanel1.add(btnAccept,cc.xy(1,1));
+
+      btnCancel.setActionCommand("_Cancel");
+      btnCancel.setName("btnCancel");
+      btnCancel.setText("_Cancel");
+      jpanel1.add(btnCancel,cc.xy(3,1));
+
+      addFillComponents(jpanel1,new int[]{ 2 },new int[0]);
+      return jpanel1;
+   }
+
+   /**
+    * Initializer
+    */
+   protected void initializePanel()
+   {
+      setLayout(new BorderLayout());
+      add(createPanel(), BorderLayout.CENTER);
+   }
+
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/FeatureStoreNameCellRenderer.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/FeatureStoreNameCellRenderer.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/FeatureStoreNameCellRenderer.java	(revision 950)
@@ -0,0 +1,34 @@
+/*
+ * Copyright 2015 DiSiD Technologies S.L.L. All rights reserved.
+ *
+ * Project  : DiSiD org.gvsig.lrs.swing.impl
+ * SVN Id   : $Id$
+ */
+package org.gvsig.lrs.swing.impl;
+
+import java.awt.Component;
+
+import javax.swing.DefaultListCellRenderer;
+import javax.swing.JLabel;
+import javax.swing.JList;
+import javax.swing.ListCellRenderer;
+
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+
+public class FeatureStoreNameCellRenderer implements ListCellRenderer{
+
+
+    protected DefaultListCellRenderer defaultRenderer = new DefaultListCellRenderer();
+
+    public Component getListCellRendererComponent(JList list, Object value, int index, boolean isSelected,
+        boolean cellHasFocus) {
+        JLabel renderer =
+            (JLabel) defaultRenderer.getListCellRendererComponent(list, value, index, isSelected, cellHasFocus);
+        if (value instanceof FeatureStore) {
+            renderer.setText(((FeatureStore) value).getName());
+        }
+        return renderer;
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/EditRouteCalibrationTableModel.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/EditRouteCalibrationTableModel.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/EditRouteCalibrationTableModel.java	(revision 950)
@@ -0,0 +1,211 @@
+/* gvSIG. Desktop Geographic Information System.
+ *
+ * Copyright © 2007-2015 gvSIG Association
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
+ * MA  02110-1301, USA.
+ *
+ * For any additional information, do not hesitate to contact us
+ * at info AT gvsig.com, or visit our website www.gvsig.com.
+ */
+package org.gvsig.lrs.swing.impl;
+
+import java.util.List;
+import javax.swing.table.AbstractTableModel;
+import org.apache.commons.lang3.mutable.MutableInt;
+import org.gvsig.fmap.geom.Geometry;
+import org.gvsig.fmap.geom.aggregate.MultiLine;
+import org.gvsig.fmap.geom.primitive.Line;
+import org.gvsig.fmap.geom.primitive.Point;
+import org.gvsig.tools.exception.BaseException;
+
+public class EditRouteCalibrationTableModel extends AbstractTableModel {
+
+    private static final long serialVersionUID = -2678580144252993562L;
+    private static final String[] COLUMN_NAMES = { "IdRoute", "OrderPoint", "XCoordinate", "YCoordinate", "MCoordinate" };
+
+    private final String routeName;
+    private final Geometry geometry;
+    private final List<Double> mCoordinates;
+    
+    private Object[][] data;
+    private int rowCount;
+    private Double valueUpdated;
+    private Double maxValue;
+    private Double minValue;
+
+    public static int COLUMN_ROUTE_NAME=0;
+    public static int COLUMN_ORDER=1;
+    public static int COLUMN_XCOORDINATE=2;
+    public static int COLUMN_YCOORDINATE=3;
+    public static int COLUMN_MCOORDINATE=4;
+
+    public EditRouteCalibrationTableModel(String routeName, Geometry geometry, List<Double> mCoordinates) throws BaseException {
+        this.routeName = routeName;
+        this.geometry = geometry;
+        this.mCoordinates = mCoordinates;
+        setRowCount();
+        this.data = new Object[getRowCount()][getColumnCount()];
+        fillData();
+        valueUpdated=Double.NaN;
+    }
+
+    private void fillData() throws BaseException {
+        final MutableInt rowNumber = new MutableInt(0);
+        maxValue = null;
+        minValue = null;
+
+        Double mValue;
+        int k = 0;
+        int order = 0;
+        if (geometry.getGeometryType().isTypeOf(Geometry.TYPES.LINE)) {
+            Line line = (Line) geometry;
+            for (int i = 0; i < line.getNumVertices(); i++) {
+                data[rowNumber.getValue()][COLUMN_ROUTE_NAME] = routeName; //IDROUTE
+                data[rowNumber.getValue()][COLUMN_ORDER] = order++; //ORDER
+                Point vertex = line.getVertex(i);
+                data[rowNumber.getValue()][COLUMN_XCOORDINATE] = vertex.getX(); //XCOORDINATE
+                data[rowNumber.getValue()][COLUMN_YCOORDINATE] = vertex.getY(); //YCOORDINATE
+
+                if (mCoordinates == null) {
+                    mValue = vertex.getCoordinateAt(vertex.getDimension() - 1); //MCOORDINATE
+                } else {
+                    mValue = this.mCoordinates.get(k++);
+                }
+
+                data[rowNumber.getValue()][COLUMN_MCOORDINATE] = mValue;
+                if (maxValue == null || maxValue.compareTo(mValue) < 0) {
+                    maxValue = mValue;
+                }
+                if (minValue == null || minValue.compareTo(mValue) > 0) {
+                    minValue = mValue;
+                }
+
+                rowNumber.setValue(rowNumber.getValue() + 1);
+            }
+        } else if (geometry.getGeometryType().isTypeOf(Geometry.TYPES.MULTILINE)) {
+            MultiLine multiline = (MultiLine) geometry;
+            for (int i = 0; i < multiline.getPrimitivesNumber(); i++) {
+                Line line = (Line) multiline.getPrimitiveAt(i);
+                for (int j = 0; j < line.getNumVertices(); j++) {
+                    data[rowNumber.getValue()][COLUMN_ROUTE_NAME] = routeName; //IDROUTE
+                    data[rowNumber.getValue()][COLUMN_ORDER] = order++; //ORDER
+                    Point vertex = line.getVertex(j);
+                    data[rowNumber.getValue()][COLUMN_XCOORDINATE] = vertex.getX(); //XCOORDINATE
+                    data[rowNumber.getValue()][COLUMN_YCOORDINATE] = vertex.getY(); //YCOORDINATE
+
+                    if (mCoordinates == null) {
+                        mValue = vertex.getCoordinateAt(vertex.getDimension() - 1); //MCOORDINATE
+                    } else {
+                        mValue = this.mCoordinates.get(k++);
+                    }
+
+                    data[rowNumber.getValue()][COLUMN_MCOORDINATE] = mValue;
+                    if (maxValue == null || maxValue.compareTo(mValue) < 0) {
+                        maxValue = mValue;
+                    }
+                    if (minValue == null || minValue.compareTo(mValue) > 0) {
+                        minValue = mValue;
+                    }
+
+                    rowNumber.setValue(rowNumber.getValue() + 1);
+                }
+            }
+        }
+    }
+
+    private void setRowCount() throws BaseException {
+        final MutableInt rowNumber = new MutableInt(0);
+
+        if (geometry.getGeometryType().isTypeOf(Geometry.TYPES.LINE)) {
+            Line line = (Line) geometry;
+            for (int i = 0; i < line.getNumVertices(); i++) {
+                rowNumber.setValue(rowNumber.getValue() + 1);
+            }
+        }
+
+        if (geometry.getGeometryType().isTypeOf(Geometry.TYPES.MULTILINE)) {
+            MultiLine multiline = (MultiLine) geometry;
+            for (int i = 0; i < multiline.getPrimitivesNumber(); i++) {
+                Line line = (Line) multiline.getPrimitiveAt(i);
+                for (int j = 0; j < line.getNumVertices(); j++) {
+                    rowNumber.setValue(rowNumber.getValue() + 1);
+                }
+            }
+        }
+        rowCount = rowNumber.toInteger();
+    }
+
+    @Override
+    public int getColumnCount() {
+        return COLUMN_NAMES.length;
+    }
+
+    @Override
+    public int getRowCount() {
+        return rowCount;
+    }
+
+    @Override
+    public String getColumnName(int col) {
+        return COLUMN_NAMES[col];
+    }
+
+    @Override
+    public Object getValueAt(int i, int j) {
+        return data[i][j];
+    }
+
+    @Override
+    public boolean isCellEditable(int row, int col) {
+        return (col == COLUMN_MCOORDINATE);
+    }
+
+    @Override
+    public void setValueAt(Object value, int row, int col) {
+        if (value!=null ){
+            try {
+                valueUpdated = Double.parseDouble((String) value);
+                fireTableCellUpdated(row,col);
+            } catch (Exception ex) {
+                //Do nothing
+            }
+        }
+      }
+
+
+    public Object[][] getData() {
+        return data;
+    }
+
+    public void setData(Object[][] data){
+        this.data=data;
+    }
+
+    public Double getValueUpdated(){
+        return this.valueUpdated;
+    }
+
+
+    public Double getMaxValue() {
+        return maxValue;
+    }
+
+
+    public Double getMinValue() {
+        return minValue;
+    }
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsGenerateDynamicSegmentationParamsView.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsGenerateDynamicSegmentationParamsView.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsGenerateDynamicSegmentationParamsView.java	(revision 950)
@@ -0,0 +1,247 @@
+package org.gvsig.lrs.swing.impl;
+
+import com.jgoodies.forms.layout.CellConstraints;
+import com.jgoodies.forms.layout.FormLayout;
+import java.awt.BorderLayout;
+import java.awt.ComponentOrientation;
+import java.awt.Container;
+import java.awt.Dimension;
+import javax.swing.Box;
+import javax.swing.ImageIcon;
+import javax.swing.JButton;
+import javax.swing.JComboBox;
+import javax.swing.JFrame;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+import javax.swing.JTextField;
+
+
+public class JLrsGenerateDynamicSegmentationParamsView extends JPanel
+{
+   JLabel lblInputLayer = new JLabel();
+   JComboBox cmbInputLayer = new JComboBox();
+   JLabel lblIdRouteField = new JLabel();
+   JComboBox cmbIdRouteField = new JComboBox();
+   JLabel lblTable = new JLabel();
+   JComboBox cmbTable = new JComboBox();
+   JLabel lblTableIdRouteField = new JLabel();
+   JComboBox cmbTableIdRouteField = new JComboBox();
+   JLabel lblLandmarkField = new JLabel();
+   JComboBox cmbLandmarkField = new JComboBox();
+   JLabel lblFinalLandmarkField = new JLabel();
+   JLabel lblValueField = new JLabel();
+   JComboBox cmbFinalLandmarkField = new JComboBox();
+   JComboBox cmbValueField = new JComboBox();
+   JLabel lblOutputFile = new JLabel();
+   JTextField txtOutputFile = new JTextField();
+   JButton btnBrowser = new JButton();
+   JButton btnAccept = new JButton();
+   JButton btnCancel = new JButton();
+
+   /**
+    * Default constructor
+    */
+   public JLrsGenerateDynamicSegmentationParamsView()
+   {
+      initializePanel();
+   }
+
+   /**
+    * Adds fill components to empty cells in the first row and first column of the grid.
+    * This ensures that the grid spacing will be the same as shown in the designer.
+    * @param cols an array of column indices in the first row where fill components should be added.
+    * @param rows an array of row indices in the first column where fill components should be added.
+    */
+   void addFillComponents( Container panel, int[] cols, int[] rows )
+   {
+      Dimension filler = new Dimension(10,10);
+
+      boolean filled_cell_11 = false;
+      CellConstraints cc = new CellConstraints();
+      if ( cols.length > 0 && rows.length > 0 )
+      {
+         if ( cols[0] == 1 && rows[0] == 1 )
+         {
+            /** add a rigid area  */
+            panel.add( Box.createRigidArea( filler ), cc.xy(1,1) );
+            filled_cell_11 = true;
+         }
+      }
+
+      for( int index = 0; index < cols.length; index++ )
+      {
+         if ( cols[index] == 1 && filled_cell_11 )
+         {
+            continue;
+         }
+         panel.add( Box.createRigidArea( filler ), cc.xy(cols[index],1) );
+      }
+
+      for( int index = 0; index < rows.length; index++ )
+      {
+         if ( rows[index] == 1 && filled_cell_11 )
+         {
+            continue;
+         }
+         panel.add( Box.createRigidArea( filler ), cc.xy(1,rows[index]) );
+      }
+
+   }
+
+   /**
+    * Helper method to load an image file from the CLASSPATH
+    * @param imageName the package and name of the file to load relative to the CLASSPATH
+    * @return an ImageIcon instance with the specified image file
+    * @throws IllegalArgumentException if the image resource cannot be loaded.
+    */
+   public ImageIcon loadImage( String imageName )
+   {
+      try
+      {
+         ClassLoader classloader = getClass().getClassLoader();
+         java.net.URL url = classloader.getResource( imageName );
+         if ( url != null )
+         {
+            ImageIcon icon = new ImageIcon( url );
+            return icon;
+         }
+      }
+      catch( Exception e )
+      {
+         e.printStackTrace();
+      }
+      throw new IllegalArgumentException( "Unable to load image: " + imageName );
+   }
+
+   /**
+    * Method for recalculating the component orientation for
+    * right-to-left Locales.
+    * @param orientation the component orientation to be applied
+    */
+   public void applyComponentOrientation( ComponentOrientation orientation )
+   {
+      // Not yet implemented...
+      // I18NUtils.applyComponentOrientation(this, orientation);
+      super.applyComponentOrientation(orientation);
+   }
+
+   public JPanel createPanel()
+   {
+      JPanel jpanel1 = new JPanel();
+      FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:256PX:GROW(1.0),FILL:DEFAULT:NONE","CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:GROW(1.0),CENTER:2DLU:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE");
+      CellConstraints cc = new CellConstraints();
+      jpanel1.setLayout(formlayout1);
+
+      lblInputLayer.setName("lblInputLayer");
+      lblInputLayer.setText("source");
+      jpanel1.add(lblInputLayer,cc.xy(2,2));
+
+      cmbInputLayer.setName("cmbInputLayer");
+      jpanel1.add(cmbInputLayer,cc.xy(4,2));
+
+      lblIdRouteField.setName("lblIdRouteField");
+      lblIdRouteField.setText("id_route_field");
+      jpanel1.add(lblIdRouteField,cc.xy(2,3));
+
+      cmbIdRouteField.setName("cmbIdRouteField");
+      jpanel1.add(cmbIdRouteField,cc.xy(4,3));
+
+      lblTable.setName("lblTable");
+      lblTable.setText("table");
+      jpanel1.add(lblTable,cc.xy(2,4));
+
+      cmbTable.setName("cmbTable");
+      jpanel1.add(cmbTable,cc.xy(4,4));
+
+      lblTableIdRouteField.setName("lblTableIdRouteField");
+      lblTableIdRouteField.setText("table_id_route_field");
+      jpanel1.add(lblTableIdRouteField,cc.xy(2,5));
+
+      cmbTableIdRouteField.setName("cmbTableIdRouteField");
+      jpanel1.add(cmbTableIdRouteField,cc.xy(4,5));
+
+      lblLandmarkField.setName("lblLandmarkField");
+      lblLandmarkField.setText("landmark_field");
+      jpanel1.add(lblLandmarkField,cc.xy(2,6));
+
+      cmbLandmarkField.setName("cmbLandmarkField");
+      jpanel1.add(cmbLandmarkField,cc.xy(4,6));
+
+      lblFinalLandmarkField.setName("lblFinalLandmarkField");
+      lblFinalLandmarkField.setText("final_landmark_field");
+      jpanel1.add(lblFinalLandmarkField,cc.xy(2,7));
+
+      lblValueField.setName("lblValueField");
+      lblValueField.setText("value_field");
+      jpanel1.add(lblValueField,cc.xy(2,8));
+
+      cmbFinalLandmarkField.setName("cmbFinalLandmarkField");
+      jpanel1.add(cmbFinalLandmarkField,cc.xy(4,7));
+
+      cmbValueField.setName("cmbValueField");
+      jpanel1.add(cmbValueField,cc.xy(4,8));
+
+      lblOutputFile.setName("lblOutputFile");
+      lblOutputFile.setText("output_file");
+      jpanel1.add(lblOutputFile,cc.xy(2,9));
+
+      jpanel1.add(createPanel1(),cc.xy(4,9));
+      jpanel1.add(createPanel2(),new CellConstraints(2,12,3,1,CellConstraints.RIGHT,CellConstraints.DEFAULT));
+      addFillComponents(jpanel1,new int[]{ 1,2,3,4,5 },new int[]{ 1,2,3,4,5,6,7,8,9,10,11,12,13 });
+      return jpanel1;
+   }
+
+   public JPanel createPanel1()
+   {
+      JPanel jpanel1 = new JPanel();
+      FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:GROW(1.0),FILL:36PX:NONE","CENTER:DEFAULT:NONE");
+      CellConstraints cc = new CellConstraints();
+      jpanel1.setLayout(formlayout1);
+
+      txtOutputFile.setName("txtOutputFile");
+      txtOutputFile.setHorizontalAlignment(JTextField.LEFT);
+      jpanel1.add(txtOutputFile,cc.xy(1,1));
+
+      btnBrowser.setActionCommand("JButton");
+      btnBrowser.setName("btnBrowser");
+      btnBrowser.setOpaque(false);
+      btnBrowser.setRolloverEnabled(true);
+      btnBrowser.setText("...");
+      jpanel1.add(btnBrowser,cc.xy(2,1));
+
+      addFillComponents(jpanel1,new int[0],new int[0]);
+      return jpanel1;
+   }
+
+   public JPanel createPanel2()
+   {
+      JPanel jpanel1 = new JPanel();
+      FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE","CENTER:DEFAULT:NONE");
+      CellConstraints cc = new CellConstraints();
+      jpanel1.setLayout(formlayout1);
+
+      btnAccept.setActionCommand("_Accept");
+      btnAccept.setName("btnAccept");
+      btnAccept.setText("_Accept");
+      jpanel1.add(btnAccept,cc.xy(1,1));
+
+      btnCancel.setActionCommand("_Cancel");
+      btnCancel.setName("btnCancel");
+      btnCancel.setText("_Cancel");
+      jpanel1.add(btnCancel,cc.xy(3,1));
+
+      addFillComponents(jpanel1,new int[]{ 2 },new int[0]);
+      return jpanel1;
+   }
+
+   /**
+    * Initializer
+    */
+   protected void initializePanel()
+   {
+      setLayout(new BorderLayout());
+      add(createPanel(), BorderLayout.CENTER);
+   }
+
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCalibrateRouteParamsController.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCalibrateRouteParamsController.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCalibrateRouteParamsController.java	(revision 950)
@@ -0,0 +1,562 @@
+/*
+ * Copyright 2015 DiSiD Technologies S.L.L. All rights reserved.
+ *
+ * Project  : DiSiD org.gvsig.lrs.swing.impl
+ * SVN Id   : $Id$
+ */
+package org.gvsig.lrs.swing.impl;
+
+import java.awt.Dimension;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.awt.event.ItemEvent;
+import java.awt.event.ItemListener;
+import java.io.File;
+import java.util.Locale;
+
+import javax.swing.ComboBoxModel;
+import javax.swing.DefaultComboBoxModel;
+import javax.swing.JComponent;
+import javax.swing.JOptionPane;
+import javax.swing.ListCellRenderer;
+
+import org.apache.commons.io.FileUtils;
+import org.apache.commons.lang3.StringUtils;
+import org.cresques.cts.IProjection;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.feature.FeatureType;
+import org.gvsig.fmap.dal.feature.NewFeatureStoreParameters;
+import org.gvsig.fmap.dal.store.shp.SHPNewStoreParameters;
+import org.gvsig.fmap.geom.DataTypes;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.operations.LayerCollection;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.lrs.lib.api.DistanceUnits;
+import org.gvsig.lrs.lib.api.LrsAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsAlgorithmsLocator;
+import org.gvsig.lrs.lib.api.LrsAlgorithmsManager;
+import org.gvsig.lrs.lib.api.LrsCalibrateRouteAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsMeasureCalculationMethods;
+import org.gvsig.lrs.lib.api.exceptions.LrsGettingParametersException;
+import org.gvsig.lrs.lib.api.exceptions.LrsNeededParameterException;
+import org.gvsig.lrs.swing.api.JLrsAlgorithmParams;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.i18n.I18nManager;
+import org.gvsig.tools.swing.api.ActionListenerSupport;
+import org.gvsig.tools.swing.api.ToolsSwingLocator;
+import org.gvsig.tools.swing.api.threadsafedialogs.ThreadSafeDialogsManager;
+
+public class JLrsCalibrateRouteParamsController extends JLrsCalibrateRouteParamsView  implements JLrsAlgorithmParams{
+
+    /**
+     *
+     */
+    private static final long serialVersionUID = -9145489136943076981L;
+
+    private static final Logger logger = LoggerFactory.getLogger(JLrsCalibrateRouteParamsController.class);
+
+    private boolean canceled;
+    private ActionListenerSupport listeners = ToolsSwingLocator.getToolsSwingManager().createActionListenerSupport();
+
+    private LayerCollection layers;
+
+    /**
+     * @param layers
+     * @throws LrsNeededParameterException
+     *
+     */
+    public JLrsCalibrateRouteParamsController(LayerCollection layers, LrsAlgorithmParams params) throws LrsNeededParameterException {
+        super();
+        this.layers = layers;
+        initComponents();
+        translate();
+        setParams(params);
+    }
+
+    public void addActionListener(ActionListener listener) {
+        listeners.addActionListener(listener);
+    }
+
+    public void removeActionListener(ActionListener listener) {
+        listeners.removeActionListener(listener);
+    }
+
+    private void translate() {
+        I18nManager i18nManager = ToolsLocator.getI18nManager();
+
+        lblInputLayer.setText(i18nManager.getTranslation(lblInputLayer.getText()));
+        lblIdRouteField.setText(i18nManager.getTranslation(lblIdRouteField.getText()));
+        lblCalibratePointLayer.setText(i18nManager.getTranslation(lblCalibratePointLayer.getText()));
+        lblCalibrationPointIdRouteField.setText(i18nManager.getTranslation(lblCalibrationPointIdRouteField.getText()));
+        lblMeasureField.setText(i18nManager.getTranslation(lblMeasureField.getText()));
+        lblOutputFile.setText(i18nManager.getTranslation(lblOutputFile.getText()));
+        lblMeasureCalcMethod.setText(i18nManager.getTranslation(lblMeasureCalcMethod.getText()));
+        lblSearchRadius.setText(i18nManager.getTranslation(lblSearchRadius.getText()));
+        chkInterpolateBetweenCalibrationPoints.setText(i18nManager.getTranslation(chkInterpolateBetweenCalibrationPoints.getText()));
+        chkExtrapolateBeforeCalibrationPoints.setText(i18nManager.getTranslation(chkExtrapolateBeforeCalibrationPoints.getText()));
+        chkExtrapolateAfterCalibrationPoints.setText(i18nManager.getTranslation(chkExtrapolateAfterCalibrationPoints.getText()));
+        chkIgnoreSpatialGaps.setText(i18nManager.getTranslation(chkIgnoreSpatialGaps.getText()));
+        chkIncludeAll.setText(i18nManager.getTranslation(chkIncludeAll.getText()));
+        btnBrowser.setText("\u2026");
+        btnAccept.setText(i18nManager.getTranslation(btnAccept.getText()));
+        btnCancel.setText(i18nManager.getTranslation(btnCancel.getText()));
+
+    }
+
+    /**
+     *
+     */
+    public void setLocate(Locale locale) {
+        Locale l = super.getLocale();
+        if (!l.equals(locale)) {
+            translate();
+        }
+        super.setLocale(locale);
+    }
+
+    /**
+     * Validates the layers:
+     *  - At least 2 layers
+     *  - At least 1 curve layer with at least 1 non-geometric field
+     *  - At least 1 point layer with at least 1 non-geometric field and 1 numeric field
+     *  if they are not correct throws an exception
+     * @throws LrsNeededParameterException
+     */
+    public static void validateLayers(LayerCollection layers)throws LrsNeededParameterException {
+        logger.debug("Validating layers for Calibrate Route");
+        if (layers==null||layers.getLayersCount()<2){
+            logger.error("Two or more layers are needed");
+            throw new LrsNeededParameterException("two_or_more_layers_are_needed", null);
+        }
+
+        if (!JLrsUtils.validatedMCurveAndPointLayer(layers)){
+            logger.error("Impossible to find the layers needed");
+            throw new LrsNeededParameterException("impossible_to_find_needed_layers",null);
+        }
+    }
+
+    /**
+     * @throws LrsNeededParameterException
+     */
+    private void initComponents() throws LrsNeededParameterException {
+
+        validateLayers(layers);
+
+        // Modelos de los combos
+        FLayersMComboBoxModel inputLayerModel = new FLayersMComboBoxModel(this.layers);
+        FeatureAttributeDescriptorsComboBoxModel idRouteFieldComboBoxModel =
+            new FeatureAttributeDescriptorsComboBoxModel();
+
+        PointLayersComboBoxModel calibratePointLayerModel = new PointLayersComboBoxModel(this.layers);
+        FeatureAttributeDescriptorsComboBoxModel idCalibrationPointFieldComboBoxModel =
+            new FeatureAttributeDescriptorsComboBoxModel();
+        FeatureAttributeDescriptorsComboBoxModel fromMeasureFieldComboBoxModel =
+            new FeatureAttributeDescriptorsComboBoxModel();
+
+
+        // Renderer para los combos de attributeDescriptors
+        ListCellRenderer featureAttributeDescriptorCellRenderer = new FLayersAttributeDescriptorCellRenderer();
+        // asignación de renderers y modelos
+        cmbIdRouteField.setRenderer(featureAttributeDescriptorCellRenderer);
+        cmbCalibrationPointIdRouteField.setRenderer(featureAttributeDescriptorCellRenderer);
+        cmbMeasureField.setRenderer(featureAttributeDescriptorCellRenderer);
+        cmbIdRouteField.setModel(idRouteFieldComboBoxModel);
+        cmbCalibrationPointIdRouteField.setModel(idCalibrationPointFieldComboBoxModel);
+        cmbMeasureField.setModel(fromMeasureFieldComboBoxModel);
+
+        // renderer para el combo de capas
+        ListCellRenderer layerNameCellRenderer=new FLayersLayerNameCellRenderer();
+        cmbInputLayer.setRenderer(layerNameCellRenderer);
+        cmbCalibratePointLayer.setRenderer(layerNameCellRenderer);
+        // asignación modelo al combo de capas
+        cmbInputLayer.setModel(inputLayerModel);
+        cmbCalibratePointLayer.setModel(calibratePointLayerModel);
+        // listener del combo de capas para que actualice el resto de
+        // componentes
+        cmbInputLayer.addItemListener(new ItemListener() {
+
+            public void itemStateChanged(ItemEvent e) {
+                Object item = e.getItem();
+                if (item instanceof FLyrVect) {
+                    FLyrVect layer = (FLyrVect) item;
+                    updateLayerSource(layer);
+                }
+            }
+        });
+        cmbCalibratePointLayer.addItemListener(new ItemListener() {
+
+            public void itemStateChanged(ItemEvent e) {
+                Object item = e.getItem();
+                if (item instanceof FLyrVect) {
+                    FLyrVect layer = (FLyrVect) item;
+                    updateLayerCalibratePoint(layer);
+                }
+            }
+        });
+
+        ComboBoxModel<LrsMeasureCalculationMethods> measureCalculationMethodsModel =
+            new DefaultComboBoxModel<LrsMeasureCalculationMethods>(LrsMeasureCalculationMethods.values());
+
+        cmbMeasureCalcMethod.setModel(measureCalculationMethodsModel);
+
+        ComboBoxModel<DistanceUnits> measureUnitsModel =
+            new DefaultComboBoxModel<DistanceUnits>(DistanceUnits.values());
+
+        cmbMeasureUnits.setModel(measureUnitsModel);
+        cmbMeasureUnits.setRenderer(new DistanceUnitsCellRenderer());
+
+        this.btnBrowser.addActionListener(new ActionListener() {
+
+            public void actionPerformed(ActionEvent e) {
+                doSelectOuputFile();
+            }
+        });
+
+        this.btnAccept.addActionListener(new ActionListener() {
+
+            public void actionPerformed(ActionEvent e) {
+                canceled = false;
+                doClose();
+                listeners.fireActionEvent(new ActionEvent(JLrsCalibrateRouteParamsController.this, 0, "accept"));
+
+            }
+        });
+
+        this.btnCancel.addActionListener(new ActionListener() {
+
+            public void actionPerformed(ActionEvent e) {
+                canceled = true;
+                doClose();
+                listeners.fireActionEvent(new ActionEvent(JLrsCalibrateRouteParamsController.this, 0, "cancel"));
+            }
+        });
+
+        setVisibleAceptCancel(false);
+        canceled = false;
+    }
+
+    private void doSelectOuputFile() {
+        final I18nManager i18nManager = ToolsLocator.getI18nManager();
+        ThreadSafeDialogsManager manager = ToolsSwingLocator.getThreadSafeDialogsManager();
+        File[] files = manager.showSaveFileDialog(i18nManager.getTranslation("output_file"), null);
+        if (files != null && files.length > 0) {
+            File file = files[0];
+            String absolutePath = file.getAbsolutePath();
+            if(!StringUtils.endsWithIgnoreCase(absolutePath, ".shp")){
+                absolutePath = new StringBuilder().append(absolutePath).append(".shp").toString();
+            }
+            File outputFile = FileUtils.getFile(absolutePath);
+            if(outputFile.exists()) {
+                int resp = JOptionPane.showOptionDialog(
+                    this.asJComponent(),
+                    i18nManager.getTranslation("file_already_exists_do_you_want_overwrite_it"),
+                    i18nManager.getTranslation("output_file"),
+                    JOptionPane.OK_CANCEL_OPTION,
+                    JOptionPane.QUESTION_MESSAGE,
+                    null,
+                    null,
+                    JOptionPane.OK_OPTION);
+                if (resp == JOptionPane.OK_OPTION){
+                    this.txtOutputFile.setText(absolutePath);
+                } else {
+                    doSelectOuputFile();
+                }
+            } else {
+                this.txtOutputFile.setText(absolutePath);
+            }
+        }
+
+    }
+
+    private void doClose() {
+        this.setVisible(false);
+    }
+
+    public boolean isCanceled() {
+        return this.canceled;
+    }
+
+    public void setVisibleAceptCancel(boolean visible) {
+        this.btnAccept.setVisible(visible);
+        this.btnCancel.setVisible(visible);
+    }
+
+    public boolean getVisibleAceptCancel() {
+        return this.btnAccept.isVisible();
+    }
+
+    public JComponent asJComponent() {
+        return this;
+    }
+
+    public LrsAlgorithmParams getParams() throws LrsGettingParametersException, LrsNeededParameterException {
+        LrsAlgorithmsManager manager = LrsAlgorithmsLocator.getLrsAlgorithmsManager();
+        LrsCalibrateRouteAlgorithmParams params = manager.createLrsCalibrateRouteAlgorithmParams();
+        // Recorrer todo del interfaz y rellenar los parametros
+
+        //cmbInputLayer
+        if (!(this.cmbInputLayer.getSelectedItem() instanceof FLyrVect)){
+            logger.error("Error getting selected item from cmbInputLayer");
+            throw new LrsGettingParametersException("error_getting_selected_item_from_cmbInputLayer", null);
+        }
+        FLyrVect fLyrVect = (FLyrVect) this.cmbInputLayer.getSelectedItem();
+        IProjection projection= fLyrVect.getProjection();
+        if (!(fLyrVect.getFeatureStore() instanceof FeatureStore)){
+            logger.error("Error getting selected item from cmbInputLayer");
+            throw new LrsGettingParametersException("error_getting_selected_item_from_cmbInputLayer", null);
+        }
+        FeatureStore sourceFeatureStore = (FeatureStore)fLyrVect.getFeatureStore();
+        if (sourceFeatureStore == null) {
+            throw new LrsNeededParameterException("need_to_select_a_source_layer", null);
+        }
+        params.setSourceFeatureStore(sourceFeatureStore);
+
+        //cmbIdRouteField
+        if (!(this.cmbIdRouteField.getSelectedItem() instanceof FeatureAttributeDescriptor)){
+            logger.error("Error getting selected item from cmbIdRouteField");
+            throw new LrsGettingParametersException("error_getting_selected_item_from_cmbIdRouteField", null);
+        }
+        FeatureAttributeDescriptor idRouteField = (FeatureAttributeDescriptor) this.cmbIdRouteField.getSelectedItem();
+        if (idRouteField == null) {
+            throw new LrsNeededParameterException("need_to_select_a_route_identifier_field", null);
+        }
+        params.setIdRouteField(idRouteField);
+
+      //cmbCalibratePointLayer
+        if (!(this.cmbCalibratePointLayer.getSelectedItem() instanceof FLyrVect)){
+            logger.error("Error getting selected item from cmbCalibratePointLayer");
+            throw new LrsGettingParametersException("error_getting_selected_item_from_cmbCalibratePointLayer", null);
+        }
+        FLyrVect fLyrVectCalibratePoint = (FLyrVect) this.cmbCalibratePointLayer.getSelectedItem();
+        if (!(fLyrVectCalibratePoint.getFeatureStore() instanceof FeatureStore)){
+            logger.error("Error getting selected item from cmbCalibratePointLayer");
+            throw new LrsGettingParametersException("error_getting_selected_item_from_cmbCalibratePointLayer", null);
+        }
+        FeatureStore calibratePointFeatureStore = (FeatureStore)fLyrVectCalibratePoint.getFeatureStore();
+        if (calibratePointFeatureStore == null) {
+            throw new LrsNeededParameterException("need_to_select_a_calibrate_point_layer", null);
+        }
+        params.setCalibratePointFeatureStore(calibratePointFeatureStore);
+
+        //cmbCalibrationPointIdRouteField
+        if (!(this.cmbCalibrationPointIdRouteField.getSelectedItem() instanceof FeatureAttributeDescriptor)){
+            logger.error("Error getting selected item from cmbCalibrationPointIdRouteField");
+            throw new LrsGettingParametersException("error_getting_selected_item_from_cmbCalibrationPointIdRouteField", null);
+        }
+        FeatureAttributeDescriptor idRouteFieldCalibratePoint =
+            (FeatureAttributeDescriptor) this.cmbCalibrationPointIdRouteField.getSelectedItem();
+        if (idRouteFieldCalibratePoint == null) {
+            throw new LrsNeededParameterException("need_to_select_a_route_identifier_calibration_point_field", null);
+        }
+        params.setCalibratePointIdRouteField(idRouteFieldCalibratePoint);
+
+        //cmbFromMeasureField
+        if (!(this.cmbMeasureField.getSelectedItem() instanceof FeatureAttributeDescriptor)){
+            logger.error("Error getting selected item from cmbFromMeasureField");
+            throw new LrsGettingParametersException("error_getting_selected_item_from_cmbFromMeasureField", null);
+        }
+        FeatureAttributeDescriptor fromMeasureField =
+            (FeatureAttributeDescriptor) this.cmbMeasureField.getSelectedItem();
+        if (fromMeasureField == null) {
+            throw new LrsNeededParameterException("need_to_select_a_from_Measure_field", null);
+        }
+        params.setFromMeasureField(fromMeasureField);
+
+        //OutputStore
+        String outputLayerPathFile = this.txtOutputFile.getText();
+        if(StringUtils.isEmpty(outputLayerPathFile)){
+            throw new LrsNeededParameterException("need_to_fill_the_target_path", null);
+        }
+        try {
+            NewFeatureStoreParameters newFeatureStoreParams=JLrsUtils.createFeatureStoreParams(outputLayerPathFile, projection);
+            params.setNewFeatureStoreParameters(newFeatureStoreParams);
+        } catch (Exception e) {
+            throw new LrsNeededParameterException("error_creating_outputStore", e);
+        }
+
+
+        LrsMeasureCalculationMethods measureCalculationMethods = (LrsMeasureCalculationMethods) this.cmbMeasureCalcMethod.getSelectedItem();
+        params.setMeasureCalculationMethods(measureCalculationMethods);
+        DistanceUnits measureUnits = (DistanceUnits) this.cmbMeasureUnits.getSelectedItem();
+        params.setMeasureUnits(measureUnits);
+
+        String searchRadius = this.txtSearchRadius.getText();
+        if (searchRadius!=null && !searchRadius.isEmpty()){
+            try{
+                params.setSearchRadius(Double.valueOf(searchRadius));
+            }catch (Exception e){
+                params.setSearchRadius(Double.valueOf(0));
+            }
+        }else {
+            params.setSearchRadius(0);
+        }
+
+        params.setInterpolateBetweenCalibrationPoints(this.chkInterpolateBetweenCalibrationPoints.isSelected());
+        params.setExtrapolateBeforeCalibrationPoints(this.chkExtrapolateBeforeCalibrationPoints.isSelected());
+        params.setExtrapolateAfterCalibrationPoints(this.chkExtrapolateAfterCalibrationPoints.isSelected());
+        params.setIgnoreSpatialGaps(this.chkIgnoreSpatialGaps.isSelected());
+        params.setIncludeAll(this.chkIncludeAll.isSelected());
+
+        return params;
+    }
+
+    public void setParams(LrsAlgorithmParams params) {
+        if (params == null) {
+            clear();
+            return;
+        }
+        // Rellena los campos con los valores de params
+        LrsCalibrateRouteAlgorithmParams parameters = (LrsCalibrateRouteAlgorithmParams) params;
+
+        this.cmbMeasureCalcMethod.setSelectedItem(parameters.getMeasureCalculationMethods());
+        this.cmbMeasureUnits.setSelectedItem(parameters.getMeasureUnits());
+
+        FeatureStore sourceFeatureStore = parameters.getSourceFeatureStore();
+        if(layers!=null && sourceFeatureStore!=null){
+            FLayer layer = layers.getLayer(sourceFeatureStore.getName());
+            this.cmbInputLayer.setSelectedItem(layer);
+        }
+        FeatureStore calibratePointFeaturesStore=parameters.getCalibratePointFeatureStore();
+        if(layers!=null && calibratePointFeaturesStore!=null){
+            FLayer layer = layers.getLayer(calibratePointFeaturesStore.getName());
+            this.cmbCalibratePointLayer.setSelectedItem(layer);
+        }
+        NewFeatureStoreParameters newFeatureStoreParameters = parameters.getNewFeatureStoreParameters();
+        if(newFeatureStoreParameters!=null && newFeatureStoreParameters instanceof SHPNewStoreParameters){
+            this.txtOutputFile.setText(((SHPNewStoreParameters)newFeatureStoreParameters).getSHPFile().getAbsolutePath());
+        }
+
+        this.cmbIdRouteField.setSelectedItem(parameters.getIdRouteField());
+        this.cmbCalibrationPointIdRouteField.setSelectedItem(parameters.getCalibratePointIdRouteField());
+        this.cmbMeasureField.setSelectedItem(parameters.getFromMeasureField());
+
+        this.txtSearchRadius.setText(String.valueOf(parameters.getSearchRadius()));
+        this.chkInterpolateBetweenCalibrationPoints.setSelected(parameters.interpolateBetweenCalibrationPoints());
+        this.chkExtrapolateBeforeCalibrationPoints.setSelected(parameters.extrapolateBeforeCalibrationPoints());
+        this.chkExtrapolateAfterCalibrationPoints.setSelected(parameters.extrapolateAfterCalibrationPoints());
+        this.chkIgnoreSpatialGaps.setSelected(parameters.ignoreSpatialGaps());
+        this.chkIncludeAll.setSelected(parameters.includeAll());
+
+    }
+
+    public void clear() {
+        this.txtOutputFile.setText("");
+        this.txtSearchRadius.setText("0.0");
+
+        this.cmbInputLayer.setSelectedIndex(0);
+        Object inputLayerSelected = this.cmbInputLayer.getSelectedItem();
+        if (inputLayerSelected != null) {
+            this.updateLayerSource((FLyrVect) inputLayerSelected);
+        }
+        this.cmbCalibratePointLayer.setSelectedIndex(0);
+        Object calibratePointLayerSelected = this.cmbCalibratePointLayer.getSelectedItem();
+        if (calibratePointLayerSelected != null) {
+            this.updateLayerCalibratePoint((FLyrVect) calibratePointLayerSelected);
+        }
+        this.cmbIdRouteField.setSelectedIndex(0);
+        this.cmbCalibrationPointIdRouteField.setSelectedIndex(0);
+        this.cmbMeasureField.setSelectedIndex(0);
+        this.cmbMeasureCalcMethod.setSelectedIndex(0);
+        this.cmbMeasureUnits.setSelectedIndex(0);
+        this.chkInterpolateBetweenCalibrationPoints.setSelected(false);
+        this.chkExtrapolateBeforeCalibrationPoints.setSelected(false);
+        this.chkExtrapolateAfterCalibrationPoints.setSelected(false);
+        this.chkIgnoreSpatialGaps.setSelected(false);
+        this.chkIncludeAll.setSelected(false);
+
+    }
+
+    private void updateLayerSource(FLyrVect layer) {
+        logger.info(new StringBuilder().append("Setting layer ").append(layer.getName()).toString());
+        FeatureStore featureStore = layer.getFeatureStore();
+        try {
+            FeatureType type = featureStore.getDefaultFeatureType();
+            // Se renuevan los combos de attributeDescriptors
+            FeatureAttributeDescriptorsComboBoxModel idRouteFieldComboBoxModel =
+                new FeatureAttributeDescriptorsComboBoxModel();
+
+            this.cmbIdRouteField.setModel(idRouteFieldComboBoxModel);
+
+            FeatureAttributeDescriptor[] attributeDescriptors = type.getAttributeDescriptors();
+            for (int i = 0; i < attributeDescriptors.length; i++) {
+                FeatureAttributeDescriptor featureAttributeDescriptor = attributeDescriptors[i];
+                if (featureAttributeDescriptor.getDataType().getType() != DataTypes.GEOMETRY) {
+                    logger.info(new StringBuilder().append("Adding field ")
+                        .append(featureAttributeDescriptor.getName()).toString());
+
+                    JLrsCalibrateRouteParamsController.this.cmbIdRouteField.addItem(featureAttributeDescriptor);
+                }
+            }
+            this.cmbIdRouteField.invalidate();
+            this.cmbIdRouteField.setSelectedIndex(0);
+
+        } catch (DataException e1) {
+            logger.warn(
+                new StringBuilder().append("Error getting default feature type from layer ").append(layer.getName())
+                    .toString(), e1);
+        }
+    }
+
+
+
+    private void updateLayerCalibratePoint(FLyrVect layer) {
+        logger.info(new StringBuilder().append("Setting layer ").append(layer.getName()).toString());
+        FeatureStore featureStore = layer.getFeatureStore();
+        try {
+            FeatureType type = featureStore.getDefaultFeatureType();
+            // Se renuevan los combos de attributeDescriptors
+            FeatureAttributeDescriptorsComboBoxModel calibrationPointIdRouteFieldComboBoxModel =
+                new FeatureAttributeDescriptorsComboBoxModel();
+            FeatureAttributeDescriptorsComboBoxModel measureFieldComboBoxModel =
+                new FeatureAttributeDescriptorsComboBoxModel();
+
+            this.cmbCalibrationPointIdRouteField.setModel(calibrationPointIdRouteFieldComboBoxModel);
+            this.cmbMeasureField.setModel(measureFieldComboBoxModel);
+
+            FeatureAttributeDescriptor[] attributeDescriptors = type.getAttributeDescriptors();
+            for (int i = 0; i < attributeDescriptors.length; i++) {
+                FeatureAttributeDescriptor featureAttributeDescriptor = attributeDescriptors[i];
+                if (featureAttributeDescriptor.getDataType().getType() != DataTypes.GEOMETRY) {
+                    logger.info(new StringBuilder().append("Adding field ")
+                        .append(featureAttributeDescriptor.getName()).toString());
+
+                    //calibrationPointIdRouteFieldComboBoxModel.addElement(featureAttributeDescriptor);
+                    this.cmbCalibrationPointIdRouteField.addItem(featureAttributeDescriptor);
+                    if (featureAttributeDescriptor.getDataType().isNumeric()) {
+                        //measureFieldComboBoxModel.addElement(featureAttributeDescriptor);
+                        this.cmbMeasureField.addItem(featureAttributeDescriptor);
+                    }
+                }
+            }
+
+            this.cmbCalibrationPointIdRouteField.setSelectedIndex(0);
+            this.cmbMeasureField.setSelectedIndex(0);
+//            calibrationPointIdRouteFieldComboBoxModel.setSelectedItem(calibrationPointIdRouteFieldComboBoxModel.getElementAt(0));
+//            measureFieldComboBoxModel.setSelectedItem(measureFieldComboBoxModel.getElementAt(0));
+
+            this.cmbCalibrationPointIdRouteField.invalidate();
+            this.cmbMeasureField.invalidate();
+
+        } catch (DataException e1) {
+            logger.warn(
+                new StringBuilder().append("Error getting default feature type from layer ").append(layer.getName())
+                    .toString(), e1);
+        }
+    }
+
+    /* (non-Javadoc)
+     * @see javax.swing.JComponent#getPreferredSize()
+     */
+    @Override
+    public Dimension getPreferredSize() {
+        return new Dimension(650, 350);
+    }
+
+
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsEditRouteCalibrationSelectIdRouteView.xml
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsEditRouteCalibrationSelectIdRouteView.xml	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsEditRouteCalibrationSelectIdRouteView.xml	(revision 950)
@@ -0,0 +1,460 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<object classname="com.jeta.forms.store.memento.FormPackage">
+ <at name="fileversion">
+  <object classname="com.jeta.forms.store.memento.FormsVersion2">
+   <at name="major">2</at>
+   <at name="minor">0</at>
+   <at name="sub">0</at>
+  </object>
+ </at>
+ <at name="form">
+  <object classname="com.jeta.forms.store.memento.FormMemento">
+   <super classname="com.jeta.forms.store.memento.ComponentMemento">
+    <at name="cellconstraints">
+     <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+      <at name="column">1</at>
+      <at name="row">1</at>
+      <at name="colspan">1</at>
+      <at name="rowspan">1</at>
+      <at name="halign">default</at>
+      <at name="valign">default</at>
+      <at name="insets" object="insets">0,0,0,0</at>
+     </object>
+    </at>
+    <at name="componentclass">com.jeta.forms.gui.form.FormComponent</at>
+   </super>
+   <at name="id">/home/daniel/tmp/abeille/JLrsEditRouteCalibrationSelectIdRouteView.xml</at>
+   <at name="rowspecs">CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:GROW(1.0),CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE</at>
+   <at name="colspecs">FILL:DEFAULT:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:334PX:GROW(1.0),FILL:DEFAULT:NONE</at>
+   <at name="components">
+    <object classname="java.util.LinkedList">
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">2</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">id_route_field</at>
+            <at name="height">14</at>
+            <at name="width">76</at>
+            <at name="name">lblIdRouteField</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">2</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JComboBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JComboBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="height">20</at>
+            <at name="items">
+             <object classname="com.jeta.forms.store.properties.ItemsProperty">
+              <at name="name">items</at>
+             </object>
+            </at>
+            <at name="width">827</at>
+            <at name="name">cmbIdRouteField</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.FormMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">4</at>
+           <at name="colspan">3</at>
+           <at name="rowspan">1</at>
+           <at name="halign">right</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.FormComponent</at>
+        </super>
+        <at name="id">embedded.1550168189</at>
+        <at name="rowspecs">CENTER:DEFAULT:NONE</at>
+        <at name="colspecs">FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE</at>
+        <at name="components">
+         <object classname="java.util.LinkedList">
+          <item >
+           <at name="value">
+            <object classname="com.jeta.forms.store.memento.BeanMemento">
+             <super classname="com.jeta.forms.store.memento.ComponentMemento">
+              <at name="cellconstraints">
+               <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+                <at name="column">1</at>
+                <at name="row">1</at>
+                <at name="colspan">1</at>
+                <at name="rowspan">1</at>
+                <at name="halign">default</at>
+                <at name="valign">default</at>
+                <at name="insets" object="insets">0,0,0,0</at>
+               </object>
+              </at>
+              <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+             </super>
+             <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+             <at name="beanclass">javax.swing.JButton</at>
+             <at name="beanproperties">
+              <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+               <at name="classname">javax.swing.JButton</at>
+               <at name="properties">
+                <object classname="com.jeta.forms.store.support.PropertyMap">
+                 <at name="text">_Accept</at>
+                 <at name="height">22</at>
+                 <at name="width">75</at>
+                 <at name="name">btnAccept</at>
+                 <at name="actionCommand">_Accept</at>
+                 <at name="border">
+                  <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                   <at name="borders">
+                    <object classname="java.util.LinkedList">
+                     <item >
+                      <at name="value">
+                       <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                        <super classname="com.jeta.forms.store.properties.BorderProperty">
+                         <at name="name">border</at>
+                        </super>
+                       </object>
+                      </at>
+                     </item>
+                    </object>
+                   </at>
+                  </object>
+                 </at>
+                </object>
+               </at>
+              </object>
+             </at>
+            </object>
+           </at>
+          </item>
+          <item >
+           <at name="value">
+            <object classname="com.jeta.forms.store.memento.BeanMemento">
+             <super classname="com.jeta.forms.store.memento.ComponentMemento">
+              <at name="cellconstraints">
+               <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+                <at name="column">3</at>
+                <at name="row">1</at>
+                <at name="colspan">1</at>
+                <at name="rowspan">1</at>
+                <at name="halign">default</at>
+                <at name="valign">default</at>
+                <at name="insets" object="insets">0,0,0,0</at>
+               </object>
+              </at>
+              <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+             </super>
+             <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+             <at name="beanclass">javax.swing.JButton</at>
+             <at name="beanproperties">
+              <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+               <at name="classname">javax.swing.JButton</at>
+               <at name="properties">
+                <object classname="com.jeta.forms.store.support.PropertyMap">
+                 <at name="text">_Cancel</at>
+                 <at name="height">22</at>
+                 <at name="width">76</at>
+                 <at name="name">btnCancel</at>
+                 <at name="actionCommand">_Cancel</at>
+                 <at name="border">
+                  <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                   <at name="borders">
+                    <object classname="java.util.LinkedList">
+                     <item >
+                      <at name="value">
+                       <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                        <super classname="com.jeta.forms.store.properties.BorderProperty">
+                         <at name="name">border</at>
+                        </super>
+                       </object>
+                      </at>
+                     </item>
+                    </object>
+                   </at>
+                  </object>
+                 </at>
+                </object>
+               </at>
+              </object>
+             </at>
+            </object>
+           </at>
+          </item>
+         </object>
+        </at>
+        <at name="properties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.gui.form.GridView</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="name"></at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="scollBars">
+             <object classname="com.jeta.forms.store.properties.ScrollBarsProperty">
+              <at name="name">scollBars</at>
+              <at name="verticalpolicy">21</at>
+              <at name="horizontalpolicy">31</at>
+              <at name="border">
+               <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                <super classname="com.jeta.forms.store.properties.BorderProperty">
+                 <at name="name">border</at>
+                </super>
+                <at name="borders">
+                 <object classname="java.util.LinkedList">
+                  <item >
+                   <at name="value">
+                    <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                     <super classname="com.jeta.forms.store.properties.BorderProperty">
+                      <at name="name">border</at>
+                     </super>
+                    </object>
+                   </at>
+                  </item>
+                 </object>
+                </at>
+               </object>
+              </at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList"/>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+        <at name="cellpainters">
+         <object classname="com.jeta.forms.store.support.Matrix">
+          <at name="rows">
+           <object classname="[Ljava.lang.Object;" size="1">
+            <at name="item" index="0">
+             <object classname="[Ljava.lang.Object;" size="3"/>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+        <at name="rowgroups">
+         <object classname="com.jeta.forms.store.memento.FormGroupSet">
+          <at name="groups">
+           <object classname="java.util.HashMap"/>
+          </at>
+         </object>
+        </at>
+        <at name="colgroups">
+         <object classname="com.jeta.forms.store.memento.FormGroupSet">
+          <at name="groups">
+           <object classname="java.util.HashMap"/>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+    </object>
+   </at>
+   <at name="properties">
+    <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+     <at name="classname">com.jeta.forms.gui.form.GridView</at>
+     <at name="properties">
+      <object classname="com.jeta.forms.store.support.PropertyMap">
+       <at name="name"></at>
+       <at name="fill">
+        <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+         <at name="name">fill</at>
+        </object>
+       </at>
+       <at name="scollBars">
+        <object classname="com.jeta.forms.store.properties.ScrollBarsProperty">
+         <at name="name">scollBars</at>
+         <at name="verticalpolicy">21</at>
+         <at name="horizontalpolicy">31</at>
+         <at name="border">
+          <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+           <super classname="com.jeta.forms.store.properties.BorderProperty">
+            <at name="name">border</at>
+           </super>
+           <at name="borders">
+            <object classname="java.util.LinkedList">
+             <item >
+              <at name="value">
+               <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                <super classname="com.jeta.forms.store.properties.BorderProperty">
+                 <at name="name">border</at>
+                </super>
+               </object>
+              </at>
+             </item>
+            </object>
+           </at>
+          </object>
+         </at>
+        </object>
+       </at>
+       <at name="border">
+        <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+         <super classname="com.jeta.forms.store.properties.BorderProperty">
+          <at name="name">border</at>
+         </super>
+         <at name="borders">
+          <object classname="java.util.LinkedList"/>
+         </at>
+        </object>
+       </at>
+      </object>
+     </at>
+    </object>
+   </at>
+   <at name="cellpainters">
+    <object classname="com.jeta.forms.store.support.Matrix">
+     <at name="rows">
+      <object classname="[Ljava.lang.Object;" size="5">
+       <at name="item" index="0">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="1">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="2">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="3">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+       <at name="item" index="4">
+        <object classname="[Ljava.lang.Object;" size="5"/>
+       </at>
+      </object>
+     </at>
+    </object>
+   </at>
+   <at name="rowgroups">
+    <object classname="com.jeta.forms.store.memento.FormGroupSet">
+     <at name="groups">
+      <object classname="java.util.HashMap"/>
+     </at>
+    </object>
+   </at>
+   <at name="colgroups">
+    <object classname="com.jeta.forms.store.memento.FormGroupSet">
+     <at name="groups">
+      <object classname="java.util.HashMap"/>
+     </at>
+    </object>
+   </at>
+  </object>
+ </at>
+</object>
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCalibrateRouteParamsView.xml
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCalibrateRouteParamsView.xml	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCalibrateRouteParamsView.xml	(revision 950)
@@ -0,0 +1,1925 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<object classname="com.jeta.forms.store.memento.FormPackage">
+ <at name="fileversion">
+  <object classname="com.jeta.forms.store.memento.FormsVersion2">
+   <at name="major">2</at>
+   <at name="minor">0</at>
+   <at name="sub">0</at>
+  </object>
+ </at>
+ <at name="form">
+  <object classname="com.jeta.forms.store.memento.FormMemento">
+   <super classname="com.jeta.forms.store.memento.ComponentMemento">
+    <at name="cellconstraints">
+     <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+      <at name="column">1</at>
+      <at name="row">1</at>
+      <at name="colspan">1</at>
+      <at name="rowspan">1</at>
+      <at name="halign">default</at>
+      <at name="valign">default</at>
+      <at name="insets" object="insets">0,0,0,0</at>
+     </object>
+    </at>
+    <at name="componentclass">com.jeta.forms.gui.form.FormComponent</at>
+   </super>
+   <at name="id">/home/paco/projects/externals/gvsig-desktop/gvSIG_v2.1/org.gvsig.lrs/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsCalibrateRouteParamsView.xml</at>
+   <at name="rowspecs">CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:GROW(1.0),BOTTOM:DEFAULT:NONE,CENTER:DEFAULT:NONE</at>
+   <at name="colspecs">FILL:DEFAULT:NONE,FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:GROW(1.0),FILL:DEFAULT:NONE,FILL:DEFAULT:NONE</at>
+   <at name="components">
+    <object classname="java.util.LinkedList">
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">2</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">source</at>
+            <at name="height">14</at>
+            <at name="width">175</at>
+            <at name="name">lblInputLayer</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">2</at>
+           <at name="colspan">2</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JComboBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JComboBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="height">20</at>
+            <at name="items">
+             <object classname="com.jeta.forms.store.properties.ItemsProperty">
+              <at name="name">items</at>
+             </object>
+            </at>
+            <at name="width">728</at>
+            <at name="name">cmbInputLayer</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">3</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">id_route_field</at>
+            <at name="height">14</at>
+            <at name="width">175</at>
+            <at name="name">lblIdRouteField</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">3</at>
+           <at name="colspan">2</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JComboBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JComboBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="height">20</at>
+            <at name="items">
+             <object classname="com.jeta.forms.store.properties.ItemsProperty">
+              <at name="name">items</at>
+             </object>
+            </at>
+            <at name="width">728</at>
+            <at name="name">cmbIdRouteField</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">6</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">measures_field</at>
+            <at name="height">14</at>
+            <at name="width">175</at>
+            <at name="name">lblMeasureField</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">6</at>
+           <at name="colspan">2</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JComboBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JComboBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="height">20</at>
+            <at name="items">
+             <object classname="com.jeta.forms.store.properties.ItemsProperty">
+              <at name="name">items</at>
+             </object>
+            </at>
+            <at name="width">728</at>
+            <at name="name">cmbMeasureField</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">7</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">output_file</at>
+            <at name="height">14</at>
+            <at name="width">175</at>
+            <at name="name">lblOutputFile</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">4</at>
+           <at name="colspan">2</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JComboBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JComboBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="height">20</at>
+            <at name="items">
+             <object classname="com.jeta.forms.store.properties.ItemsProperty">
+              <at name="name">items</at>
+             </object>
+            </at>
+            <at name="width">728</at>
+            <at name="name">cmbCalibratePointLayer</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">4</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">calibrate_point_layer</at>
+            <at name="height">14</at>
+            <at name="width">175</at>
+            <at name="name">lblCalibratePointLayer</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">5</at>
+           <at name="colspan">2</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JComboBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JComboBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="height">20</at>
+            <at name="items">
+             <object classname="com.jeta.forms.store.properties.ItemsProperty">
+              <at name="name">items</at>
+             </object>
+            </at>
+            <at name="width">728</at>
+            <at name="name">cmbCalibrationPointIdRouteField</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">5</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">id_calibration_point_route_field</at>
+            <at name="height">14</at>
+            <at name="width">175</at>
+            <at name="name">lblCalibrationPointIdRouteField</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">8</at>
+           <at name="colspan">2</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JComboBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JComboBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="height">20</at>
+            <at name="items">
+             <object classname="com.jeta.forms.store.properties.ItemsProperty">
+              <at name="name">items</at>
+             </object>
+            </at>
+            <at name="width">728</at>
+            <at name="name">cmbMeasureCalcMethod</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">8</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">measure_calc_method</at>
+            <at name="height">14</at>
+            <at name="width">175</at>
+            <at name="name">lblMeasureCalcMethod</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">10</at>
+           <at name="colspan">4</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JCheckBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JCheckBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">interpolate_between_calibration_points</at>
+            <at name="height">16</at>
+            <at name="width">914</at>
+            <at name="name">chkInterpolateBetweenCalibrationPoints</at>
+            <at name="actionCommand">JCBIgnoreSpatialGaps</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">11</at>
+           <at name="colspan">4</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JCheckBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JCheckBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">extrapolate_before_calibration_points</at>
+            <at name="height">16</at>
+            <at name="width">914</at>
+            <at name="name">chkExtrapolateBeforeCalibrationPoints</at>
+            <at name="actionCommand">JCBIgnoreSpatialGaps</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">12</at>
+           <at name="colspan">4</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JCheckBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JCheckBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">extrapolate_after_calibration_points</at>
+            <at name="height">16</at>
+            <at name="width">914</at>
+            <at name="name">chkExtrapolateAfterCalibrationPoints</at>
+            <at name="actionCommand">JCBIgnoreSpatialGaps</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">13</at>
+           <at name="colspan">4</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JCheckBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JCheckBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">ignore_spatial_gaps</at>
+            <at name="height">16</at>
+            <at name="width">914</at>
+            <at name="name">chkIgnoreSpatialGaps</at>
+            <at name="actionCommand">JCBIgnoreSpatialGaps</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">14</at>
+           <at name="colspan">4</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">javax.swing.JCheckBox</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">javax.swing.JCheckBox</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">include_all</at>
+            <at name="height">16</at>
+            <at name="width">914</at>
+            <at name="name">chkIncludeAll</at>
+            <at name="actionCommand">JCBIgnoreSpatialGaps</at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.BeanMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">9</at>
+           <at name="colspan">1</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+        </super>
+        <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+        <at name="beanclass">com.jeta.forms.components.label.JETALabel</at>
+        <at name="beanproperties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.components.label.JETALabel</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="text">search_radius</at>
+            <at name="height">14</at>
+            <at name="width">175</at>
+            <at name="name">lblSearchRadius</at>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList">
+                <item >
+                 <at name="value">
+                  <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                  </object>
+                 </at>
+                </item>
+               </object>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.FormMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">7</at>
+           <at name="colspan">2</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.FormComponent</at>
+        </super>
+        <at name="id">embedded.475704330</at>
+        <at name="rowspecs">CENTER:DEFAULT:NONE</at>
+        <at name="colspecs">FILL:DEFAULT:GROW(1.0),FILL:36PX:NONE</at>
+        <at name="components">
+         <object classname="java.util.LinkedList">
+          <item >
+           <at name="value">
+            <object classname="com.jeta.forms.store.memento.BeanMemento">
+             <super classname="com.jeta.forms.store.memento.ComponentMemento">
+              <at name="cellconstraints">
+               <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+                <at name="column">1</at>
+                <at name="row">1</at>
+                <at name="colspan">1</at>
+                <at name="rowspan">1</at>
+                <at name="halign">default</at>
+                <at name="valign">default</at>
+                <at name="insets" object="insets">0,0,0,0</at>
+               </object>
+              </at>
+              <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+             </super>
+             <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+             <at name="beanclass">javax.swing.JTextField</at>
+             <at name="beanproperties">
+              <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+               <at name="classname">javax.swing.JTextField</at>
+               <at name="properties">
+                <object classname="com.jeta.forms.store.support.PropertyMap">
+                 <at name="horizontalAlignment">2</at>
+                 <at name="height">20</at>
+                 <at name="width">687</at>
+                 <at name="name">txtOutputFile</at>
+                 <at name="border">
+                  <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                   <at name="borders">
+                    <object classname="java.util.LinkedList">
+                     <item >
+                      <at name="value">
+                       <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                        <super classname="com.jeta.forms.store.properties.BorderProperty">
+                         <at name="name">border</at>
+                        </super>
+                       </object>
+                      </at>
+                     </item>
+                    </object>
+                   </at>
+                  </object>
+                 </at>
+                </object>
+               </at>
+              </object>
+             </at>
+            </object>
+           </at>
+          </item>
+          <item >
+           <at name="value">
+            <object classname="com.jeta.forms.store.memento.BeanMemento">
+             <super classname="com.jeta.forms.store.memento.ComponentMemento">
+              <at name="cellconstraints">
+               <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+                <at name="column">2</at>
+                <at name="row">1</at>
+                <at name="colspan">1</at>
+                <at name="rowspan">1</at>
+                <at name="halign">default</at>
+                <at name="valign">default</at>
+                <at name="insets" object="insets">0,0,0,0</at>
+               </object>
+              </at>
+              <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+             </super>
+             <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+             <at name="beanclass">javax.swing.JButton</at>
+             <at name="beanproperties">
+              <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+               <at name="classname">javax.swing.JButton</at>
+               <at name="properties">
+                <object classname="com.jeta.forms.store.support.PropertyMap">
+                 <at name="text">...</at>
+                 <at name="height">22</at>
+                 <at name="opaque">false</at>
+                 <at name="width">32</at>
+                 <at name="name">btnBrowser</at>
+                 <at name="actionCommand">JButton</at>
+                 <at name="border">
+                  <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                   <at name="borders">
+                    <object classname="java.util.LinkedList">
+                     <item >
+                      <at name="value">
+                       <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                        <super classname="com.jeta.forms.store.properties.BorderProperty">
+                         <at name="name">border</at>
+                        </super>
+                       </object>
+                      </at>
+                     </item>
+                    </object>
+                   </at>
+                  </object>
+                 </at>
+                 <at name="rolloverEnabled">true</at>
+                </object>
+               </at>
+              </object>
+             </at>
+            </object>
+           </at>
+          </item>
+         </object>
+        </at>
+        <at name="properties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.gui.form.GridView</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="name"/>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="scollBars">
+             <object classname="com.jeta.forms.store.properties.ScrollBarsProperty">
+              <at name="name">scollBars</at>
+              <at name="verticalpolicy">21</at>
+              <at name="horizontalpolicy">31</at>
+              <at name="border">
+               <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                <super classname="com.jeta.forms.store.properties.BorderProperty">
+                 <at name="name">border</at>
+                </super>
+                <at name="borders">
+                 <object classname="java.util.LinkedList">
+                  <item >
+                   <at name="value">
+                    <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                     <super classname="com.jeta.forms.store.properties.BorderProperty">
+                      <at name="name">border</at>
+                     </super>
+                    </object>
+                   </at>
+                  </item>
+                 </object>
+                </at>
+               </object>
+              </at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList"/>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+        <at name="cellpainters">
+         <object classname="com.jeta.forms.store.support.Matrix">
+          <at name="rows">
+           <object classname="[Ljava.lang.Object;" size="1">
+            <at name="item" index="0">
+             <object classname="[Ljava.lang.Object;" size="2"/>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+        <at name="rowgroups">
+         <object classname="com.jeta.forms.store.memento.FormGroupSet">
+          <at name="groups">
+           <object classname="java.util.HashMap"/>
+          </at>
+         </object>
+        </at>
+        <at name="colgroups">
+         <object classname="com.jeta.forms.store.memento.FormGroupSet">
+          <at name="groups">
+           <object classname="java.util.HashMap"/>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.FormMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">4</at>
+           <at name="row">9</at>
+           <at name="colspan">2</at>
+           <at name="rowspan">1</at>
+           <at name="halign">default</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.FormComponent</at>
+        </super>
+        <at name="id">embedded.148398888</at>
+        <at name="rowspecs">CENTER:DEFAULT:NONE</at>
+        <at name="colspecs">FILL:20DLU:GROW(1.0),FILL:DEFAULT:NONE</at>
+        <at name="components">
+         <object classname="java.util.LinkedList">
+          <item >
+           <at name="value">
+            <object classname="com.jeta.forms.store.memento.BeanMemento">
+             <super classname="com.jeta.forms.store.memento.ComponentMemento">
+              <at name="cellconstraints">
+               <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+                <at name="column">2</at>
+                <at name="row">1</at>
+                <at name="colspan">1</at>
+                <at name="rowspan">1</at>
+                <at name="halign">default</at>
+                <at name="valign">default</at>
+                <at name="insets" object="insets">0,0,0,0</at>
+               </object>
+              </at>
+              <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+             </super>
+             <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+             <at name="beanclass">javax.swing.JComboBox</at>
+             <at name="beanproperties">
+              <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+               <at name="classname">javax.swing.JComboBox</at>
+               <at name="properties">
+                <object classname="com.jeta.forms.store.support.PropertyMap">
+                 <at name="height">20</at>
+                 <at name="items">
+                  <object classname="com.jeta.forms.store.properties.ItemsProperty">
+                   <at name="name">items</at>
+                  </object>
+                 </at>
+                 <at name="width">26</at>
+                 <at name="name">cmbMeasureUnits</at>
+                 <at name="border">
+                  <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                   <at name="borders">
+                    <object classname="java.util.LinkedList">
+                     <item >
+                      <at name="value">
+                       <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                        <super classname="com.jeta.forms.store.properties.BorderProperty">
+                         <at name="name">border</at>
+                        </super>
+                       </object>
+                      </at>
+                     </item>
+                    </object>
+                   </at>
+                  </object>
+                 </at>
+                </object>
+               </at>
+              </object>
+             </at>
+            </object>
+           </at>
+          </item>
+          <item >
+           <at name="value">
+            <object classname="com.jeta.forms.store.memento.BeanMemento">
+             <super classname="com.jeta.forms.store.memento.ComponentMemento">
+              <at name="cellconstraints">
+               <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+                <at name="column">1</at>
+                <at name="row">1</at>
+                <at name="colspan">1</at>
+                <at name="rowspan">1</at>
+                <at name="halign">default</at>
+                <at name="valign">default</at>
+                <at name="insets" object="insets">0,0,0,0</at>
+               </object>
+              </at>
+              <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+             </super>
+             <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+             <at name="beanclass">javax.swing.JTextField</at>
+             <at name="beanproperties">
+              <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+               <at name="classname">javax.swing.JTextField</at>
+               <at name="properties">
+                <object classname="com.jeta.forms.store.support.PropertyMap">
+                 <at name="height">20</at>
+                 <at name="width">693</at>
+                 <at name="name">txtSearchRadius</at>
+                 <at name="border">
+                  <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                   <at name="borders">
+                    <object classname="java.util.LinkedList">
+                     <item >
+                      <at name="value">
+                       <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                        <super classname="com.jeta.forms.store.properties.BorderProperty">
+                         <at name="name">border</at>
+                        </super>
+                       </object>
+                      </at>
+                     </item>
+                    </object>
+                   </at>
+                  </object>
+                 </at>
+                </object>
+               </at>
+              </object>
+             </at>
+            </object>
+           </at>
+          </item>
+         </object>
+        </at>
+        <at name="properties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.gui.form.GridView</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="name"/>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="scollBars">
+             <object classname="com.jeta.forms.store.properties.ScrollBarsProperty">
+              <at name="name">scollBars</at>
+              <at name="verticalpolicy">21</at>
+              <at name="horizontalpolicy">31</at>
+              <at name="border">
+               <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                <super classname="com.jeta.forms.store.properties.BorderProperty">
+                 <at name="name">border</at>
+                </super>
+                <at name="borders">
+                 <object classname="java.util.LinkedList">
+                  <item >
+                   <at name="value">
+                    <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                     <super classname="com.jeta.forms.store.properties.BorderProperty">
+                      <at name="name">border</at>
+                     </super>
+                    </object>
+                   </at>
+                  </item>
+                 </object>
+                </at>
+               </object>
+              </at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList"/>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+        <at name="cellpainters">
+         <object classname="com.jeta.forms.store.support.Matrix">
+          <at name="rows">
+           <object classname="[Ljava.lang.Object;" size="1">
+            <at name="item" index="0">
+             <object classname="[Ljava.lang.Object;" size="2"/>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+        <at name="rowgroups">
+         <object classname="com.jeta.forms.store.memento.FormGroupSet">
+          <at name="groups">
+           <object classname="java.util.HashMap"/>
+          </at>
+         </object>
+        </at>
+        <at name="colgroups">
+         <object classname="com.jeta.forms.store.memento.FormGroupSet">
+          <at name="groups">
+           <object classname="java.util.HashMap"/>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+     <item >
+      <at name="value">
+       <object classname="com.jeta.forms.store.memento.FormMemento">
+        <super classname="com.jeta.forms.store.memento.ComponentMemento">
+         <at name="cellconstraints">
+          <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+           <at name="column">2</at>
+           <at name="row">16</at>
+           <at name="colspan">4</at>
+           <at name="rowspan">1</at>
+           <at name="halign">right</at>
+           <at name="valign">default</at>
+           <at name="insets" object="insets">0,0,0,0</at>
+          </object>
+         </at>
+         <at name="componentclass">com.jeta.forms.gui.form.FormComponent</at>
+        </super>
+        <at name="id">embedded.1819485502</at>
+        <at name="rowspecs">CENTER:DEFAULT:NONE</at>
+        <at name="colspecs">FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE</at>
+        <at name="components">
+         <object classname="java.util.LinkedList">
+          <item >
+           <at name="value">
+            <object classname="com.jeta.forms.store.memento.BeanMemento">
+             <super classname="com.jeta.forms.store.memento.ComponentMemento">
+              <at name="cellconstraints">
+               <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+                <at name="column">1</at>
+                <at name="row">1</at>
+                <at name="colspan">1</at>
+                <at name="rowspan">1</at>
+                <at name="halign">default</at>
+                <at name="valign">default</at>
+                <at name="insets" object="insets">0,0,0,0</at>
+               </object>
+              </at>
+              <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+             </super>
+             <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+             <at name="beanclass">javax.swing.JButton</at>
+             <at name="beanproperties">
+              <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+               <at name="classname">javax.swing.JButton</at>
+               <at name="properties">
+                <object classname="com.jeta.forms.store.support.PropertyMap">
+                 <at name="text">_Accept</at>
+                 <at name="height">22</at>
+                 <at name="width">75</at>
+                 <at name="name">btnAccept</at>
+                 <at name="actionCommand">_Accept</at>
+                 <at name="border">
+                  <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                   <at name="borders">
+                    <object classname="java.util.LinkedList">
+                     <item >
+                      <at name="value">
+                       <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                        <super classname="com.jeta.forms.store.properties.BorderProperty">
+                         <at name="name">border</at>
+                        </super>
+                       </object>
+                      </at>
+                     </item>
+                    </object>
+                   </at>
+                  </object>
+                 </at>
+                </object>
+               </at>
+              </object>
+             </at>
+            </object>
+           </at>
+          </item>
+          <item >
+           <at name="value">
+            <object classname="com.jeta.forms.store.memento.BeanMemento">
+             <super classname="com.jeta.forms.store.memento.ComponentMemento">
+              <at name="cellconstraints">
+               <object classname="com.jeta.forms.store.memento.CellConstraintsMemento">
+                <at name="column">3</at>
+                <at name="row">1</at>
+                <at name="colspan">1</at>
+                <at name="rowspan">1</at>
+                <at name="halign">default</at>
+                <at name="valign">default</at>
+                <at name="insets" object="insets">0,0,0,0</at>
+               </object>
+              </at>
+              <at name="componentclass">com.jeta.forms.gui.form.StandardComponent</at>
+             </super>
+             <at name="jetabeanclass">com.jeta.forms.gui.beans.JETABean</at>
+             <at name="beanclass">javax.swing.JButton</at>
+             <at name="beanproperties">
+              <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+               <at name="classname">javax.swing.JButton</at>
+               <at name="properties">
+                <object classname="com.jeta.forms.store.support.PropertyMap">
+                 <at name="text">_Cancel</at>
+                 <at name="height">22</at>
+                 <at name="width">76</at>
+                 <at name="name">btnCancel</at>
+                 <at name="actionCommand">_Cancel</at>
+                 <at name="border">
+                  <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                   <super classname="com.jeta.forms.store.properties.BorderProperty">
+                    <at name="name">border</at>
+                   </super>
+                   <at name="borders">
+                    <object classname="java.util.LinkedList">
+                     <item >
+                      <at name="value">
+                       <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                        <super classname="com.jeta.forms.store.properties.BorderProperty">
+                         <at name="name">border</at>
+                        </super>
+                       </object>
+                      </at>
+                     </item>
+                    </object>
+                   </at>
+                  </object>
+                 </at>
+                </object>
+               </at>
+              </object>
+             </at>
+            </object>
+           </at>
+          </item>
+         </object>
+        </at>
+        <at name="properties">
+         <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+          <at name="classname">com.jeta.forms.gui.form.GridView</at>
+          <at name="properties">
+           <object classname="com.jeta.forms.store.support.PropertyMap">
+            <at name="name"/>
+            <at name="fill">
+             <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+              <at name="name">fill</at>
+             </object>
+            </at>
+            <at name="scollBars">
+             <object classname="com.jeta.forms.store.properties.ScrollBarsProperty">
+              <at name="name">scollBars</at>
+              <at name="verticalpolicy">21</at>
+              <at name="horizontalpolicy">31</at>
+              <at name="border">
+               <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+                <super classname="com.jeta.forms.store.properties.BorderProperty">
+                 <at name="name">border</at>
+                </super>
+                <at name="borders">
+                 <object classname="java.util.LinkedList">
+                  <item >
+                   <at name="value">
+                    <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                     <super classname="com.jeta.forms.store.properties.BorderProperty">
+                      <at name="name">border</at>
+                     </super>
+                    </object>
+                   </at>
+                  </item>
+                 </object>
+                </at>
+               </object>
+              </at>
+             </object>
+            </at>
+            <at name="border">
+             <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+              <super classname="com.jeta.forms.store.properties.BorderProperty">
+               <at name="name">border</at>
+              </super>
+              <at name="borders">
+               <object classname="java.util.LinkedList"/>
+              </at>
+             </object>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+        <at name="cellpainters">
+         <object classname="com.jeta.forms.store.support.Matrix">
+          <at name="rows">
+           <object classname="[Ljava.lang.Object;" size="1">
+            <at name="item" index="0">
+             <object classname="[Ljava.lang.Object;" size="3"/>
+            </at>
+           </object>
+          </at>
+         </object>
+        </at>
+        <at name="rowgroups">
+         <object classname="com.jeta.forms.store.memento.FormGroupSet">
+          <at name="groups">
+           <object classname="java.util.HashMap"/>
+          </at>
+         </object>
+        </at>
+        <at name="colgroups">
+         <object classname="com.jeta.forms.store.memento.FormGroupSet">
+          <at name="groups">
+           <object classname="java.util.HashMap"/>
+          </at>
+         </object>
+        </at>
+       </object>
+      </at>
+     </item>
+    </object>
+   </at>
+   <at name="properties">
+    <object classname="com.jeta.forms.store.memento.PropertiesMemento">
+     <at name="classname">com.jeta.forms.gui.form.GridView</at>
+     <at name="properties">
+      <object classname="com.jeta.forms.store.support.PropertyMap">
+       <at name="name"/>
+       <at name="fill">
+        <object classname="com.jeta.forms.store.properties.effects.PaintProperty">
+         <at name="name">fill</at>
+        </object>
+       </at>
+       <at name="scollBars">
+        <object classname="com.jeta.forms.store.properties.ScrollBarsProperty">
+         <at name="name">scollBars</at>
+         <at name="verticalpolicy">21</at>
+         <at name="horizontalpolicy">31</at>
+         <at name="border">
+          <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+           <super classname="com.jeta.forms.store.properties.BorderProperty">
+            <at name="name">border</at>
+           </super>
+           <at name="borders">
+            <object classname="java.util.LinkedList">
+             <item >
+              <at name="value">
+               <object classname="com.jeta.forms.store.properties.DefaultBorderProperty">
+                <super classname="com.jeta.forms.store.properties.BorderProperty">
+                 <at name="name">border</at>
+                </super>
+               </object>
+              </at>
+             </item>
+            </object>
+           </at>
+          </object>
+         </at>
+        </object>
+       </at>
+       <at name="border">
+        <object classname="com.jeta.forms.store.properties.CompoundBorderProperty">
+         <super classname="com.jeta.forms.store.properties.BorderProperty">
+          <at name="name">border</at>
+         </super>
+         <at name="borders">
+          <object classname="java.util.LinkedList"/>
+         </at>
+        </object>
+       </at>
+      </object>
+     </at>
+    </object>
+   </at>
+   <at name="cellpainters">
+    <object classname="com.jeta.forms.store.support.Matrix">
+     <at name="rows">
+      <object classname="[Ljava.lang.Object;" size="17">
+       <at name="item" index="0">
+        <object classname="[Ljava.lang.Object;" size="6"/>
+       </at>
+       <at name="item" index="1">
+        <object classname="[Ljava.lang.Object;" size="6"/>
+       </at>
+       <at name="item" index="2">
+        <object classname="[Ljava.lang.Object;" size="6"/>
+       </at>
+       <at name="item" index="3">
+        <object classname="[Ljava.lang.Object;" size="6"/>
+       </at>
+       <at name="item" index="4">
+        <object classname="[Ljava.lang.Object;" size="6"/>
+       </at>
+       <at name="item" index="5">
+        <object classname="[Ljava.lang.Object;" size="6"/>
+       </at>
+       <at name="item" index="6">
+        <object classname="[Ljava.lang.Object;" size="6"/>
+       </at>
+       <at name="item" index="7">
+        <object classname="[Ljava.lang.Object;" size="6"/>
+       </at>
+       <at name="item" index="8">
+        <object classname="[Ljava.lang.Object;" size="6"/>
+       </at>
+       <at name="item" index="9">
+        <object classname="[Ljava.lang.Object;" size="6"/>
+       </at>
+       <at name="item" index="10">
+        <object classname="[Ljava.lang.Object;" size="6"/>
+       </at>
+       <at name="item" index="11">
+        <object classname="[Ljava.lang.Object;" size="6"/>
+       </at>
+       <at name="item" index="12">
+        <object classname="[Ljava.lang.Object;" size="6"/>
+       </at>
+       <at name="item" index="13">
+        <object classname="[Ljava.lang.Object;" size="6"/>
+       </at>
+       <at name="item" index="14">
+        <object classname="[Ljava.lang.Object;" size="6"/>
+       </at>
+       <at name="item" index="15">
+        <object classname="[Ljava.lang.Object;" size="6"/>
+       </at>
+       <at name="item" index="16">
+        <object classname="[Ljava.lang.Object;" size="6"/>
+       </at>
+      </object>
+     </at>
+    </object>
+   </at>
+   <at name="rowgroups">
+    <object classname="com.jeta.forms.store.memento.FormGroupSet">
+     <at name="groups">
+      <object classname="java.util.HashMap"/>
+     </at>
+    </object>
+   </at>
+   <at name="colgroups">
+    <object classname="com.jeta.forms.store.memento.FormGroupSet">
+     <at name="groups">
+      <object classname="java.util.HashMap"/>
+     </at>
+    </object>
+   </at>
+  </object>
+ </at>
+</object>
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsShowMeasuresParamsView.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsShowMeasuresParamsView.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsShowMeasuresParamsView.java	(revision 950)
@@ -0,0 +1,175 @@
+package org.gvsig.lrs.swing.impl;
+
+import com.jeta.open.i18n.I18NUtils;
+import com.jgoodies.forms.layout.CellConstraints;
+import com.jgoodies.forms.layout.FormLayout;
+import java.awt.BorderLayout;
+import java.awt.ComponentOrientation;
+import java.awt.Container;
+import java.awt.Dimension;
+import javax.swing.Box;
+import javax.swing.ImageIcon;
+import javax.swing.JButton;
+import javax.swing.JComboBox;
+import javax.swing.JFrame;
+import javax.swing.JLabel;
+import javax.swing.JPanel;
+import javax.swing.JTextField;
+
+
+public class JLrsShowMeasuresParamsView extends JPanel
+{
+   JButton btnAccept = new JButton();
+   JButton btnCancel = new JButton();
+   JLabel lblUnits = new JLabel();
+   JComboBox cboUnits = new JComboBox();
+   JLabel lblDistance = new JLabel();
+   JTextField txtDistance = new JTextField();
+
+   /**
+    * Default constructor
+    */
+   public JLrsShowMeasuresParamsView()
+   {
+      initializePanel();
+   }
+
+   /**
+    * Adds fill components to empty cells in the first row and first column of the grid.
+    * This ensures that the grid spacing will be the same as shown in the designer.
+    * @param cols an array of column indices in the first row where fill components should be added.
+    * @param rows an array of row indices in the first column where fill components should be added.
+    */
+   void addFillComponents( Container panel, int[] cols, int[] rows )
+   {
+      Dimension filler = new Dimension(10,10);
+
+      boolean filled_cell_11 = false;
+      CellConstraints cc = new CellConstraints();
+      if ( cols.length > 0 && rows.length > 0 )
+      {
+         if ( cols[0] == 1 && rows[0] == 1 )
+         {
+            /** add a rigid area  */
+            panel.add( Box.createRigidArea( filler ), cc.xy(1,1) );
+            filled_cell_11 = true;
+         }
+      }
+
+      for( int index = 0; index < cols.length; index++ )
+      {
+         if ( cols[index] == 1 && filled_cell_11 )
+         {
+            continue;
+         }
+         panel.add( Box.createRigidArea( filler ), cc.xy(cols[index],1) );
+      }
+
+      for( int index = 0; index < rows.length; index++ )
+      {
+         if ( rows[index] == 1 && filled_cell_11 )
+         {
+            continue;
+         }
+         panel.add( Box.createRigidArea( filler ), cc.xy(1,rows[index]) );
+      }
+
+   }
+
+   /**
+    * Helper method to load an image file from the CLASSPATH
+    * @param imageName the package and name of the file to load relative to the CLASSPATH
+    * @return an ImageIcon instance with the specified image file
+    * @throws IllegalArgumentException if the image resource cannot be loaded.
+    */
+   public ImageIcon loadImage( String imageName )
+   {
+      try
+      {
+         ClassLoader classloader = getClass().getClassLoader();
+         java.net.URL url = classloader.getResource( imageName );
+         if ( url != null )
+         {
+            ImageIcon icon = new ImageIcon( url );
+            return icon;
+         }
+      }
+      catch( Exception e )
+      {
+         e.printStackTrace();
+      }
+      throw new IllegalArgumentException( "Unable to load image: " + imageName );
+   }
+
+   /**
+    * Method for recalculating the component orientation for 
+    * right-to-left Locales.
+    * @param orientation the component orientation to be applied
+    */
+   public void applyComponentOrientation( ComponentOrientation orientation )
+   {
+      // Not yet implemented...
+      // I18NUtils.applyComponentOrientation(this, orientation);
+      super.applyComponentOrientation(orientation);
+   }
+
+   public JPanel createPanel()
+   {
+      JPanel jpanel1 = new JPanel();
+      FormLayout formlayout1 = new FormLayout("FILL:4DLU:NONE,FILL:DEFAULT:GROW(1.0),FILL:4DLU:NONE","CENTER:2DLU:NONE,CENTER:DEFAULT:NONE,CENTER:2DLU:NONE,CENTER:DEFAULT:NONE,CENTER:2DLU:NONE,CENTER:DEFAULT:NONE,CENTER:2DLU:NONE,CENTER:DEFAULT:NONE,CENTER:DEFAULT:GROW(1.0),CENTER:DEFAULT:NONE,CENTER:2DLU:NONE");
+      CellConstraints cc = new CellConstraints();
+      jpanel1.setLayout(formlayout1);
+
+      jpanel1.add(createPanel1(),new CellConstraints(2,10,1,1,CellConstraints.RIGHT,CellConstraints.DEFAULT));
+      lblUnits.setName("lblUnits");
+      lblUnits.setText("_Data_units");
+      lblUnits.setToolTipText("_Units_of_measure_of_the_M_coordinate_of_the_layer");
+      jpanel1.add(lblUnits,cc.xy(2,2));
+
+      cboUnits.setName("cboUnits");
+      cboUnits.setToolTipText("_Units_of_measure_of_the_M_coordinate_of_the_layer");
+      jpanel1.add(cboUnits,cc.xy(2,4));
+
+      lblDistance.setName("lblDistance");
+      lblDistance.setText("distance");
+      jpanel1.add(lblDistance,cc.xy(2,6));
+
+      txtDistance.setName("txtDistance");
+      jpanel1.add(txtDistance,cc.xy(2,8));
+
+      addFillComponents(jpanel1,new int[]{ 1,2,3 },new int[]{ 1,2,3,4,5,6,7,8,9,10,11 });
+      return jpanel1;
+   }
+
+   public JPanel createPanel1()
+   {
+      JPanel jpanel1 = new JPanel();
+      FormLayout formlayout1 = new FormLayout("FILL:DEFAULT:NONE,FILL:4DLU:NONE,FILL:DEFAULT:NONE","CENTER:DEFAULT:NONE");
+      CellConstraints cc = new CellConstraints();
+      jpanel1.setLayout(formlayout1);
+
+      btnAccept.setActionCommand("_Accept");
+      btnAccept.setName("btnAccept");
+      btnAccept.setText("_Accept");
+      jpanel1.add(btnAccept,new CellConstraints(1,1,1,1,CellConstraints.CENTER,CellConstraints.DEFAULT));
+
+      btnCancel.setActionCommand("_Cancel");
+      btnCancel.setName("btnCancel");
+      btnCancel.setText("_Cancel");
+      jpanel1.add(btnCancel,cc.xy(3,1));
+
+      addFillComponents(jpanel1,new int[]{ 2 },new int[0]);
+      return jpanel1;
+   }
+
+   /**
+    * Initializer
+    */
+   protected void initializePanel()
+   {
+      setLayout(new BorderLayout());
+      add(createPanel(), BorderLayout.CENTER);
+   }
+
+
+}
Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsGenerateDynamicSegmentationParamsController.java
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsGenerateDynamicSegmentationParamsController.java	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl/JLrsGenerateDynamicSegmentationParamsController.java	(revision 950)
@@ -0,0 +1,613 @@
+/*
+ * Copyright 2015 DiSiD Technologies S.L.L. All rights reserved.
+ *
+ * Project  : DiSiD org.gvsig.lrs.swing.impl
+ * SVN Id   : $Id$
+ */
+package org.gvsig.lrs.swing.impl;
+
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.awt.event.ItemEvent;
+import java.awt.event.ItemListener;
+import java.io.File;
+import java.util.List;
+import java.util.Locale;
+
+import javax.swing.JComponent;
+import javax.swing.JOptionPane;
+import javax.swing.ListCellRenderer;
+
+import org.apache.commons.io.FileUtils;
+import org.apache.commons.lang3.StringUtils;
+import org.cresques.cts.IProjection;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import org.gvsig.fmap.dal.exception.DataException;
+import org.gvsig.fmap.dal.exception.ReadException;
+import org.gvsig.fmap.dal.feature.FeatureAttributeDescriptor;
+import org.gvsig.fmap.dal.feature.FeatureStore;
+import org.gvsig.fmap.dal.feature.FeatureType;
+import org.gvsig.fmap.dal.feature.NewFeatureStoreParameters;
+import org.gvsig.fmap.dal.store.shp.SHPNewStoreParameters;
+import org.gvsig.fmap.geom.DataTypes;
+import org.gvsig.fmap.mapcontext.layers.FLayer;
+import org.gvsig.fmap.mapcontext.layers.operations.LayerCollection;
+import org.gvsig.fmap.mapcontext.layers.vectorial.FLyrVect;
+import org.gvsig.lrs.lib.api.LrsAlgorithmParams;
+import org.gvsig.lrs.lib.api.LrsAlgorithmsLocator;
+import org.gvsig.lrs.lib.api.LrsAlgorithmsManager;
+import org.gvsig.lrs.lib.api.LrsGenerateDynamicSegmentationAlgorithmParams;
+import org.gvsig.lrs.lib.api.exceptions.LrsGettingParametersException;
+import org.gvsig.lrs.lib.api.exceptions.LrsNeededParameterException;
+import org.gvsig.lrs.swing.api.JLrsAlgorithmParams;
+import org.gvsig.tools.ToolsLocator;
+import org.gvsig.tools.i18n.I18nManager;
+import org.gvsig.tools.swing.api.ActionListenerSupport;
+import org.gvsig.tools.swing.api.ToolsSwingLocator;
+import org.gvsig.tools.swing.api.threadsafedialogs.ThreadSafeDialogsManager;
+
+public class JLrsGenerateDynamicSegmentationParamsController extends
+    JLrsGenerateDynamicSegmentationParamsView implements JLrsAlgorithmParams {
+
+    /**
+     *
+     */
+    private static final long serialVersionUID = -5764089056918981236L;
+
+    private static final Logger logger = LoggerFactory
+        .getLogger(JLrsGenerateDynamicSegmentationParamsController.class);
+
+    private boolean canceled;
+    private ActionListenerSupport listeners =
+        ToolsSwingLocator.getToolsSwingManager().createActionListenerSupport();
+
+    private LayerCollection layers;
+    private List<FeatureStore> tables;
+
+    /**
+     * @param layers
+     * @throws LrsNeededParameterException
+     *
+     */
+    public JLrsGenerateDynamicSegmentationParamsController(
+        LayerCollection layers, List<FeatureStore> tables,
+        LrsAlgorithmParams params) throws LrsNeededParameterException {
+        super();
+        this.layers = layers;
+        this.tables = tables;
+        initComponents();
+        translate();
+        setParams(params);
+    }
+
+    public void addActionListener(ActionListener listener) {
+        listeners.addActionListener(listener);
+    }
+
+    public void removeActionListener(ActionListener listener) {
+        listeners.removeActionListener(listener);
+    }
+
+    private void translate() {
+        I18nManager i18nManager = ToolsLocator.getI18nManager();
+
+        lblInputLayer
+            .setText(i18nManager.getTranslation(lblInputLayer.getText()));
+        lblIdRouteField
+            .setText(i18nManager.getTranslation(lblIdRouteField.getText()));
+        lblTable.setText(i18nManager.getTranslation(lblTable.getText()));
+        lblTableIdRouteField.setText(
+            i18nManager.getTranslation(lblTableIdRouteField.getText()));
+        lblLandmarkField
+            .setText(i18nManager.getTranslation(lblLandmarkField.getText()));
+        lblFinalLandmarkField.setText(
+            i18nManager.getTranslation(lblFinalLandmarkField.getText()));
+        lblValueField
+            .setText(i18nManager.getTranslation(lblValueField.getText()));
+        lblOutputFile
+            .setText(i18nManager.getTranslation(lblOutputFile.getText()));
+
+        btnBrowser.setText("\u2026");
+        btnAccept.setText(i18nManager.getTranslation(btnAccept.getText()));
+        btnCancel.setText(i18nManager.getTranslation(btnCancel.getText()));
+
+    }
+
+    /**
+     *
+     */
+    public void setLocate(Locale locale) {
+        Locale l = super.getLocale();
+        if (!l.equals(locale)) {
+            translate();
+        }
+        super.setLocale(locale);
+    }
+
+    /**
+     * Validates it is a curve layer with at least 1 non-geometric
+     * field
+     * if it is not correct throws an exception
+     *
+     * @throws LrsNeededParameterException
+     * @throws ReadException
+     */
+    public static void validateLayers(LayerCollection layers)
+        throws LrsNeededParameterException {
+        logger.debug("Validating layer for Generate Dynamic Segmentation");
+        if (layers == null || layers.getLayersCount() < 1) {
+            logger.error("A layer is needed");
+            throw new LrsNeededParameterException("a_layer_is_needed", null);
+        }
+
+        if (!JLrsUtils.validateMLayerWithNonGeomField(layers)) {
+            logger.error("Impossible to find the layer needed");
+            throw new LrsNeededParameterException(
+                "impossible_to_find_needed_layer", null);
+        }
+    }
+
+    /**
+     * Validates if there is a valid table:
+     * - at least two fields
+     * - one of them is numeric
+     * if can't find any throws an exception
+     *
+     * @throws LrsNeededParameterException
+     * @throws ReadException
+     */
+    public static void validateTables(List<FeatureStore> tables)
+        throws LrsNeededParameterException {
+        logger.debug("Validating tables for Generate Dynamic Segmentation");
+        if (tables == null || tables.size() < 1) {
+            logger.error("A table is needed");
+            throw new LrsNeededParameterException("a_table_is_needed", null);
+        }
+
+        if (!JLrsUtils.validateStoreWithFieldsAndOneNumeric(tables)) {
+            logger.error("Impossible to find the layer needed");
+            throw new LrsNeededParameterException(
+                "impossible_to_find_needed_layer", null);
+        }
+    }
+
+    /**
+     * @throws LrsNeededParameterException
+     */
+    private void initComponents() throws LrsNeededParameterException {
+
+        validateLayers(layers);
+        validateTables(tables);
+
+        // Modelos de los combos
+        FLayersMComboBoxModel inputLayerModel =
+            new FLayersMComboBoxModel(this.layers);
+        FeatureAttributeDescriptorsComboBoxModel idRouteFieldComboBoxModel =
+            new FeatureAttributeDescriptorsComboBoxModel();
+
+        FeatureStoresComboBoxModel tableLayerModel =
+            new FeatureStoresComboBoxModel(this.tables);
+
+        FeatureAttributeDescriptorsComboBoxModel tableIdRouteFieldComboBoxModel =
+            new FeatureAttributeDescriptorsComboBoxModel();
+        FeatureAttributeDescriptorsComboBoxModel landmarkComboBoxModel =
+            new FeatureAttributeDescriptorsComboBoxModel();
+        FeatureAttributeDescriptorsComboBoxModel finalLandmarkComboBoxModel =
+            new FeatureAttributeDescriptorsComboBoxModel();
+        FeatureAttributeDescriptorsComboBoxModel valueComboBoxModel =
+            new FeatureAttributeDescriptorsComboBoxModel();
+
+        // Renderer para los combos de attributeDescriptors
+        ListCellRenderer featureAttributeDescriptorCellRenderer =
+            new FLayersAttributeDescriptorCellRenderer();
+        // asignación de renderers y modelos
+        cmbIdRouteField.setRenderer(featureAttributeDescriptorCellRenderer);
+        cmbTableIdRouteField
+            .setRenderer(featureAttributeDescriptorCellRenderer);
+        cmbLandmarkField.setRenderer(featureAttributeDescriptorCellRenderer);
+        cmbFinalLandmarkField
+            .setRenderer(featureAttributeDescriptorCellRenderer);
+        cmbValueField.setRenderer(featureAttributeDescriptorCellRenderer);
+        cmbIdRouteField.setModel(idRouteFieldComboBoxModel);
+        cmbTableIdRouteField.setModel(tableIdRouteFieldComboBoxModel);
+        cmbLandmarkField.setModel(landmarkComboBoxModel);
+        cmbFinalLandmarkField.setModel(finalLandmarkComboBoxModel);
+        cmbValueField.setModel(valueComboBoxModel);
+
+        // renderer para el combo de capas
+        ListCellRenderer layerNameCellRenderer =
+            new FLayersLayerNameCellRenderer();
+        ListCellRenderer featureStorerNameCellRenderer =
+            new FeatureStoreNameCellRenderer();
+        cmbInputLayer.setRenderer(layerNameCellRenderer);
+        cmbTable.setRenderer(featureStorerNameCellRenderer);
+        // asignación modelo al combo de capas
+        cmbInputLayer.setModel(inputLayerModel);
+        cmbTable.setModel(tableLayerModel);
+
+        // listener del combo de capas para que actualice el resto de componentes
+        cmbInputLayer.addItemListener(new ItemListener() {
+
+            public void itemStateChanged(ItemEvent e) {
+                Object item = e.getItem();
+                if (item instanceof FLyrVect) {
+                    FLyrVect layer = (FLyrVect) item;
+                    updateLayerSource(layer);
+                }
+            }
+        });
+        cmbTable.addItemListener(new ItemListener() {
+
+            public void itemStateChanged(ItemEvent e) {
+                Object item = e.getItem();
+                if (item instanceof FeatureStore) {
+                    FeatureStore featureStore = (FeatureStore) item;
+                    updateTable(featureStore);
+                    clearTableFields();
+                }
+            }
+        });
+
+        this.btnBrowser.addActionListener(new ActionListener() {
+
+            public void actionPerformed(ActionEvent e) {
+                doSelectOuputFile();
+            }
+        });
+
+        this.btnAccept.addActionListener(new ActionListener() {
+
+            public void actionPerformed(ActionEvent e) {
+                canceled = false;
+                doClose();
+                listeners.fireActionEvent(new ActionEvent(
+                    JLrsGenerateDynamicSegmentationParamsController.this, 0,
+                    "accept"));
+
+            }
+        });
+
+        this.btnCancel.addActionListener(new ActionListener() {
+
+            public void actionPerformed(ActionEvent e) {
+                canceled = true;
+                doClose();
+                listeners.fireActionEvent(new ActionEvent(
+                    JLrsGenerateDynamicSegmentationParamsController.this, 0,
+                    "cancel"));
+            }
+        });
+
+        setVisibleAceptCancel(false);
+        canceled = false;
+    }
+
+    private void doSelectOuputFile() {
+        final I18nManager i18nManager = ToolsLocator.getI18nManager();
+        ThreadSafeDialogsManager manager =
+            ToolsSwingLocator.getThreadSafeDialogsManager();
+        File[] files = manager.showSaveFileDialog(
+            i18nManager.getTranslation("output_file"), null);
+        if (files != null && files.length > 0) {
+            File file = files[0];
+            String absolutePath = file.getAbsolutePath();
+            if (!StringUtils.endsWithIgnoreCase(absolutePath, ".shp")) {
+                absolutePath = new StringBuilder().append(absolutePath)
+                    .append(".shp").toString();
+            }
+            File outputFile = FileUtils.getFile(absolutePath);
+            if (outputFile.exists()) {
+                int resp = JOptionPane.showOptionDialog(this.asJComponent(),
+                    i18nManager.getTranslation(
+                        "file_already_exists_do_you_want_overwrite_it"),
+                    i18nManager.getTranslation("output_file"),
+                    JOptionPane.OK_CANCEL_OPTION, JOptionPane.QUESTION_MESSAGE,
+                    null, null, JOptionPane.OK_OPTION);
+                if (resp == JOptionPane.OK_OPTION) {
+                    this.txtOutputFile.setText(absolutePath);
+                } else {
+                    doSelectOuputFile();
+                }
+            } else {
+                this.txtOutputFile.setText(absolutePath);
+            }
+        }
+
+    }
+
+    private void doClose() {
+        this.setVisible(false);
+    }
+
+    public boolean isCanceled() {
+        return this.canceled;
+    }
+
+    public void setVisibleAceptCancel(boolean visible) {
+        this.btnAccept.setVisible(visible);
+        this.btnCancel.setVisible(visible);
+    }
+
+    public boolean getVisibleAceptCancel() {
+        return this.btnAccept.isVisible();
+    }
+
+    public JComponent asJComponent() {
+        return this;
+    }
+
+    public LrsAlgorithmParams getParams()  throws LrsGettingParametersException, LrsNeededParameterException {
+        LrsAlgorithmsManager manager = LrsAlgorithmsLocator.getLrsAlgorithmsManager();
+        LrsGenerateDynamicSegmentationAlgorithmParams params =manager.createLrsGenerateDynamicSegmentationAlgorithmParams();
+
+        // Recorrer todo del interfaz y rellenar los parametros
+
+        //cmbInputLayer
+        if (!(this.cmbInputLayer.getSelectedItem() instanceof FLyrVect)){
+            logger.error("Error getting selected item from cmbInputLayer");
+            throw new LrsGettingParametersException("error_getting_selected_item_from_cmbInputLayer", null);
+        }
+        FLyrVect fLyrVect = (FLyrVect) this.cmbInputLayer.getSelectedItem();
+        IProjection projection= fLyrVect.getProjection();
+        if (!(fLyrVect.getFeatureStore() instanceof FeatureStore)){
+            logger.error("Error getting selected item from cmbInputLayer");
+            throw new LrsGettingParametersException("error_getting_selected_item_from_cmbInputLayer", null);
+        }
+        FeatureStore sourceFeatureStore = (FeatureStore)fLyrVect.getFeatureStore();
+        if (sourceFeatureStore == null) {
+            throw new LrsNeededParameterException("need_to_select_a_source_layer", null);
+        }
+        params.setSourceFeatureStore(sourceFeatureStore);
+
+        //cmbIdRouteField
+        if (!(this.cmbIdRouteField.getSelectedItem() instanceof FeatureAttributeDescriptor)){
+            logger.error("Error getting selected item from cmbIdRouteField");
+            throw new LrsGettingParametersException("error_getting_selected_item_from_cmbIdRouteField", null);
+        }
+        FeatureAttributeDescriptor idRouteField = (FeatureAttributeDescriptor) this.cmbIdRouteField.getSelectedItem();
+        if (idRouteField == null) {
+            throw new LrsNeededParameterException("need_to_select_a_route_identifier_field", null);
+        }
+        params.setIdRouteField(idRouteField);
+
+        //cmbTable
+        if (!(this.cmbTable.getSelectedItem() instanceof FeatureStore)){
+            logger.error("Error getting selected item from cmbTable");
+            throw new LrsGettingParametersException("error_getting_selected_item_from_cmbTable", null);
+        }
+        FeatureStore tableFeatureStore = (FeatureStore) this.cmbTable.getSelectedItem();
+        if (tableFeatureStore == null) {
+            throw new LrsNeededParameterException("need_to_select_a_table", null);
+        }
+        params.setValueTableFeatureStore(tableFeatureStore);
+
+        //cmbTableIdRouteField
+        if (!(this.cmbTableIdRouteField.getSelectedItem() instanceof FeatureAttributeDescriptor)){
+            logger.error("Error getting selected item from cmbTableIdRouteField");
+            throw new LrsGettingParametersException("error_getting_selected_item_from_cmbTableIdRouteField", null);
+        }
+        FeatureAttributeDescriptor tableIdRouteField = (FeatureAttributeDescriptor) this.cmbTableIdRouteField.getSelectedItem();
+        params.setValueTableIdRouteField(tableIdRouteField);
+
+        //cmbLandmarkField
+        if (!(this.cmbLandmarkField.getSelectedItem() instanceof FeatureAttributeDescriptor)){
+            logger.error("Error getting selected item from cmbLandmarkField");
+            throw new LrsGettingParametersException("error_getting_selected_item_from_cmbLandmarkField", null);
+        }
+        FeatureAttributeDescriptor landmarkField = (FeatureAttributeDescriptor) this.cmbLandmarkField.getSelectedItem();
+        if (landmarkField == null) {
+            throw new LrsNeededParameterException("need_to_select_a_landmark_field", null);
+        }
+        params.setLandmarkField(landmarkField);
+
+        //cmbFinalLandmarkField
+        if (this.cmbFinalLandmarkField.getSelectedItem()!=null && !(this.cmbFinalLandmarkField.getSelectedItem() instanceof FeatureAttributeDescriptor)){
+            logger.error("Error getting selected item from cmbFinalLandmarkField");
+            throw new LrsGettingParametersException("error_getting_selected_item_from_cmbFinalLandmarkField", null);
+        }
+        FeatureAttributeDescriptor finalLandmarkField = (FeatureAttributeDescriptor) this.cmbFinalLandmarkField.getSelectedItem();
+        params.setFinalLandmarkField(finalLandmarkField);
+
+        //cmbValue
+        if (!(this.cmbValueField.getSelectedItem() instanceof FeatureAttributeDescriptor)){
+            logger.error("Error getting selected item from cmbValueField");
+            throw new LrsGettingParametersException("error_getting_selected_item_from_cmbValueField", null);
+        }
+        FeatureAttributeDescriptor valueField = (FeatureAttributeDescriptor) this.cmbValueField.getSelectedItem();
+        if (valueField == null) {
+            throw new LrsNeededParameterException("need_to_select_a_value_field", null);
+        }
+        params.setValueField(valueField);
+
+        //OutputStore
+        String outputLayerPathFile = this.txtOutputFile.getText();
+        if(StringUtils.isEmpty(outputLayerPathFile)){
+            throw new LrsNeededParameterException("need_to_fill_the_target_path", null);
+        }
+        try {
+            NewFeatureStoreParameters newFeatureStoreParams=JLrsUtils.createFeatureStoreParams(outputLayerPathFile, projection);
+            params.setNewFeatureStoreParameters(newFeatureStoreParams);
+        } catch (Exception e) {
+            throw new LrsNeededParameterException("error_creating_outputStore", e);
+        }
+
+        return params;
+    }
+
+    public void setParams(LrsAlgorithmParams params) {
+        if (params == null) {
+            clear();
+            return;
+        }
+        // Rellena los campos con los valores de params
+        LrsGenerateDynamicSegmentationAlgorithmParams parameters = (LrsGenerateDynamicSegmentationAlgorithmParams) params;
+
+        FeatureStore sourceFeatureStore = parameters.getSourceFeatureStore();
+        if(layers!=null && sourceFeatureStore!=null){
+            FLayer layer = layers.getLayer(sourceFeatureStore.getName());
+            this.cmbInputLayer.setSelectedItem(layer);
+        }
+
+        FeatureStore tableFeaturesStore=parameters.getValueTableFeatureStore();
+        if(tables!=null && tableFeaturesStore!=null){
+            this.cmbTable.setSelectedItem(tableFeaturesStore.getName());
+        }
+
+        NewFeatureStoreParameters newFeatureStoreParameters = parameters.getNewFeatureStoreParameters();
+        if(newFeatureStoreParameters!=null && newFeatureStoreParameters instanceof SHPNewStoreParameters){
+            this.txtOutputFile.setText(((SHPNewStoreParameters)newFeatureStoreParameters).getSHPFile().getAbsolutePath());
+        }
+
+        this.cmbIdRouteField.setSelectedItem(parameters.getIdRouteField());
+        this.cmbTableIdRouteField.setSelectedItem(parameters.getValueTableIdRouteField());
+        this.cmbLandmarkField.setSelectedItem(parameters.getLandmarkField());
+        this.cmbFinalLandmarkField.setSelectedItem(parameters.getFinalLandmarkField());
+        this.cmbValueField.setSelectedItem(parameters.getValueField());
+
+    }
+
+    public void clear() {
+        this.txtOutputFile.setText("");
+
+        this.cmbInputLayer.setSelectedIndex(0);
+        Object inputLayerSelected = this.cmbInputLayer.getSelectedItem();
+        if (inputLayerSelected != null) {
+            this.updateLayerSource((FLyrVect) inputLayerSelected);
+        }
+        if (this.cmbIdRouteField.getItemCount() > 0) {
+            this.cmbIdRouteField.setSelectedIndex(0);
+        }
+        this.cmbTable.setSelectedIndex(0);
+        Object tableSelected = this.cmbTable.getSelectedItem();
+        if (tableSelected != null) {
+            this.updateTable((FeatureStore) tableSelected);
+        }
+        clearTableFields();
+    }
+
+    /**
+     *
+     */
+    private void clearTableFields() {
+        logger.info(String.valueOf(this.cmbTableIdRouteField.getItemCount()));
+        if (this.cmbTableIdRouteField.getItemCount() > 0) {
+            this.cmbTableIdRouteField.setSelectedIndex(0);
+        }
+        logger.info(String.valueOf(this.cmbLandmarkField.getItemCount()));
+        if (this.cmbLandmarkField.getItemCount() > 0) {
+            this.cmbLandmarkField.setSelectedIndex(0);
+        }
+        logger.info(String.valueOf(this.cmbFinalLandmarkField.getItemCount()));
+        this.cmbFinalLandmarkField.setSelectedIndex(-1);
+
+        logger.info(String.valueOf(this.cmbValueField.getItemCount()));
+        if (this.cmbValueField.getItemCount() > 0) {
+            this.cmbValueField.setSelectedIndex(0);
+        }
+        this.cmbTableIdRouteField.repaint();
+        this.cmbLandmarkField.repaint();
+        this.cmbFinalLandmarkField.repaint();
+        this.cmbValueField.repaint();
+
+    }
+
+    private void updateLayerSource(FLyrVect layer) {
+        logger.info(new StringBuilder().append("Setting layer ")
+            .append(layer.getName()).toString());
+        FeatureStore featureStore = layer.getFeatureStore();
+        try {
+            FeatureType type = featureStore.getDefaultFeatureType();
+            // Se renuevan los combos de attributeDescriptors
+            FeatureAttributeDescriptorsComboBoxModel idRouteFieldComboBoxModel =
+                new FeatureAttributeDescriptorsComboBoxModel();
+
+            this.cmbIdRouteField.setModel(idRouteFieldComboBoxModel);
+
+            FeatureAttributeDescriptor[] attributeDescriptors =
+                type.getAttributeDescriptors();
+            for (int i = 0; i < attributeDescriptors.length; i++) {
+                FeatureAttributeDescriptor featureAttributeDescriptor =
+                    attributeDescriptors[i];
+                if (featureAttributeDescriptor.getDataType()
+                    .getType() != DataTypes.GEOMETRY) {
+                    logger.info(new StringBuilder().append("Adding field ")
+                        .append(featureAttributeDescriptor.getName())
+                        .toString());
+
+                    JLrsGenerateDynamicSegmentationParamsController.this.cmbIdRouteField
+                        .addItem(featureAttributeDescriptor);
+                }
+            }
+            this.cmbIdRouteField.invalidate();
+
+        } catch (DataException e1) {
+            logger.warn(new StringBuilder()
+                .append("Error getting default feature type from layer ")
+                .append(layer.getName()).toString(), e1);
+        }
+    }
+
+    private void updateTable(FeatureStore featureStore) {
+        logger.info(new StringBuilder().append("Setting featureStore ")
+            .append(featureStore.getName()).toString());
+        try {
+            FeatureType type = featureStore.getDefaultFeatureType();
+            // Se renuevan los combos de attributeDescriptors
+            FeatureAttributeDescriptorsComboBoxModel tableIdRouteComboBoxModel =
+                new FeatureAttributeDescriptorsComboBoxModel();
+            FeatureAttributeDescriptorsComboBoxModel landmarkComboBoxModel =
+                new FeatureAttributeDescriptorsComboBoxModel();
+            FeatureAttributeDescriptorsComboBoxModel finalLandmarkComboBoxModel =
+                new FeatureAttributeDescriptorsComboBoxModel();
+            FeatureAttributeDescriptorsComboBoxModel valueComboBoxModel =
+                new FeatureAttributeDescriptorsComboBoxModel();
+
+            this.cmbTableIdRouteField.setModel(tableIdRouteComboBoxModel);
+            this.cmbLandmarkField.setModel(landmarkComboBoxModel);
+            this.cmbFinalLandmarkField.setModel(finalLandmarkComboBoxModel);
+            this.cmbValueField.setModel(valueComboBoxModel);
+
+            // Renderer para los combos de attributeDescriptors
+            ListCellRenderer featureAttributeDescriptorCellRenderer =
+                new FLayersAttributeDescriptorCellRenderer();
+            // asignación de renderers
+            cmbTableIdRouteField
+                .setRenderer(featureAttributeDescriptorCellRenderer);
+            cmbLandmarkField.setRenderer(featureAttributeDescriptorCellRenderer);
+            cmbFinalLandmarkField
+                .setRenderer(featureAttributeDescriptorCellRenderer);
+            cmbValueField.setRenderer(featureAttributeDescriptorCellRenderer);
+
+            this.cmbFinalLandmarkField.insertItemAt(null,0);
+
+            FeatureAttributeDescriptor[] attributeDescriptors = type.getAttributeDescriptors();
+            for (int i = 0; i<attributeDescriptors.length; i++) {
+                FeatureAttributeDescriptor featureAttributeDescriptor =
+                    attributeDescriptors[i];
+                if (featureAttributeDescriptor.getDataType().getType() != DataTypes.GEOMETRY) {
+                    logger.info(new StringBuilder().append("0 - Adding field ")
+                        .append(featureAttributeDescriptor.getName())
+                        .toString());
+
+                    JLrsGenerateDynamicSegmentationParamsController.this.cmbTableIdRouteField.addItem(featureAttributeDescriptor);
+                    JLrsGenerateDynamicSegmentationParamsController.this.cmbValueField.addItem(featureAttributeDescriptor);
+                    if (featureAttributeDescriptor.getDataType().isNumeric()) {
+                        JLrsGenerateDynamicSegmentationParamsController.this.cmbLandmarkField.addItem(featureAttributeDescriptor);
+                        JLrsGenerateDynamicSegmentationParamsController.this.cmbFinalLandmarkField.addItem(featureAttributeDescriptor);
+                    }
+                    logger.info(new StringBuilder().append("1 - Adding field ")
+                        .append(featureAttributeDescriptor.getName())
+                        .toString());
+                }
+            }
+        } catch (DataException e1) {
+            logger
+                .warn(new StringBuilder()
+                    .append(
+                        "Error getting default feature type from featureStore ")
+                    .append(featureStore.getName()).toString(), e1);
+        }
+    }
+}

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing/impl
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs/swing
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig/lrs
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org/gvsig
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java/org
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main/java
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/main
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/test/java
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/test/resources
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src/test
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath



Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/src
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath


Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/pom.xml
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/pom.xml	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl/pom.xml	(revision 950)
@@ -0,0 +1,52 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+  <parent>
+    <groupId>org.gvsig</groupId>
+    <artifactId>org.gvsig.lrs.swing</artifactId>
+    <version>1.0.173</version>
+  </parent>
+  <artifactId>org.gvsig.lrs.swing.impl</artifactId>
+  <name>${project.artifactId}</name>
+  <dependencies>
+    <dependency>
+      <groupId>org.gvsig</groupId>
+      <artifactId>org.gvsig.lrs.swing.api</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.gvsig</groupId>
+      <artifactId>org.gvsig.tools.lib</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>com.jgoodies</groupId>
+      <artifactId>jgoodies-forms</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.gvsig</groupId>
+      <artifactId>org.gvsig.lrs.lib.api</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.gvsig</groupId>
+      <artifactId>org.gvsig.tools.swing.api</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.gvsig</groupId>
+      <artifactId>org.gvsig.fmap.control</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.gvsig</groupId>
+      <artifactId>org.gvsig.newlayer.lib.api</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.gvsig</groupId>
+      <artifactId>org.gvsig.fmap.dal.file.shp</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.gvsig</groupId>
+      <artifactId>org.gvsig.symbology.lib.api</artifactId>
+    </dependency>
+    <dependency>
+      <groupId>org.gvsig</groupId>
+      <artifactId>org.gvsig.fmap.mapcontext.api</artifactId>
+    </dependency>
+  </dependencies>
+</project>

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/org.gvsig.lrs.swing.impl
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath
target

.project


Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/pom.xml
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/pom.xml	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing/pom.xml	(revision 950)
@@ -0,0 +1,15 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+  <parent>
+    <groupId>org.gvsig</groupId>
+    <artifactId>org.gvsig.lrs</artifactId>
+    <version>1.0.173</version>
+  </parent>
+  <artifactId>org.gvsig.lrs.swing</artifactId>
+  <packaging>pom</packaging>
+  <name>${project.artifactId}</name>
+  <modules>
+    <module>org.gvsig.lrs.swing.api</module>
+    <module>org.gvsig.lrs.swing.impl</module>
+  </modules>
+</project>

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/org.gvsig.lrs.swing
___________________________________________________________________
Added: svn:ignore
   + .settings
.classpath

.project


Index: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/pom.xml
===================================================================
--- org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/pom.xml	(revision 0)
+++ org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173/pom.xml	(revision 950)
@@ -0,0 +1,89 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+  <groupId>org.gvsig</groupId>
+  <artifactId>org.gvsig.lrs</artifactId>
+  <version>1.0.173</version>
+  <packaging>pom</packaging>
+  <name>${project.artifactId}</name>
+  <description>Linear Referencing System project</description>
+  <parent>
+    <groupId>org.gvsig</groupId>
+    <artifactId>org.gvsig.desktop</artifactId>
+    <version>2.0.425</version>
+  </parent>
+
+  <url>https://devel.gvsig.org/sites/org.gvsig.lrs/${project.version}</url>
+  <scm>
+    <connection>scm:svn:https://devel.gvsig.org/svn/gvsig-lrs/org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173</connection>
+    <developerConnection>scm:svn:https://devel.gvsig.org/svn/gvsig-lrs/org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173</developerConnection>
+    <url>https://devel.gvsig.org/redmine/projects/gvsig-lrs/repository/show/org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173</url>
+  </scm>
+  <repositories>
+    <repository>
+      <id>gvsig-public-http-repository</id>
+      <name>gvSIG maven public HTTP repository</name>
+      <url>http://devel.gvsig.org/m2repo/j2se</url>
+      <releases>
+        <enabled>true</enabled>
+        <updatePolicy>daily</updatePolicy>
+        <checksumPolicy>warn</checksumPolicy>
+      </releases>
+      <snapshots>
+        <enabled>true</enabled>
+        <updatePolicy>daily</updatePolicy>
+        <checksumPolicy>warn</checksumPolicy>
+      </snapshots>
+    </repository>
+  </repositories>
+
+  <distributionManagement>
+    <site>
+      <id>gvsig-repository</id>
+      <url>dav:https://devel.gvsig.org/download/projects/gvsig-lrs/pool/${project.artifactId}/${project.version}</url>
+    </site>
+  </distributionManagement>
+
+  <build>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-release-plugin</artifactId>
+        <configuration>
+          <tagBase>https://devel.gvsig.org/svn/gvsig-lrs/org.gvsig.lrs/tags</tagBase>
+        </configuration>
+      </plugin>
+    </plugins>
+  </build>
+
+
+
+  <dependencyManagement>
+    <dependencies>
+      <dependency>
+        <groupId>org.gvsig</groupId>
+        <artifactId>org.gvsig.lrs.lib.api</artifactId>
+        <version>1.0.173</version>
+      </dependency>
+      <dependency>
+        <groupId>org.gvsig</groupId>
+        <artifactId>org.gvsig.lrs.lib.impl</artifactId>
+        <version>1.0.173</version>
+      </dependency>
+      <dependency>
+        <groupId>org.gvsig</groupId>
+        <artifactId>org.gvsig.lrs.swing.api</artifactId>
+        <version>1.0.173</version>
+      </dependency>
+      <dependency>
+        <groupId>org.gvsig</groupId>
+        <artifactId>org.gvsig.lrs.swing.impl</artifactId>
+        <version>1.0.173</version>
+      </dependency>
+    </dependencies>
+  </dependencyManagement>
+  <modules>
+    <module>org.gvsig.lrs.lib</module>
+    <module>org.gvsig.lrs.swing</module>
+    <module>org.gvsig.lrs.app</module>
+  </modules>
+</project>
\ No newline at end of file

Property changes on: org.gvsig.lrs/tags/org.gvsig.lrs-1.0.173
___________________________________________________________________
Added: svn:ignore
   + .classpath
.project
.directory
.settings


