sis-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From desruisse...@apache.org
Subject svn commit: r1651061 [2/4] - in /sis/branches/JDK8/storage/sis-shapefile/src/main: java/org/apache/sis/internal/shapefile/ java/org/apache/sis/internal/shapefile/jdbc/ java/org/apache/sis/internal/shapefile/jdbc/connection/ java/org/apache/sis/internal...
Date Mon, 12 Jan 2015 11:14:55 GMT
Modified: sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/CommonByteReader.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/CommonByteReader.java?rev=1651061&r1=1651060&r2=1651061&view=diff
==============================================================================
--- sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/CommonByteReader.java [iso-8859-1] (original)
+++ sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/CommonByteReader.java [UTF-8] Mon Jan 12 11:14:54 2015
@@ -1,132 +1,132 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.sis.internal.shapefile.jdbc;
-
-import java.io.*;
-import java.nio.MappedByteBuffer;
-import java.nio.channels.FileChannel;
-import java.util.Objects;
-import java.util.logging.Level;
-
-import org.apache.sis.internal.shapefile.AutoChecker;
-
-/**
- * Common byte reader.
- * @author  Marc Le Bihan
- * @version 0.5
- * @param <InvalidFormatException> Invalid format Exception to throw in case of trouble.
- * @param <FNFException> File not found Exception to throw in case of missing file.
- * @since   0.5
- * @module
- */
-public abstract class CommonByteReader<InvalidFormatException extends Exception, FNFException extends Exception> extends AutoChecker  implements AutoCloseable  {
-    /** The File. */
-    private File file;
-    
-    /** Input Stream on the DBF. */
-    private FileInputStream fis;
-
-    /** File channel on the file. */
-    private FileChannel fc;
-
-    /** Buffer reader. */
-    private MappedByteBuffer byteBuffer;
-    
-    /** Indicates if the byte buffer is closed. */
-    private boolean isClosed = false;
-
-    /** Invalid Exception to throw in case of invalid file format. */
-    private Class<InvalidFormatException> classInvalidFormatException;
-
-    /** Invalid Exception to throw in case of file not found exception. */
-    private Class<FNFException> classFNFException;
-    
-    /**
-     * Create and open a byte reader based on a file.
-     * @param f File.
-     * @param invalidFormatException Invalid Exception to throw in case of invalid file format.
-     * @param fileNotFoundException Invalid Exception to throw in case of file not found exception.
-     * @throws FNFException if the file cannot be opened.
-     * @throws InvalidFormatException if the file format is invalid.
-     */
-    public CommonByteReader(File f, Class<InvalidFormatException> invalidFormatException, Class<FNFException> fileNotFoundException) throws FNFException, InvalidFormatException {
-        Objects.requireNonNull(f, "The file cannot be null.");
-        classInvalidFormatException = invalidFormatException;
-        classFNFException = fileNotFoundException;
-        
-        file = f;
-        
-        try {
-            fis = new FileInputStream(file);
-        }
-        catch(FileNotFoundException e) {
-            throwException(classInvalidFormatException, e.getMessage(), e);
-            throw new RuntimeException("this place should not be reached.");
-        }
-        
-        fc = fis.getChannel();
-        
-        try {
-            int fsize = (int)fc.size();
-            byteBuffer = fc.map(FileChannel.MapMode.READ_ONLY, 0, fsize);
-        }
-        catch(IOException e) {
-            String message = format(Level.WARNING, "excp.reader_cannot_be_created", file.getAbsolutePath(), e.getMessage());
-            throwException(classFNFException, message, e);
-            throw new RuntimeException("this place should not be reached.");
-        }
-   }
-
-    /**
-     * Close the MappedByteReader.
-     * @throws IOException if the close operation fails.
-     */
-    @Override 
-    public void close() throws IOException {
-        if (fc != null)
-            fc.close();
-
-        if (fis != null)
-            fis.close();
-        
-        isClosed = true;
-    }
-
-    /**
-     * Returns the closed state of this binary reader.
-     * @return true if it is closed.
-     */
-    public boolean isClosed() {
-        return isClosed;
-    }
-
-    /**
-     * Returns the byte buffer.
-     * @return Byte Buffer.
-     */
-    public MappedByteBuffer getByteBuffer() {
-        return byteBuffer;
-    }
-    
-    /**
-     * Return the file mapped.
-     * @return File.
-     */
-    public File getFile() {
-        return file;
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.sis.internal.shapefile.jdbc;
+
+import java.io.*;
+import java.nio.MappedByteBuffer;
+import java.nio.channels.FileChannel;
+import java.util.Objects;
+import java.util.logging.Level;
+
+import org.apache.sis.internal.shapefile.AutoChecker;
+
+/**
+ * Common byte reader.
+ * @author  Marc Le Bihan
+ * @version 0.5
+ * @param <InvalidFormatException> Invalid format Exception to throw in case of trouble.
+ * @param <FNFException> File not found Exception to throw in case of missing file.
+ * @since   0.5
+ * @module
+ */
+public abstract class CommonByteReader<InvalidFormatException extends Exception, FNFException extends Exception> extends AutoChecker  implements AutoCloseable  {
+    /** The File. */
+    private File file;
+
+    /** Input Stream on the DBF. */
+    private FileInputStream fis;
+
+    /** File channel on the file. */
+    private FileChannel fc;
+
+    /** Buffer reader. */
+    private MappedByteBuffer byteBuffer;
+
+    /** Indicates if the byte buffer is closed. */
+    private boolean isClosed = false;
+
+    /** Invalid Exception to throw in case of invalid file format. */
+    private Class<InvalidFormatException> classInvalidFormatException;
+
+    /** Invalid Exception to throw in case of file not found exception. */
+    private Class<FNFException> classFNFException;
+
+    /**
+     * Create and open a byte reader based on a file.
+     * @param f File.
+     * @param invalidFormatException Invalid Exception to throw in case of invalid file format.
+     * @param fileNotFoundException Invalid Exception to throw in case of file not found exception.
+     * @throws FNFException if the file cannot be opened.
+     * @throws InvalidFormatException if the file format is invalid.
+     */
+    public CommonByteReader(File f, Class<InvalidFormatException> invalidFormatException, Class<FNFException> fileNotFoundException) throws FNFException, InvalidFormatException {
+        Objects.requireNonNull(f, "The file cannot be null.");
+        classInvalidFormatException = invalidFormatException;
+        classFNFException = fileNotFoundException;
+
+        file = f;
+
+        try {
+            fis = new FileInputStream(file);
+        }
+        catch(FileNotFoundException e) {
+            throwException(classInvalidFormatException, e.getMessage(), e);
+            throw new RuntimeException("this place should not be reached.");
+        }
+
+        fc = fis.getChannel();
+
+        try {
+            int fsize = (int)fc.size();
+            byteBuffer = fc.map(FileChannel.MapMode.READ_ONLY, 0, fsize);
+        }
+        catch(IOException e) {
+            String message = format(Level.WARNING, "excp.reader_cannot_be_created", file.getAbsolutePath(), e.getMessage());
+            throwException(classFNFException, message, e);
+            throw new RuntimeException("this place should not be reached.");
+        }
+   }
+
+    /**
+     * Close the MappedByteReader.
+     * @throws IOException if the close operation fails.
+     */
+    @Override
+    public void close() throws IOException {
+        if (fc != null)
+            fc.close();
+
+        if (fis != null)
+            fis.close();
+
+        isClosed = true;
+    }
+
+    /**
+     * Returns the closed state of this binary reader.
+     * @return true if it is closed.
+     */
+    public boolean isClosed() {
+        return isClosed;
+    }
+
+    /**
+     * Returns the byte buffer.
+     * @return Byte Buffer.
+     */
+    public MappedByteBuffer getByteBuffer() {
+        return byteBuffer;
+    }
+
+    /**
+     * Return the file mapped.
+     * @return File.
+     */
+    public File getFile() {
+        return file;
+    }
+}

Propchange: sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/CommonByteReader.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/CommonByteReader.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain;charset=UTF-8

Modified: sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/DBFDriver.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/DBFDriver.java?rev=1651061&r1=1651060&r2=1651061&view=diff
==============================================================================
--- sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/DBFDriver.java [UTF-8] (original)
+++ sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/DBFDriver.java [UTF-8] Mon Jan 12 11:14:54 2015
@@ -39,7 +39,7 @@ public class DBFDriver extends AbstractJ
      */
     public DBFDriver() {
     }
-    
+
     /**
      * @see java.sql.Wrapper#isWrapperFor(java.lang.Class)
      */
@@ -72,7 +72,7 @@ public class DBFDriver extends AbstractJ
     public Connection connect(final String url, @SuppressWarnings("unused") Properties info) throws InvalidDbaseFileFormatException, DbaseFileNotFoundException {
         Objects.requireNonNull(url, "the DBase3 url cannot be null");
         File file = new File(url);
-        
+
         return new DBFConnection(file, new MappedByteReader(file));
     }
 
@@ -84,7 +84,7 @@ public class DBFDriver extends AbstractJ
         if (!url.endsWith(".dbf")) {
             return false;
         }
-        
+
         final File datafile = new File(url);
         return datafile.isFile(); // Future version should check for magic number.
     }

Modified: sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/DBase3FieldDescriptor.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/DBase3FieldDescriptor.java?rev=1651061&r1=1651060&r2=1651061&view=diff
==============================================================================
--- sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/DBase3FieldDescriptor.java [UTF-8] (original)
+++ sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/DBase3FieldDescriptor.java [UTF-8] Mon Jan 12 11:14:54 2015
@@ -101,7 +101,7 @@ public class DBase3FieldDescriptor exten
     public int getDecimalCount() {
         return Byte.toUnsignedInt(this.fieldDecimalCount);
     }
-    
+
     /**
      * Returns the field length.
      * @return field length.
@@ -129,7 +129,7 @@ public class DBase3FieldDescriptor exten
     public DBaseDataType getType() {
         return(fieldType);
     }
-    
+
     /**
      * @see java.lang.Object#toString()
      */

Modified: sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/Dbase3ByteReader.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/Dbase3ByteReader.java?rev=1651061&r1=1651060&r2=1651061&view=diff
==============================================================================
--- sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/Dbase3ByteReader.java [iso-8859-1] (original)
+++ sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/Dbase3ByteReader.java [UTF-8] Mon Jan 12 11:14:54 2015
@@ -1,118 +1,118 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.sis.internal.shapefile.jdbc;
-
-import java.io.IOException;
-import java.nio.charset.Charset;
-import java.util.Date;
-import java.util.List;
-import java.util.Map;
-
-import org.apache.sis.internal.shapefile.jdbc.resultset.SQLIllegalColumnIndexException;
-import org.apache.sis.internal.shapefile.jdbc.resultset.SQLNoSuchFieldException;
-import org.opengis.feature.Feature;
-
-/**
- * Database byte reader contract. Used to allow refactoring of core byte management of a DBase file.
- * @author Marc LE BIHAN
- */
-public interface Dbase3ByteReader {
-    /**
-     * Close the MappedByteReader.
-     * @throws IOException if the close operation fails.
-     */
-    public void close() throws IOException;
-
-    /**
-     * Checks if the ByteReader is closed.
-     * @return true if it is closed.
-     */
-    public boolean isClosed();
-    
-    /**
-     * Returns the fields descriptors in their binary format.
-     * @return Fields descriptors.
-     */
-    public List<DBase3FieldDescriptor> getFieldsDescriptors();
-    
-    /**
-     * Returns the column index for the given column name.
-     * The default implementation of all methods expecting a column label will invoke this method.
-     * @param columnLabel The name of the column.
-     * @param sql For information, the SQL statement that is attempted.
-     * @return The index of the given column name : first column is 1.
-     * @throws SQLNoSuchFieldException if there is no field with this name in the query.
-     */
-    public int findColumn(String columnLabel, String sql) throws SQLNoSuchFieldException;
-    
-    /**
-     * Returns the charset.
-     * @return Charset.
-     */
-    public Charset getCharset();
-    
-    /**
-     * Returns the column count of the unique table of the DBase 3.
-     * @return Column count.
-     */
-    public int getColumnCount();
-
-    /**
-     * Return a field name.
-     * @param columnIndex Column index.
-     * @param sql For information, the SQL statement that is attempted.
-     * @return Field Name.
-     * @throws SQLIllegalColumnIndexException if the index is out of bounds.
-     */
-    public String getFieldName(int columnIndex, String sql) throws SQLIllegalColumnIndexException;
-    
-    /**
-     * Returns the database last update date.
-     * @return Date of the last update.
-     */
-    public Date getDateOfLastUpdate();
-    
-    /**
-     * Returns the record count.
-     * @return Record count.
-     */
-    public int getRowCount();
-
-    /**
-     * Returns the current record number.
-     * @return Current record number.
-     */
-    public int getRowNum();
-    
-    /**
-     * Load a row into a feature.
-     * @param feature Feature to fill.
-     */
-    public void loadRowIntoFeature(Feature feature);
-    
-    /**
-     * Checks if a next row is available. Warning : it may be a deleted one.
-     * @return true if a next row is available.
-     */
-    public boolean nextRowAvailable();
-    
-    /**
-     * Read the next row as a set of objects.
-     * @return Map of field name / object value.
-     */
-    public Map<String, Object> readNextRowAsObjects();
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.sis.internal.shapefile.jdbc;
+
+import java.io.IOException;
+import java.nio.charset.Charset;
+import java.util.Date;
+import java.util.List;
+import java.util.Map;
+
+import org.apache.sis.internal.shapefile.jdbc.resultset.SQLIllegalColumnIndexException;
+import org.apache.sis.internal.shapefile.jdbc.resultset.SQLNoSuchFieldException;
+import org.opengis.feature.Feature;
+
+/**
+ * Database byte reader contract. Used to allow refactoring of core byte management of a DBase file.
+ * @author Marc LE BIHAN
+ */
+public interface Dbase3ByteReader {
+    /**
+     * Close the MappedByteReader.
+     * @throws IOException if the close operation fails.
+     */
+    public void close() throws IOException;
+
+    /**
+     * Checks if the ByteReader is closed.
+     * @return true if it is closed.
+     */
+    public boolean isClosed();
+
+    /**
+     * Returns the fields descriptors in their binary format.
+     * @return Fields descriptors.
+     */
+    public List<DBase3FieldDescriptor> getFieldsDescriptors();
+
+    /**
+     * Returns the column index for the given column name.
+     * The default implementation of all methods expecting a column label will invoke this method.
+     * @param columnLabel The name of the column.
+     * @param sql For information, the SQL statement that is attempted.
+     * @return The index of the given column name : first column is 1.
+     * @throws SQLNoSuchFieldException if there is no field with this name in the query.
+     */
+    public int findColumn(String columnLabel, String sql) throws SQLNoSuchFieldException;
+
+    /**
+     * Returns the charset.
+     * @return Charset.
+     */
+    public Charset getCharset();
+
+    /**
+     * Returns the column count of the unique table of the DBase 3.
+     * @return Column count.
+     */
+    public int getColumnCount();
+
+    /**
+     * Return a field name.
+     * @param columnIndex Column index.
+     * @param sql For information, the SQL statement that is attempted.
+     * @return Field Name.
+     * @throws SQLIllegalColumnIndexException if the index is out of bounds.
+     */
+    public String getFieldName(int columnIndex, String sql) throws SQLIllegalColumnIndexException;
+
+    /**
+     * Returns the database last update date.
+     * @return Date of the last update.
+     */
+    public Date getDateOfLastUpdate();
+
+    /**
+     * Returns the record count.
+     * @return Record count.
+     */
+    public int getRowCount();
+
+    /**
+     * Returns the current record number.
+     * @return Current record number.
+     */
+    public int getRowNum();
+
+    /**
+     * Load a row into a feature.
+     * @param feature Feature to fill.
+     */
+    public void loadRowIntoFeature(Feature feature);
+
+    /**
+     * Checks if a next row is available. Warning : it may be a deleted one.
+     * @return true if a next row is available.
+     */
+    public boolean nextRowAvailable();
+
+    /**
+     * Read the next row as a set of objects.
+     * @return Map of field name / object value.
+     */
+    public Map<String, Object> readNextRowAsObjects();
+}

Propchange: sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/Dbase3ByteReader.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/Dbase3ByteReader.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain;charset=UTF-8

Modified: sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/DbaseFileNotFoundException.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/DbaseFileNotFoundException.java?rev=1651061&r1=1651060&r2=1651061&view=diff
==============================================================================
--- sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/DbaseFileNotFoundException.java [iso-8859-1] (original)
+++ sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/DbaseFileNotFoundException.java [UTF-8] Mon Jan 12 11:14:54 2015
@@ -1,50 +1,50 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.sis.internal.shapefile.jdbc;
-
-import java.sql.SQLNonTransientException;
-
-
-/**
- * Thrown when a DBF file has not been found.
- *
- * @author  Marc Le Bihan
- * @version 0.5
- * @since   0.5
- * @module
- */
-public class DbaseFileNotFoundException extends SQLNonTransientException {
-    /** Serial UID. */
-    private static final long serialVersionUID = 2572691456125734352L;
-
-    /**
-     * Construct an exception.
-     * @param message Message of the exception.
-     */
-    public DbaseFileNotFoundException(String message) {
-        super(message);
-    }
-
-    /**
-     * Construct an exception.
-     * @param message Message of the exception.
-     * @param cause Root cause of the exception.
-     */
-    public DbaseFileNotFoundException(String message, Throwable cause) {
-        super(message, cause);
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.sis.internal.shapefile.jdbc;
+
+import java.sql.SQLNonTransientException;
+
+
+/**
+ * Thrown when a DBF file has not been found.
+ *
+ * @author  Marc Le Bihan
+ * @version 0.5
+ * @since   0.5
+ * @module
+ */
+public class DbaseFileNotFoundException extends SQLNonTransientException {
+    /** Serial UID. */
+    private static final long serialVersionUID = 2572691456125734352L;
+
+    /**
+     * Construct an exception.
+     * @param message Message of the exception.
+     */
+    public DbaseFileNotFoundException(String message) {
+        super(message);
+    }
+
+    /**
+     * Construct an exception.
+     * @param message Message of the exception.
+     * @param cause Root cause of the exception.
+     */
+    public DbaseFileNotFoundException(String message, Throwable cause) {
+        super(message, cause);
+    }
+}

Propchange: sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/DbaseFileNotFoundException.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/DbaseFileNotFoundException.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain;charset=UTF-8

Modified: sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/MappedByteReader.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/MappedByteReader.java?rev=1651061&r1=1651060&r2=1651061&view=diff
==============================================================================
--- sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/MappedByteReader.java [iso-8859-1] (original)
+++ sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/MappedByteReader.java [UTF-8] Mon Jan 12 11:14:54 2015
@@ -1,240 +1,240 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.sis.internal.shapefile.jdbc;
-
-import java.io.File;
-import java.nio.BufferUnderflowException;
-import java.nio.ByteOrder;
-import java.util.*;
-import java.util.logging.Level;
-
-import org.apache.sis.internal.shapefile.jdbc.resultset.SQLIllegalColumnIndexException;
-import org.apache.sis.internal.shapefile.jdbc.resultset.SQLNoSuchFieldException;
-import org.opengis.feature.Feature;
-
-
-/**
- * Reader of a Database Binary content by the way of a {@link java.nio.MappedByteBuffer}
- *
- * @author  Marc Le Bihan
- * @version 0.5
- * @since   0.5
- * @module
- */
-public class MappedByteReader extends AbstractDbase3ByteReader implements AutoCloseable {
-    /** List of field descriptors. */
-    private List<DBase3FieldDescriptor> fieldsDescriptors = new ArrayList<>();
-    
-    /**
-     * Construct a mapped byte reader on a file.
-     * @param dbase3File File.
-     * @throws InvalidDbaseFileFormatException if the database seems to be invalid.
-     * @throws DbaseFileNotFoundException if the Dbase file has not been found. 
-     */
-    public MappedByteReader(File dbase3File) throws InvalidDbaseFileFormatException, DbaseFileNotFoundException {
-        super(dbase3File);
-        loadDescriptor();
-    }
-
-    /**
-     * Load a row into a feature.
-     * @param feature Feature to fill.
-     */
-    @Override public void loadRowIntoFeature(Feature feature) {
-        // TODO: ignore deleted records
-        getByteBuffer().get(); // denotes whether deleted or current
-        // read first part of record
-
-        for (DBase3FieldDescriptor fd : fieldsDescriptors) {
-            byte[] data = new byte[fd.getLength()];
-            getByteBuffer().get(data);
-
-            int length = data.length;
-            while (length != 0 && data[length - 1] <= ' ') {
-                length--;
-            }
-
-            String value = new String(data, 0, length);
-            feature.setPropertyValue(fd.getName(), value);
-        }
-
-        rowNum ++;
-    }
-
-    /**
-     * Checks if a next row is available. Warning : it may be a deleted one.
-     * @return true if a next row is available.
-     */
-    @Override 
-    public boolean nextRowAvailable() {
-        return getByteBuffer().hasRemaining();
-    }
-
-    /**
-     * Read the next row as a set of objects.
-     * @return Map of field name / object value.
-     */
-    @Override 
-    public Map<String, Object> readNextRowAsObjects() {
-        // TODO: ignore deleted records
-        byte isDeleted = getByteBuffer().get(); // denotes whether deleted or current
-        // read first part of record
-
-        HashMap<String, Object> fieldsValues = new HashMap<>();
-
-        for (DBase3FieldDescriptor fd : fieldsDescriptors) {
-            byte[] data = new byte[fd.getLength()];
-            getByteBuffer().get(data);
-
-            int length = data.length;
-            while (length != 0 && data[length - 1] <= ' ') {
-                length--;
-            }
-
-            String value = new String(data, 0, length);
-            fieldsValues.put(fd.getName(), value);
-        }
-
-        rowNum ++;
-        return fieldsValues;
-    }
-    
-    /**
-     * Loading the database file content from binary .dbf file.
-     * @throws InvalidDbaseFileFormatException if descriptor is not readable. 
-     */
-    private void loadDescriptor() throws InvalidDbaseFileFormatException {
-        try {
-            this.dbaseVersion = getByteBuffer().get();
-            getByteBuffer().get(this.dbaseLastUpdate);
-    
-            getByteBuffer().order(ByteOrder.LITTLE_ENDIAN);
-            this.rowCount = getByteBuffer().getInt();
-            this.dbaseHeaderBytes = getByteBuffer().getShort();
-            this.dbaseRecordBytes = getByteBuffer().getShort();
-            getByteBuffer().order(ByteOrder.BIG_ENDIAN);
-            
-            getByteBuffer().get(reservedFiller1);
-            this.reservedIncompleteTransaction = getByteBuffer().get();
-            this.reservedEncryptionFlag = getByteBuffer().get();
-            getByteBuffer().get(reservedFreeRecordThread);
-            getByteBuffer().get(reservedMultiUser);
-            reservedMDXFlag = getByteBuffer().get();
-            
-            // Translate code page value to a known charset.
-            this.codePage = getByteBuffer().get();
-            this.charset = toCharset(this.codePage);             
-            
-            getByteBuffer().get(reservedFiller2); 
-    
-            while(getByteBuffer().position() < this.dbaseHeaderBytes - 1) {
-                DBase3FieldDescriptor fd = new DBase3FieldDescriptor(getByteBuffer()); 
-                this.fieldsDescriptors.add(fd);
-                // loop until you hit the 0Dh field terminator
-            }
-            
-            this.descriptorTerminator = getByteBuffer().get();
-
-            // If the last character read after the field descriptor isn't 0x0D, the expected mark has not been found and the DBF is corrupted.
-            if (descriptorTerminator != 0x0D) {
-                String message = format(Level.WARNING, "excp.filedescriptor_problem", getFile().getAbsolutePath(), "Character marking the end of the fields descriptors (0x0D) has not been found.");
-                throw new InvalidDbaseFileFormatException(message);
-            }
-        }
-        catch(BufferUnderflowException e) {
-            // This exception doesn't denote a trouble of file opening because the file has been checked before 
-            // the calling of this private function.
-            // Therefore, an internal structure problem cause maybe a premature End of file or anything else, but the only thing
-            // we can conclude is : we are not before a device trouble, but a file format trouble.
-            String message = format(Level.WARNING, "excp.filedescriptor_problem", getFile().getAbsolutePath(), e.getMessage());
-            throw new InvalidDbaseFileFormatException(message);
-        }
-    }
-    
-    /**
-     * Returns the fields descriptors in their binary format.
-     * @return Fields descriptors.
-     */
-    @Override 
-    public List<DBase3FieldDescriptor> getFieldsDescriptors() {
-        return fieldsDescriptors;
-    }
-
-    /**
-     * Return a field name.
-     * @param columnIndex Column index.
-     * @param sql For information, the SQL statement that is attempted.
-     * @return Field Name.
-     * @throws SQLIllegalColumnIndexException if the index is out of bounds.
-     */
-    @Override 
-    public String getFieldName(int columnIndex, String sql) throws SQLIllegalColumnIndexException {
-        return getField(columnIndex, sql).getName();
-    }
-
-    /**
-     * @see org.apache.sis.internal.shapefile.jdbc.Dbase3ByteReader#getColumnCount()
-     */
-    @Override 
-    public int getColumnCount() {
-        return fieldsDescriptors.size();
-    }
-    
-    /**
-     * Returns the column index for the given column name.
-     * The default implementation of all methods expecting a column label will invoke this method.
-     * @param columnLabel The name of the column.
-     * @param sql For information, the SQL statement that is attempted.
-     * @return The index of the given column name : first column is 1.
-     * @throws SQLNoSuchFieldException if there is no field with this name in the query.
-     */
-    @Override 
-    public int findColumn(String columnLabel, String sql) throws SQLNoSuchFieldException {
-        // If the column name is null, no search is needed.
-        if (columnLabel == null) {
-            String message = format(Level.WARNING, "excp.no_such_column_in_resultset", columnLabel, sql, getFile().getName());
-            throw new SQLNoSuchFieldException(message, sql, getFile(), columnLabel);
-        }
-        
-        // Search the field among the fields descriptors.
-        for(int index=0; index < fieldsDescriptors.size(); index ++) {
-            if (fieldsDescriptors.get(index).getName().equals(columnLabel)) {
-                return index + 1;
-            }
-        }
-
-        // If we are here, we haven't found our field. Throw an exception.
-        String message = format(Level.WARNING, "excp.no_such_column_in_resultset", columnLabel, sql, getFile().getName());
-        throw new SQLNoSuchFieldException(message, sql, getFile(), columnLabel);
-    }
-    
-    /**
-     * Returns the field descriptor of a given ResultSet column index.
-     * @param columnIndex Column index, first column is 1, second is 2, etc.
-     * @param sql For information, the SQL statement that is attempted.
-     * @return Field Descriptor.
-     * @throws SQLIllegalColumnIndexException if the index is out of bounds.
-     */
-    private DBase3FieldDescriptor getField(int columnIndex, String sql) throws SQLIllegalColumnIndexException {
-        if (columnIndex < 1 || columnIndex > getColumnCount()) {
-            String message = format(Level.WARNING, "excp.illegal_column_index", columnIndex, getColumnCount());
-            throw new SQLIllegalColumnIndexException(message, sql, getFile(), columnIndex);
-        }
-        
-        return fieldsDescriptors.get(columnIndex-1);
-    }
-}
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.sis.internal.shapefile.jdbc;
+
+import java.io.File;
+import java.nio.BufferUnderflowException;
+import java.nio.ByteOrder;
+import java.util.*;
+import java.util.logging.Level;
+
+import org.apache.sis.internal.shapefile.jdbc.resultset.SQLIllegalColumnIndexException;
+import org.apache.sis.internal.shapefile.jdbc.resultset.SQLNoSuchFieldException;
+import org.opengis.feature.Feature;
+
+
+/**
+ * Reader of a Database Binary content by the way of a {@link java.nio.MappedByteBuffer}
+ *
+ * @author  Marc Le Bihan
+ * @version 0.5
+ * @since   0.5
+ * @module
+ */
+public class MappedByteReader extends AbstractDbase3ByteReader implements AutoCloseable {
+    /** List of field descriptors. */
+    private List<DBase3FieldDescriptor> fieldsDescriptors = new ArrayList<>();
+
+    /**
+     * Construct a mapped byte reader on a file.
+     * @param dbase3File File.
+     * @throws InvalidDbaseFileFormatException if the database seems to be invalid.
+     * @throws DbaseFileNotFoundException if the Dbase file has not been found.
+     */
+    public MappedByteReader(File dbase3File) throws InvalidDbaseFileFormatException, DbaseFileNotFoundException {
+        super(dbase3File);
+        loadDescriptor();
+    }
+
+    /**
+     * Load a row into a feature.
+     * @param feature Feature to fill.
+     */
+    @Override public void loadRowIntoFeature(Feature feature) {
+        // TODO: ignore deleted records
+        getByteBuffer().get(); // denotes whether deleted or current
+        // read first part of record
+
+        for (DBase3FieldDescriptor fd : fieldsDescriptors) {
+            byte[] data = new byte[fd.getLength()];
+            getByteBuffer().get(data);
+
+            int length = data.length;
+            while (length != 0 && data[length - 1] <= ' ') {
+                length--;
+            }
+
+            String value = new String(data, 0, length);
+            feature.setPropertyValue(fd.getName(), value);
+        }
+
+        rowNum ++;
+    }
+
+    /**
+     * Checks if a next row is available. Warning : it may be a deleted one.
+     * @return true if a next row is available.
+     */
+    @Override
+    public boolean nextRowAvailable() {
+        return getByteBuffer().hasRemaining();
+    }
+
+    /**
+     * Read the next row as a set of objects.
+     * @return Map of field name / object value.
+     */
+    @Override
+    public Map<String, Object> readNextRowAsObjects() {
+        // TODO: ignore deleted records
+        byte isDeleted = getByteBuffer().get(); // denotes whether deleted or current
+        // read first part of record
+
+        HashMap<String, Object> fieldsValues = new HashMap<>();
+
+        for (DBase3FieldDescriptor fd : fieldsDescriptors) {
+            byte[] data = new byte[fd.getLength()];
+            getByteBuffer().get(data);
+
+            int length = data.length;
+            while (length != 0 && data[length - 1] <= ' ') {
+                length--;
+            }
+
+            String value = new String(data, 0, length);
+            fieldsValues.put(fd.getName(), value);
+        }
+
+        rowNum ++;
+        return fieldsValues;
+    }
+
+    /**
+     * Loading the database file content from binary .dbf file.
+     * @throws InvalidDbaseFileFormatException if descriptor is not readable.
+     */
+    private void loadDescriptor() throws InvalidDbaseFileFormatException {
+        try {
+            this.dbaseVersion = getByteBuffer().get();
+            getByteBuffer().get(this.dbaseLastUpdate);
+
+            getByteBuffer().order(ByteOrder.LITTLE_ENDIAN);
+            this.rowCount = getByteBuffer().getInt();
+            this.dbaseHeaderBytes = getByteBuffer().getShort();
+            this.dbaseRecordBytes = getByteBuffer().getShort();
+            getByteBuffer().order(ByteOrder.BIG_ENDIAN);
+
+            getByteBuffer().get(reservedFiller1);
+            this.reservedIncompleteTransaction = getByteBuffer().get();
+            this.reservedEncryptionFlag = getByteBuffer().get();
+            getByteBuffer().get(reservedFreeRecordThread);
+            getByteBuffer().get(reservedMultiUser);
+            reservedMDXFlag = getByteBuffer().get();
+
+            // Translate code page value to a known charset.
+            this.codePage = getByteBuffer().get();
+            this.charset = toCharset(this.codePage);
+
+            getByteBuffer().get(reservedFiller2);
+
+            while(getByteBuffer().position() < this.dbaseHeaderBytes - 1) {
+                DBase3FieldDescriptor fd = new DBase3FieldDescriptor(getByteBuffer());
+                this.fieldsDescriptors.add(fd);
+                // loop until you hit the 0Dh field terminator
+            }
+
+            this.descriptorTerminator = getByteBuffer().get();
+
+            // If the last character read after the field descriptor isn't 0x0D, the expected mark has not been found and the DBF is corrupted.
+            if (descriptorTerminator != 0x0D) {
+                String message = format(Level.WARNING, "excp.filedescriptor_problem", getFile().getAbsolutePath(), "Character marking the end of the fields descriptors (0x0D) has not been found.");
+                throw new InvalidDbaseFileFormatException(message);
+            }
+        }
+        catch(BufferUnderflowException e) {
+            // This exception doesn't denote a trouble of file opening because the file has been checked before
+            // the calling of this private function.
+            // Therefore, an internal structure problem cause maybe a premature End of file or anything else, but the only thing
+            // we can conclude is : we are not before a device trouble, but a file format trouble.
+            String message = format(Level.WARNING, "excp.filedescriptor_problem", getFile().getAbsolutePath(), e.getMessage());
+            throw new InvalidDbaseFileFormatException(message);
+        }
+    }
+
+    /**
+     * Returns the fields descriptors in their binary format.
+     * @return Fields descriptors.
+     */
+    @Override
+    public List<DBase3FieldDescriptor> getFieldsDescriptors() {
+        return fieldsDescriptors;
+    }
+
+    /**
+     * Return a field name.
+     * @param columnIndex Column index.
+     * @param sql For information, the SQL statement that is attempted.
+     * @return Field Name.
+     * @throws SQLIllegalColumnIndexException if the index is out of bounds.
+     */
+    @Override
+    public String getFieldName(int columnIndex, String sql) throws SQLIllegalColumnIndexException {
+        return getField(columnIndex, sql).getName();
+    }
+
+    /**
+     * @see org.apache.sis.internal.shapefile.jdbc.Dbase3ByteReader#getColumnCount()
+     */
+    @Override
+    public int getColumnCount() {
+        return fieldsDescriptors.size();
+    }
+
+    /**
+     * Returns the column index for the given column name.
+     * The default implementation of all methods expecting a column label will invoke this method.
+     * @param columnLabel The name of the column.
+     * @param sql For information, the SQL statement that is attempted.
+     * @return The index of the given column name : first column is 1.
+     * @throws SQLNoSuchFieldException if there is no field with this name in the query.
+     */
+    @Override
+    public int findColumn(String columnLabel, String sql) throws SQLNoSuchFieldException {
+        // If the column name is null, no search is needed.
+        if (columnLabel == null) {
+            String message = format(Level.WARNING, "excp.no_such_column_in_resultset", columnLabel, sql, getFile().getName());
+            throw new SQLNoSuchFieldException(message, sql, getFile(), columnLabel);
+        }
+
+        // Search the field among the fields descriptors.
+        for(int index=0; index < fieldsDescriptors.size(); index ++) {
+            if (fieldsDescriptors.get(index).getName().equals(columnLabel)) {
+                return index + 1;
+            }
+        }
+
+        // If we are here, we haven't found our field. Throw an exception.
+        String message = format(Level.WARNING, "excp.no_such_column_in_resultset", columnLabel, sql, getFile().getName());
+        throw new SQLNoSuchFieldException(message, sql, getFile(), columnLabel);
+    }
+
+    /**
+     * Returns the field descriptor of a given ResultSet column index.
+     * @param columnIndex Column index, first column is 1, second is 2, etc.
+     * @param sql For information, the SQL statement that is attempted.
+     * @return Field Descriptor.
+     * @throws SQLIllegalColumnIndexException if the index is out of bounds.
+     */
+    private DBase3FieldDescriptor getField(int columnIndex, String sql) throws SQLIllegalColumnIndexException {
+        if (columnIndex < 1 || columnIndex > getColumnCount()) {
+            String message = format(Level.WARNING, "excp.illegal_column_index", columnIndex, getColumnCount());
+            throw new SQLIllegalColumnIndexException(message, sql, getFile(), columnIndex);
+        }
+
+        return fieldsDescriptors.get(columnIndex-1);
+    }
+}

Propchange: sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/MappedByteReader.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/MappedByteReader.java
------------------------------------------------------------------------------
    svn:mime-type = text/plain;charset=UTF-8

Modified: sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/SQLConnectionClosedException.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/SQLConnectionClosedException.java?rev=1651061&r1=1651060&r2=1651061&view=diff
==============================================================================
--- sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/SQLConnectionClosedException.java [UTF-8] (original)
+++ sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/SQLConnectionClosedException.java [UTF-8] Mon Jan 12 11:14:54 2015
@@ -29,10 +29,10 @@ public class SQLConnectionClosedExceptio
 
     /** The SQL Statement that whas attempted (if known). */
     private String sql;
-    
+
     /** The database file. */
     private File database;
-    
+
     /**
      * Build the exception.
      * @param message Exception message.
@@ -44,7 +44,7 @@ public class SQLConnectionClosedExceptio
         sql = sqlStatement;
         database = dbf;
     }
-    
+
     /**
      * Returns the SQL statement who encountered the "connection closed" alert, if known.
      * @return SQL statement or null.
@@ -52,7 +52,7 @@ public class SQLConnectionClosedExceptio
     public String getSQL() {
         return sql;
     }
-    
+
     /**
      * Returns the database file that is not opened for connection.
      * @return Database file.

Modified: sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/connection/DBFConnection.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/connection/DBFConnection.java?rev=1651061&r1=1651060&r2=1651061&view=diff
==============================================================================
--- sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/connection/DBFConnection.java [UTF-8] (original)
+++ sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/connection/DBFConnection.java [UTF-8] Mon Jan 12 11:14:54 2015
@@ -40,30 +40,30 @@ import org.apache.sis.internal.shapefile
 public class DBFConnection extends AbstractConnection {
     /** The object to use for reading the database content. */
     final File databaseFile;
-    
+
     /** Opened statement. */
-    private HashSet<DBFStatement> openedStatements = new HashSet<>(); 
-    
+    private HashSet<DBFStatement> openedStatements = new HashSet<>();
+
     /** ByteReader. */
     private Dbase3ByteReader byteReader;
-    
+
     /**
      * Constructs a connection to the given database.
      * @param datafile Data file ({@code .dbf} extension).
      * @param br Byte reader to use for reading binary content.
-     * @throws DbaseFileNotFoundException if the Database file cannot be found or is not a file. 
+     * @throws DbaseFileNotFoundException if the Database file cannot be found or is not a file.
      */
     public DBFConnection(final File datafile, Dbase3ByteReader br) throws DbaseFileNotFoundException {
         // Check that file exists.
         if (!datafile.exists()) {
             throw new DbaseFileNotFoundException(format(Level.WARNING, "excp.file_not_found", datafile.getAbsolutePath()));
         }
-        
+
         // Check that its not a directory.
         if (datafile.isDirectory()) {
             throw new DbaseFileNotFoundException(format(Level.WARNING, "excp.directory_not_expected", datafile.getAbsolutePath()));
         }
-        
+
        databaseFile = datafile;
        byteReader = br;
        format(Level.FINE, "log.database_connection_opened", databaseFile.getAbsolutePath(), "FIXME : column desc.");
@@ -76,14 +76,14 @@ public class DBFConnection extends Abstr
     public void close() {
         if (isClosed())
             return;
-        
+
         try {
             // Check if all the underlying connections that has been opened with this connection has been closed.
             // If not, we log a warning to help the developper.
             if (openedStatements.size() > 0) {
-                format(Level.WARNING, "log.statements_left_opened", openedStatements.size(), openedStatements.stream().map(DBFStatement::toString).collect(Collectors.joining(", ")));  
+                format(Level.WARNING, "log.statements_left_opened", openedStatements.size(), openedStatements.stream().map(DBFStatement::toString).collect(Collectors.joining(", ")));
             }
-            
+
             byteReader.close();
         } catch (IOException e) {
             format(Level.FINE, e.getMessage(), e);
@@ -97,7 +97,7 @@ public class DBFConnection extends Abstr
     @Override
     public Statement createStatement() throws SQLConnectionClosedException {
         assertNotClosed();
-        
+
         DBFStatement stmt = new DBFStatement(this);
         openedStatements.add(stmt);
         return stmt;
@@ -110,7 +110,7 @@ public class DBFConnection extends Abstr
     public String getCatalog() {
         return null; // DBase 3 offers no catalog.
     }
-    
+
     /**
      * Returns the charset.
      * @return Charset.
@@ -127,7 +127,7 @@ public class DBFConnection extends Abstr
     public File getFile() {
         return databaseFile;
     }
-    
+
     /**
      * Returns the JDBC interface implemented by this class.
      * This is used for formatting error messages.
@@ -175,24 +175,24 @@ public class DBFConnection extends Abstr
      * @throws SQLConnectionClosedException if the connection is closed.
      */
     public void assertNotClosed() throws SQLConnectionClosedException {
-        // If closed throw an exception specifying the name if the DBF that is closed. 
+        // If closed throw an exception specifying the name if the DBF that is closed.
         if (isClosed()) {
             throw new SQLConnectionClosedException(format(Level.WARNING, "excp.closed_connection", getFile().getName()), null, getFile());
         }
     }
-    
+
     /**
      * Method called by Statement class to notity this connection that a statement has been closed.
      * @param stmt Statement that has been closed.
      */
     public void notifyCloseStatement(DBFStatement stmt) {
         Objects.requireNonNull(stmt, "The statement notified being closed cannot be null.");
-        
+
         if (openedStatements.remove(stmt) == false) {
             throw new RuntimeException(format(Level.SEVERE, "assert.statement_not_opened_by_me", stmt, toString()));
         }
     }
-    
+
     /**
      * Returns the column index for the given column name.
      * The default implementation of all methods expecting a column label will invoke this method.
@@ -223,15 +223,15 @@ public class DBFConnection extends Abstr
      */
     public ResultSet getFieldDesc(String columnLabel, String sql) throws SQLConnectionClosedException, SQLNoSuchFieldException {
         Objects.requireNonNull(columnLabel, "The column name cannot be null.");
-        
+
         DBFBuiltInMemoryResultSetForColumnsListing rs = (DBFBuiltInMemoryResultSetForColumnsListing)((DBFDatabaseMetaData)getMetaData()).getColumns(null, null, null, null);
-        
+
         try {
             while(rs.next()) {
                 try {
                     if (rs.getString("COLUMN_NAME").equalsIgnoreCase(columnLabel)) {
                         return rs;
-                    } 
+                    }
                 }
                 catch(SQLNoSuchFieldException e) {
                     // if it is the COLUMN_NAME column that has not been found in the desc ResultSet, we have an internal error.
@@ -245,7 +245,7 @@ public class DBFConnection extends Abstr
             rs.close();
             throw new RuntimeException(e.getMessage(), e);
         }
-        
+
         // But if we are here, we have not found the column with this name, and we have to throw an SQLNoSuchFieldException exception ourselves.
         String message = format("excp.no_such_column_in_resultset", columnLabel, sql, getFile().getName());
         throw new SQLNoSuchFieldException(message, sql, getFile(), columnLabel);
@@ -261,13 +261,13 @@ public class DBFConnection extends Abstr
      */
     public ResultSet getFieldDesc(int column, String sql) throws SQLConnectionClosedException, SQLIllegalColumnIndexException {
         DBFBuiltInMemoryResultSetForColumnsListing rs = (DBFBuiltInMemoryResultSetForColumnsListing)((DBFDatabaseMetaData)getMetaData()).getColumns(null, null, null, null);
-        
+
         if (column <= 0 || column > getColumnCount()) {
             rs.close();
             String message = format("excp.illegal_column_index_metadata", column, getColumnCount());
             throw new SQLIllegalColumnIndexException(message, sql, getFile(), column);
         }
-        
+
         // TODO Implements ResultSet:absolute(int) instead.
         for(int index=1; index <= column; index ++) {
             try {
@@ -279,10 +279,10 @@ public class DBFConnection extends Abstr
                 throw new RuntimeException(e.getMessage(), e);
             }
         }
-        
+
         return rs;
     }
-    
+
     /**
      * Returns the fields descriptors in their binary format.
      * @return Fields descriptors.
@@ -307,7 +307,7 @@ public class DBFConnection extends Abstr
      * @return true if a next row is available.
      */
     public boolean nextRowAvailable() {
-        return byteReader.nextRowAvailable();        
+        return byteReader.nextRowAvailable();
     }
 
     /**
@@ -317,7 +317,7 @@ public class DBFConnection extends Abstr
     public Map<String, Object> readNextRowAsObjects() {
         return byteReader.readNextRowAsObjects();
     }
-    
+
     /**
      * @see java.lang.Object#toString()
      */

Modified: sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/connection/SQLClosingIOFailureException.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/connection/SQLClosingIOFailureException.java?rev=1651061&r1=1651060&r2=1651061&view=diff
==============================================================================
--- sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/connection/SQLClosingIOFailureException.java [UTF-8] (original)
+++ sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/connection/SQLClosingIOFailureException.java [UTF-8] Mon Jan 12 11:14:54 2015
@@ -29,10 +29,10 @@ public class SQLClosingIOFailureExceptio
 
     /** The SQL Statement that whas attempted (if known). */
     private String sql;
-    
+
     /** The database file. */
     private File database;
-    
+
     /**
      * Build the exception.
      * @param message Exception message.
@@ -44,7 +44,7 @@ public class SQLClosingIOFailureExceptio
         sql = sqlStatement;
         database = dbf;
     }
-    
+
     /**
      * Returns the SQL statement who encountered the "connection closed" alert, if known.
      * @return SQL statement or null.
@@ -52,7 +52,7 @@ public class SQLClosingIOFailureExceptio
     public String getSQL() {
         return sql;
     }
-    
+
     /**
      * Returns the database file that is not opened for connection.
      * @return Database file.

Modified: sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/connection/package-info.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/connection/package-info.java?rev=1651061&r1=1651060&r2=1651061&view=diff
==============================================================================
--- sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/connection/package-info.java [UTF-8] (original)
+++ sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/connection/package-info.java [UTF-8] Mon Jan 12 11:14:54 2015
@@ -16,4 +16,4 @@
  */
 
 /** Connections */
-package org.apache.sis.internal.shapefile.jdbc.connection;
\ No newline at end of file
+package org.apache.sis.internal.shapefile.jdbc.connection;

Modified: sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/metadata/AbstractDatabaseMetaData.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/metadata/AbstractDatabaseMetaData.java?rev=1651061&r1=1651060&r2=1651061&view=diff
==============================================================================
--- sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/metadata/AbstractDatabaseMetaData.java [UTF-8] (original)
+++ sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/metadata/AbstractDatabaseMetaData.java [UTF-8] Mon Jan 12 11:14:54 2015
@@ -15,7 +15,7 @@ public abstract class AbstractDatabaseMe
     @Override public ResultSet getAttributes(String catalog, String schemaPattern, String typeNamePattern, String attributeNamePattern) throws SQLException {
         throw unsupportedOperation("getAttributes", catalog, schemaPattern, typeNamePattern, attributeNamePattern);
     }
-    
+
     /**
      * @see java.sql.DatabaseMetaData#getBestRowIdentifier(java.lang.String, java.lang.String, java.lang.String, int, boolean)
      */
@@ -183,5 +183,4 @@ public abstract class AbstractDatabaseMe
     @Override public <T> T unwrap(Class<T> iface) throws SQLFeatureNotSupportedException {
         throw unsupportedOperation("unwrap", iface);
     }
-
 }

Modified: sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/metadata/DBFDatabaseMetaData.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/metadata/DBFDatabaseMetaData.java?rev=1651061&r1=1651060&r2=1651061&view=diff
==============================================================================
--- sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/metadata/DBFDatabaseMetaData.java [UTF-8] (original)
+++ sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/metadata/DBFDatabaseMetaData.java [UTF-8] Mon Jan 12 11:14:54 2015
@@ -33,7 +33,7 @@ import org.apache.sis.internal.shapefile
 public class DBFDatabaseMetaData extends AbstractDatabaseMetaData {
     /** Connection. */
     private DBFConnection connection;
-    
+
     /**
      * Construct a database Metadata.
      * @param cnt Connection.
@@ -69,9 +69,9 @@ public class DBFDatabaseMetaData extends
 
     /**
      * @see java.sql.DatabaseMetaData#getColumns(java.lang.String, java.lang.String, java.lang.String, java.lang.String)
-     * @throws SQLConnectionClosedException if the connection is closed. 
+     * @throws SQLConnectionClosedException if the connection is closed.
      */
-    @Override 
+    @Override
     public ResultSet getColumns(@SuppressWarnings("unused") String catalog, @SuppressWarnings("unused") String schemaPattern, @SuppressWarnings("unused") String tableNamePattern, @SuppressWarnings("unused") String columnNamePattern) throws SQLConnectionClosedException {
         try(DBFStatement stmt = (DBFStatement)connection.createStatement()) {
             return new DBFBuiltInMemoryResultSetForColumnsListing(stmt, connection.getFieldsDescriptors());
@@ -82,7 +82,7 @@ public class DBFDatabaseMetaData extends
      * Returns the Database File.
      * @return Database File.
      */
-    @Override 
+    @Override
     public File getFile() {
         return connection.getFile();
     }
@@ -469,7 +469,7 @@ public class DBFDatabaseMetaData extends
         logStep("supportsMinimumSQLGrammar");
         return false; // Check what is the ODBC SQL minimum grammar.
     }
-    
+
     /**
      * @see java.sql.DatabaseMetaData#supportsCoreSQLGrammar()
      */
@@ -573,7 +573,7 @@ public class DBFDatabaseMetaData extends
         logStep("isCatalogAtStart");
         return false;
     }
-    
+
     /**
      * @see java.sql.DatabaseMetaData#getCatalogSeparator()
      */
@@ -1009,7 +1009,7 @@ public class DBFDatabaseMetaData extends
     /**
      * @see java.sql.DatabaseMetaData#getTables(java.lang.String, java.lang.String, java.lang.String, java.lang.String[])
      */
-    @SuppressWarnings("resource") // The statement will be closed by the caller. 
+    @SuppressWarnings("resource") // The statement will be closed by the caller.
     @Override public ResultSet getTables(String catalog, String schemaPattern, String tableNamePattern, String[] types) {
         logStep("getTables", catalog, schemaPattern, tableNamePattern, types != null ? Arrays.asList(types) : null);
 
@@ -1022,7 +1022,7 @@ public class DBFDatabaseMetaData extends
     /**
      * @see java.sql.DatabaseMetaData#getSchemas()
      */
-    @SuppressWarnings("resource") // The statement will be closed by the caller. 
+    @SuppressWarnings("resource") // The statement will be closed by the caller.
     @Override public ResultSet getSchemas() {
         logStep("getSchemas");
 
@@ -1035,7 +1035,7 @@ public class DBFDatabaseMetaData extends
     /**
      * @see java.sql.DatabaseMetaData#getCatalogs()
      */
-    @SuppressWarnings("resource") // The statement will be closed by the caller. 
+    @SuppressWarnings("resource") // The statement will be closed by the caller.
     @Override public ResultSet getCatalogs() {
         logStep("getCatalogs");
 
@@ -1048,7 +1048,7 @@ public class DBFDatabaseMetaData extends
     /**
      * @see java.sql.DatabaseMetaData#getTableTypes()
      */
-    @SuppressWarnings("resource") // The statement will be closed by the caller. 
+    @SuppressWarnings("resource") // The statement will be closed by the caller.
     @Override public ResultSet getTableTypes() {
         logStep("getTableTypes");
 
@@ -1069,7 +1069,7 @@ public class DBFDatabaseMetaData extends
             case ResultSet.FETCH_UNKNOWN:
             case ResultSet.TYPE_FORWARD_ONLY:
             return true;
-            
+
             default :
                 return false;
         }

Modified: sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/metadata/DBFResultSetMataData.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/metadata/DBFResultSetMataData.java?rev=1651061&r1=1651060&r2=1651061&view=diff
==============================================================================
--- sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/metadata/DBFResultSetMataData.java [UTF-8] (original)
+++ sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/metadata/DBFResultSetMataData.java [UTF-8] Mon Jan 12 11:14:54 2015
@@ -36,10 +36,10 @@ import org.apache.sis.internal.shapefile
 public class DBFResultSetMataData extends AbstractJDBC implements ResultSetMetaData {
     /** ResultSet. */
     private DBFRecordBasedResultSet rs;
-    
+
     /** Database metadata. */
     private DBFDatabaseMetaData metadata;
-    
+
     /**
      * Construct a ResultSetMetaData.
      * @param resultset ResultSet.
@@ -47,7 +47,7 @@ public class DBFResultSetMataData extend
     public DBFResultSetMataData(DBFRecordBasedResultSet resultset) {
         Objects.requireNonNull(resultset, "A non null ResultSet is required.");
         rs = resultset;
-        
+
         try {
             metadata = (DBFDatabaseMetaData)resultset.getStatement().getConnection().getMetaData();
         }
@@ -55,7 +55,7 @@ public class DBFResultSetMataData extend
             throw new RuntimeException(e.getMessage(), e);
         }
     }
-    
+
     /**
      * @see java.sql.Wrapper#unwrap(java.lang.Class)
      */
@@ -74,19 +74,19 @@ public class DBFResultSetMataData extend
 
     /**
      * @see java.sql.ResultSetMetaData#getColumnCount()
-     * @throws SQLConnectionClosedException if the connection is closed. 
+     * @throws SQLConnectionClosedException if the connection is closed.
      */
-    @SuppressWarnings("resource") // The current connection is only used and has not to be closed. 
+    @SuppressWarnings("resource") // The current connection is only used and has not to be closed.
     @Override public int getColumnCount() throws SQLConnectionClosedException {
         logStep("getColumnCount");
         DBFConnection cnt = (DBFConnection)(((DBFStatement)rs.getStatement()).getConnection());
-        
+
         return cnt.getColumnCount();
     }
 
     /**
      * @see java.sql.ResultSetMetaData#isAutoIncrement(int)
-     * @throws SQLIllegalColumnIndexException if the column index is illegal. 
+     * @throws SQLIllegalColumnIndexException if the column index is illegal.
      * @throws SQLConnectionClosedException if the connection is closed.
      */
     @Override public boolean isAutoIncrement(int column) throws SQLIllegalColumnIndexException, SQLConnectionClosedException {
@@ -120,7 +120,7 @@ public class DBFResultSetMataData extend
 
     /**
      * @see java.sql.ResultSetMetaData#isCurrency(int)
-     * @throws SQLIllegalColumnIndexException if the column index is illegal. 
+     * @throws SQLIllegalColumnIndexException if the column index is illegal.
      * @throws SQLConnectionClosedException if the connection is closed.
      */
     @Override public boolean isCurrency(int column) throws SQLIllegalColumnIndexException, SQLConnectionClosedException {
@@ -153,31 +153,31 @@ public class DBFResultSetMataData extend
 
     /**
      * @see java.sql.ResultSetMetaData#getColumnDisplaySize(int)
-     * @throws SQLIllegalColumnIndexException if the column index is illegal. 
+     * @throws SQLIllegalColumnIndexException if the column index is illegal.
      * @throws SQLConnectionClosedException if the connection is closed.
      */
     @Override public int getColumnDisplaySize(int column) throws SQLIllegalColumnIndexException, SQLConnectionClosedException {
         logStep("getColumnDisplaySize", column);
-        
+
         try(DBFBuiltInMemoryResultSetForColumnsListing rsDatabase = desc(column)) {
             switch(rsDatabase.getString("TYPE_NAME")) {
                 case "AUTO_INCREMENT":
                 case "CHAR":
                 case "INTEGER":
                    return rsDatabase.getInt("COLUMN_SIZE");
-                    
+
                 case "DATE":
                     return 8;
-                    
+
                 // Add decimal separator for decimal numbers.
                 case "DOUBLE":
                 case "FLOAT":
                 case "DECIMAL":
                     return rsDatabase.getInt("COLUMN_SIZE") + 1;
-                    
+
                 case "BOOLEAN":
                     return 5; // Translation for true, false, null.
-    
+
                 // Unhandled types default to field length.
                 case "CURRENCY":
                 case "DATETIME":
@@ -188,7 +188,7 @@ public class DBFResultSetMataData extend
                 case "VARIANT":
                 case "UNKNOWN":
                     return rsDatabase.getInt("COLUMN_SIZE");
-                    
+
                 default:
                     return rsDatabase.getInt("COLUMN_SIZE");
             }
@@ -201,12 +201,12 @@ public class DBFResultSetMataData extend
 
     /**
      * @see java.sql.ResultSetMetaData#getColumnLabel(int)
-     * @throws SQLIllegalColumnIndexException if the column index is illegal. 
+     * @throws SQLIllegalColumnIndexException if the column index is illegal.
      * @throws SQLConnectionClosedException if the connection is closed.
      */
     @Override public String getColumnLabel(int column) throws SQLIllegalColumnIndexException, SQLConnectionClosedException {
         logStep("getColumnLabel", column);
-        
+
         try(DBFBuiltInMemoryResultSetForColumnsListing rsDatabase = desc(column)) {
             return rsDatabase.getString("COLUMN_NAME");
         }
@@ -218,12 +218,12 @@ public class DBFResultSetMataData extend
 
     /**
      * @see java.sql.ResultSetMetaData#getColumnName(int)
-     * @throws SQLIllegalColumnIndexException if the column index is illegal. 
+     * @throws SQLIllegalColumnIndexException if the column index is illegal.
      * @throws SQLConnectionClosedException if the connection is closed.
      */
     @Override public String getColumnName(int column) throws SQLIllegalColumnIndexException, SQLConnectionClosedException {
         logStep("getColumnName", column);
-        
+
         try(DBFBuiltInMemoryResultSetForColumnsListing rsDatabase = desc(column)) {
             return rsDatabase.getString("COLUMN_NAME");
         }
@@ -243,12 +243,12 @@ public class DBFResultSetMataData extend
 
     /**
      * @see java.sql.ResultSetMetaData#getPrecision(int)
-     * @throws SQLIllegalColumnIndexException if the column index is illegal. 
+     * @throws SQLIllegalColumnIndexException if the column index is illegal.
      * @throws SQLConnectionClosedException if the connection is closed.
      */
     @Override public int getPrecision(int column) throws SQLIllegalColumnIndexException, SQLConnectionClosedException {
         logStep("getPrecision", column);
-        
+
         try(DBFBuiltInMemoryResultSetForColumnsListing rsDatabase = desc(column)) {
             return rsDatabase.getInt("COLUMN_SIZE");
         }
@@ -260,12 +260,12 @@ public class DBFResultSetMataData extend
 
     /**
      * @see java.sql.ResultSetMetaData#getScale(int)
-     * @throws SQLIllegalColumnIndexException if the column index is illegal. 
+     * @throws SQLIllegalColumnIndexException if the column index is illegal.
      * @throws SQLConnectionClosedException if the connection is closed.
      */
     @Override public int getScale(int column) throws SQLIllegalColumnIndexException, SQLConnectionClosedException {
         logStep("getScale", column);
-        
+
         try(DBFBuiltInMemoryResultSetForColumnsListing rsDatabase = desc(column)) {
             return rsDatabase.getInt("DECIMAL_DIGITS");
         }
@@ -282,10 +282,10 @@ public class DBFResultSetMataData extend
         logStep("getTableName", column);
 
         // The table default to the file name (without its extension .dbf).
-        String fileName = rs.getFile().getName(); 
+        String fileName = rs.getFile().getName();
         int indexDBF = fileName.lastIndexOf(".");
         String tableName = fileName.substring(0, indexDBF);
-        
+
         return tableName;
     }
 
@@ -299,11 +299,11 @@ public class DBFResultSetMataData extend
 
     /**
      * @see java.sql.ResultSetMetaData#getColumnType(int)
-     * @throws SQLIllegalColumnIndexException if the column index is illegal. 
+     * @throws SQLIllegalColumnIndexException if the column index is illegal.
      */
     @Override public int getColumnType(int column) throws SQLIllegalColumnIndexException, SQLConnectionClosedException {
         logStep("getColumnType", column);
-        
+
         try(DBFBuiltInMemoryResultSetForColumnsListing rsDatabase = desc(column)) {
             return rsDatabase.getInt("DATA_TYPE");
         }
@@ -315,12 +315,12 @@ public class DBFResultSetMataData extend
 
     /**
      * @see java.sql.ResultSetMetaData#getColumnTypeName(int)
-     * @throws SQLIllegalColumnIndexException if the column index is illegal. 
+     * @throws SQLIllegalColumnIndexException if the column index is illegal.
      * @throws SQLConnectionClosedException if the connection is closed.
      */
     @Override public String getColumnTypeName(int column) throws SQLIllegalColumnIndexException, SQLConnectionClosedException {
         logStep("getColumnTypeName", column);
-        
+
         try(DBFBuiltInMemoryResultSetForColumnsListing rsDatabase = desc(column)) {
             return rsDatabase.getString("TYPE_NAME");
         }
@@ -356,8 +356,8 @@ public class DBFResultSetMataData extend
 
     /**
      * @see java.sql.ResultSetMetaData#getColumnClassName(int)
-     * @throws SQLFeatureNotSupportedException if underlying class implementing a type isn't currently set. 
-     * @throws SQLIllegalColumnIndexException if the column index is illegal. 
+     * @throws SQLFeatureNotSupportedException if underlying class implementing a type isn't currently set.
+     * @throws SQLIllegalColumnIndexException if the column index is illegal.
      * @throws SQLConnectionClosedException if the connection is closed.
      */
     @Override public String getColumnClassName(int column) throws SQLFeatureNotSupportedException, SQLIllegalColumnIndexException, SQLConnectionClosedException {
@@ -367,52 +367,52 @@ public class DBFResultSetMataData extend
             switch(rsDatabase.getString("TYPE_NAME")) {
                 case "AUTO_INCREMENT":
                     return Integer.class.getName();
-                    
+
                 case "CHAR":
                     return String.class.getName();
-                    
+
                 case "INTEGER":
                    return Integer.class.getName();
-                    
+
                 case "DATE":
                     return java.sql.Date.class.getName();
-                    
+
                 case "DOUBLE":
                     return Double.class.getName();
-                    
+
                 case "FLOAT":
                     return Float.class.getName();
-                    
+
                 case "DECIMAL":
                     return Double.class.getName();
-                    
+
                 case "BOOLEAN":
                     return Boolean.class.getName();
-        
+
                 case "CURRENCY":
                     return Double.class.getName();
-                    
+
                 case "DATETIME":
                     throw unsupportedOperation("ResultSetMetaData.getColumnClassName(..) on DateTime");
-                    
+
                 case "TIMESTAMP":
                     throw unsupportedOperation("ResultSetMetaData.getColumnClassName(..) on TimeStamp");
-                    
+
                 case "MEMO":
                     throw unsupportedOperation("ResultSetMetaData.getColumnClassName(..) on Memo");
-                    
+
                 case "PICTURE":
                     throw unsupportedOperation("ResultSetMetaData.getColumnClassName(..) on Picture");
-                    
+
                 case "VARIFIELD":
                     throw unsupportedOperation("ResultSetMetaData.getColumnClassName(..) on VariField");
-                    
+
                 case "VARIANT":
                     throw unsupportedOperation("ResultSetMetaData.getColumnClassName(..) on Variant");
-                    
+
                 case "UNKNOWN":
                     throw unsupportedOperation("ResultSetMetaData.getColumnClassName(..) on " + rsDatabase.getString("TYPE_NAME"));
-                    
+
                 default:
                     throw unsupportedOperation("ResultSetMetaData.getColumnClassName(..) on " + rsDatabase.getString("TYPE_NAME"));
             }
@@ -428,9 +428,9 @@ public class DBFResultSetMataData extend
      * @see org.apache.sis.internal.shapefile.jdbc.AbstractJDBC#getInterface()
      */
     @Override protected Class<?> getInterface() {
-        return ResultSetMetaData.class; 
+        return ResultSetMetaData.class;
     }
-    
+
     /**
      * @see org.apache.sis.internal.shapefile.jdbc.AbstractJDBC#getFile()
      */
@@ -438,7 +438,7 @@ public class DBFResultSetMataData extend
     protected File getFile() {
         return rs.getFile();
     }
-    
+
     /**
      * Returns a ResultSet set on the wished column.
      * @param column Column.
@@ -448,13 +448,13 @@ public class DBFResultSetMataData extend
      */
     private DBFBuiltInMemoryResultSetForColumnsListing desc(int column) throws SQLIllegalColumnIndexException, SQLConnectionClosedException {
         DBFBuiltInMemoryResultSetForColumnsListing rsDatabase = (DBFBuiltInMemoryResultSetForColumnsListing)metadata.getColumns(null, null, null, null);
-        
+
         if (column > getColumnCount()) {
             rsDatabase.close();
             String message = format(Level.WARNING, "excp.illegal_column_index_metadata", column, getColumnCount());
             throw new SQLIllegalColumnIndexException(message, rs.getSQL(), getFile(), column);
         }
-        
+
         // TODO Implements ResultSet:absolute(int) instead.
         for(int index=1; index <= column; index ++) {
             try {
@@ -467,7 +467,7 @@ public class DBFResultSetMataData extend
                 throw new RuntimeException(message, e);
             }
         }
-        
+
         return rsDatabase;
     }
 }

Modified: sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/package-info.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/package-info.java?rev=1651061&r1=1651060&r2=1651061&view=diff
==============================================================================
--- sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/package-info.java [UTF-8] (original)
+++ sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/package-info.java [UTF-8] Mon Jan 12 11:14:54 2015
@@ -17,7 +17,7 @@
 
 /**
  * Allows access to the DBase3 part of a shapefile through JDBC driver.
- * Many exceptions are declared inside this package, to help trouble descriptions and permit precise unit tests. 
+ * Many exceptions are declared inside this package, to help trouble descriptions and permit precise unit tests.
  * @author  Marc Le Bihan
  * @version 0.5
  * @since   0.5

Modified: sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/resultset/AbstractResultSet.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/resultset/AbstractResultSet.java?rev=1651061&r1=1651060&r2=1651061&view=diff
==============================================================================
--- sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/resultset/AbstractResultSet.java [UTF-8] (original)
+++ sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/resultset/AbstractResultSet.java [UTF-8] Mon Jan 12 11:14:54 2015
@@ -62,11 +62,11 @@ import org.apache.sis.internal.shapefile
  * @module
  */
 public abstract class AbstractResultSet extends AbstractJDBC implements ResultSet {
-    /* 
+    /*
      * Note to developpers : this class only offers methods that return unsupported exceptions : methods that are not implemented anywhere.
      * if any implementation is done, even a redirection to another class or method, please move the implementation on the next subclass.
      */
-    
+
     /**
      * Constructs a new {@code ResultSet} instance.
      */

Modified: sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/resultset/BuiltInMemoryResultSet.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/resultset/BuiltInMemoryResultSet.java?rev=1651061&r1=1651060&r2=1651061&view=diff
==============================================================================
--- sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/resultset/BuiltInMemoryResultSet.java [UTF-8] (original)
+++ sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/resultset/BuiltInMemoryResultSet.java [UTF-8] Mon Jan 12 11:14:54 2015
@@ -25,7 +25,7 @@ import org.apache.sis.internal.shapefile
 
 
 /**
- * This Base ResultSet is only used for Descriptions function (getTables(..) and others functions in in Metadata). 
+ * This Base ResultSet is only used for Descriptions function (getTables(..) and others functions in in Metadata).
  * @author  Marc Le Bihan
  * @version 0.5
  * @since   0.5
@@ -45,7 +45,7 @@ public abstract class BuiltInMemoryResul
      * @see java.sql.ResultSet#getBigDecimal(java.lang.String, int)
      * @deprecated Deprecated API (from ResultSet Interface)
      */
-    @Deprecated @Override 
+    @Deprecated @Override
     public BigDecimal getBigDecimal(String columnLabel, int scale) throws SQLException {
         throw unsupportedOperation("BigDecimal", columnLabel, scale);
     }
@@ -85,7 +85,7 @@ public abstract class BuiltInMemoryResul
     /**
      * @see java.sql.ResultSet#getDouble(java.lang.String)
      */
-    @Override 
+    @Override
     public double getDouble(String columnLabel) throws SQLException {
         throw unsupportedOperation("getDouble", columnLabel);
     }
@@ -109,7 +109,7 @@ public abstract class BuiltInMemoryResul
     /**
      * @see java.sql.ResultSet#getFloat(java.lang.String)
      */
-    @Override 
+    @Override
     public float getFloat(String columnLabel) throws SQLException {
         throw unsupportedOperation("getFloat", columnLabel);
     }
@@ -117,7 +117,7 @@ public abstract class BuiltInMemoryResul
     /**
      * @see java.sql.ResultSet#getInt(java.lang.String)
      */
-    @Override 
+    @Override
     public int getInt(String columnLabel) throws SQLException {
         throw unsupportedOperation("getInt", columnLabel);
     }
@@ -165,7 +165,7 @@ public abstract class BuiltInMemoryResul
     @Override public String getString(String columnLabel) throws SQLException {
         throw unsupportedOperation("getString", columnLabel);
     }
-    
+
     /**
      * @see java.sql.ResultSet#getString(int)
      */
@@ -180,17 +180,17 @@ public abstract class BuiltInMemoryResul
     @Override public ResultSetMetaData getMetaData() throws SQLException {
         throw unsupportedOperation("getMetaData");
     }
-    
+
     /**
      * Returns the table name.
      * @return Table Name.
      */
     protected String getTableName() {
         // The table default to the file name (without its extension .dbf).
-        String fileName = getFile().getName(); 
+        String fileName = getFile().getName();
         int indexDBF = fileName.lastIndexOf(".");
         String tableName = fileName.substring(0, indexDBF);
-        
+
         return tableName;
     }
 }

Modified: sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/resultset/DBFBuiltInMemoryResultSetForCatalogNamesListing.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/resultset/DBFBuiltInMemoryResultSetForCatalogNamesListing.java?rev=1651061&r1=1651060&r2=1651061&view=diff
==============================================================================
--- sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/resultset/DBFBuiltInMemoryResultSetForCatalogNamesListing.java [UTF-8] (original)
+++ sis/branches/JDK8/storage/sis-shapefile/src/main/java/org/apache/sis/internal/shapefile/jdbc/resultset/DBFBuiltInMemoryResultSetForCatalogNamesListing.java [UTF-8] Mon Jan 12 11:14:54 2015
@@ -49,4 +49,3 @@ public class DBFBuiltInMemoryResultSetFo
         return true;
     }
 }
-



Mime
View raw message