sis-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From desruisse...@apache.org
Subject svn commit: r1615133 - in /sis/branches/JDK7: ./ core/sis-metadata/src/main/java/org/apache/sis/metadata/iso/identification/ core/sis-referencing/src/test/java/org/apache/sis/test/integration/ core/sis-utility/src/test/java/org/apache/sis/xml/ storage/...
Date Fri, 01 Aug 2014 15:10:04 GMT
Author: desruisseaux
Date: Fri Aug  1 15:10:03 2014
New Revision: 1615133

URL: http://svn.apache.org/r1615133
Log:
Merge from the JDK8 branch.

Modified:
    sis/branches/JDK7/   (props changed)
    sis/branches/JDK7/core/sis-metadata/src/main/java/org/apache/sis/metadata/iso/identification/DefaultAggregateInformation.java
    sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/test/integration/DefaultMetadataTest.java
    sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/test/integration/ReferencingInMetadataTest.java
    sis/branches/JDK7/core/sis-utility/src/test/java/org/apache/sis/xml/ValueConverterTest.java
    sis/branches/JDK7/storage/sis-storage/src/test/java/org/apache/sis/internal/storage/xml/XMLStoreTest.java

Propchange: sis/branches/JDK7/
------------------------------------------------------------------------------
  Merged /sis/branches/JDK8:r1615099-1615131

Modified: sis/branches/JDK7/core/sis-metadata/src/main/java/org/apache/sis/metadata/iso/identification/DefaultAggregateInformation.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK7/core/sis-metadata/src/main/java/org/apache/sis/metadata/iso/identification/DefaultAggregateInformation.java?rev=1615133&r1=1615132&r2=1615133&view=diff
==============================================================================
--- sis/branches/JDK7/core/sis-metadata/src/main/java/org/apache/sis/metadata/iso/identification/DefaultAggregateInformation.java
[UTF-8] (original)
+++ sis/branches/JDK7/core/sis-metadata/src/main/java/org/apache/sis/metadata/iso/identification/DefaultAggregateInformation.java
[UTF-8] Fri Aug  1 15:10:03 2014
@@ -18,6 +18,7 @@ package org.apache.sis.metadata.iso.iden
 
 import java.util.Iterator;
 import java.util.ArrayList;
+import java.util.Collection;
 import javax.xml.bind.annotation.XmlType;
 import javax.xml.bind.annotation.XmlElement;
 import javax.xml.bind.annotation.XmlRootElement;
@@ -157,9 +158,12 @@ public class DefaultAggregateInformation
      */
     static Identifier getAggregateDataSetIdentifier(final Citation name) {
         if (name != null) {
-            final Iterator<? extends Identifier> it = name.getIdentifiers().iterator();
-            if (it.hasNext()) {
-                return it.next();
+            final Collection<? extends Identifier> names = name.getIdentifiers();
+            if (names != null) { // May be null on XML marshalling.
+                final Iterator<? extends Identifier> it = names.iterator();
+                if (it.hasNext()) {
+                    return it.next();
+                }
             }
         }
         return null;

Modified: sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/test/integration/DefaultMetadataTest.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/test/integration/DefaultMetadataTest.java?rev=1615133&r1=1615132&r2=1615133&view=diff
==============================================================================
--- sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/test/integration/DefaultMetadataTest.java
[UTF-8] (original)
+++ sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/test/integration/DefaultMetadataTest.java
[UTF-8] Fri Aug  1 15:10:03 2014
@@ -20,7 +20,6 @@ import java.net.URI;
 import java.net.URL;
 import java.util.Arrays;
 import java.util.Locale;
-import java.nio.charset.StandardCharsets;
 import javax.xml.bind.Unmarshaller;
 import javax.xml.bind.JAXBException;
 import javax.measure.unit.SI;
@@ -62,6 +61,9 @@ import static org.apache.sis.test.Assert
 import static java.util.Collections.singleton;
 import static java.util.Collections.singletonMap;
 
+// Branch-dependent imports
+import java.nio.charset.StandardCharsets;
+
 
 /**
  * Tests XML (un)marshalling of a metadata object containing various elements

Modified: sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/test/integration/ReferencingInMetadataTest.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/test/integration/ReferencingInMetadataTest.java?rev=1615133&r1=1615132&r2=1615133&view=diff
==============================================================================
--- sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/test/integration/ReferencingInMetadataTest.java
[UTF-8] (original)
+++ sis/branches/JDK7/core/sis-referencing/src/test/java/org/apache/sis/test/integration/ReferencingInMetadataTest.java
[UTF-8] Fri Aug  1 15:10:03 2014
@@ -18,7 +18,6 @@ package org.apache.sis.test.integration;
 
 import java.net.URI;
 import java.util.Locale;
-import java.nio.charset.StandardCharsets;
 import javax.xml.bind.JAXBException;
 import org.opengis.metadata.Metadata;
 import org.opengis.metadata.citation.Citation;
@@ -49,6 +48,9 @@ import org.junit.Test;
 import static org.apache.sis.test.Assert.*;
 import static org.apache.sis.test.TestUtilities.getSingleton;
 
+// Branch-dependent imports
+import java.nio.charset.StandardCharsets;
+
 
 /**
  * Tests XML (un)marshalling of referencing object inside metadata.

Modified: sis/branches/JDK7/core/sis-utility/src/test/java/org/apache/sis/xml/ValueConverterTest.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK7/core/sis-utility/src/test/java/org/apache/sis/xml/ValueConverterTest.java?rev=1615133&r1=1615132&r2=1615133&view=diff
==============================================================================
--- sis/branches/JDK7/core/sis-utility/src/test/java/org/apache/sis/xml/ValueConverterTest.java
[UTF-8] (original)
+++ sis/branches/JDK7/core/sis-utility/src/test/java/org/apache/sis/xml/ValueConverterTest.java
[UTF-8] Fri Aug  1 15:10:03 2014
@@ -17,13 +17,15 @@
 package org.apache.sis.xml;
 
 import java.util.Locale;
-import java.nio.charset.StandardCharsets;
 import org.apache.sis.test.DependsOn;
 import org.apache.sis.test.TestCase;
 import org.junit.Test;
 
 import static org.junit.Assert.*;
 
+// Branch-dependent imports
+import java.nio.charset.StandardCharsets;
+
 
 /**
  * Tests the {@link ValueConverter} class.

Modified: sis/branches/JDK7/storage/sis-storage/src/test/java/org/apache/sis/internal/storage/xml/XMLStoreTest.java
URL: http://svn.apache.org/viewvc/sis/branches/JDK7/storage/sis-storage/src/test/java/org/apache/sis/internal/storage/xml/XMLStoreTest.java?rev=1615133&r1=1615132&r2=1615133&view=diff
==============================================================================
--- sis/branches/JDK7/storage/sis-storage/src/test/java/org/apache/sis/internal/storage/xml/XMLStoreTest.java
[UTF-8] (original)
+++ sis/branches/JDK7/storage/sis-storage/src/test/java/org/apache/sis/internal/storage/xml/XMLStoreTest.java
[UTF-8] Fri Aug  1 15:10:03 2014
@@ -18,7 +18,6 @@ package org.apache.sis.internal.storage.
 
 import java.util.Locale;
 import java.io.StringReader;
-import java.nio.charset.StandardCharsets;
 import org.opengis.metadata.Metadata;
 import org.opengis.metadata.citation.Role;
 import org.opengis.metadata.citation.OnLineFunction;
@@ -33,6 +32,9 @@ import org.junit.Test;
 import static org.junit.Assert.*;
 import static org.apache.sis.test.TestUtilities.getSingleton;
 
+// Branch-dependent imports
+import java.nio.charset.StandardCharsets;
+
 
 /**
  * Tests {@link XMLStore}.



Mime
View raw message