From 58a06e5db74e6ddc0e7a7f9edeac595134654a08 Mon Sep 17 00:00:00 2001 From: gmantele <gmantele@ari.uni-heidelberg.de> Date: Wed, 23 Jul 2014 15:38:03 +0200 Subject: [PATCH] [TAP] Fix detection type problem on upload (=all types were considered as varchar) --- src/tap/metadata/VotType.java | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/tap/metadata/VotType.java b/src/tap/metadata/VotType.java index 27daede..3d12e92 100644 --- a/src/tap/metadata/VotType.java +++ b/src/tap/metadata/VotType.java @@ -16,7 +16,8 @@ package tap.metadata; * You should have received a copy of the GNU Lesser General Public License * along with TAPLibrary. If not, see <http://www.gnu.org/licenses/>. * - * Copyright 2012 - UDS/Centre de DonnĂ©es astronomiques de Strasbourg (CDS) + * Copyright 2012,2014 - UDS/Centre de DonnĂ©es astronomiques de Strasbourg (CDS), + * Astronomisches Rechen Institute (ARI) */ import cds.savot.writer.SavotWriter; @@ -29,8 +30,8 @@ import cds.savot.writer.SavotWriter; * <li><code>xtype</code>.</li> * </ul> * - * @author Grégory Mantelet (CDS) - * @version 11/2011 + * @author Grégory Mantelet (CDS;ARI) + * @version 07/2014 */ public final class VotType { public final String datatype; @@ -48,7 +49,7 @@ public final class VotType { throw new NullPointerException("Null VOTable datatype !"); this.datatype = datatype; this.arraysize = arraysize; - this.xtype = xtype; + this.xtype = (xtype != null && xtype.trim().length() <= 0) ? null : xtype; } @Override -- GitLab