You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@sis.apache.org by de...@apache.org on 2019/05/01 20:55:16 UTC

[sis] branch master updated (4610eab -> 09ba94f)

This is an automated email from the ASF dual-hosted git repository.

desruisseaux pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/sis.git.


    from 4610eab  Merge branch 'geoapi-3.1'. Contains work on netCDF reader and addition of two map projections.
     add 1f0fbb9  Fix a thread-safety hole.
     add 24fcb0f  Implements GridEnvelope and GridCoordinates following resolution of https://github.com/opengeospatial/geoapi/issues/36
     add 77720b8  Merge branch 'geoapi-4.0' into geoapi-3.1: implementation of GridEnvelope interface.
     new cdc04d4  Merge branch 'geoapi-3.1' excluding the use of `GridEnvelope` interface (because not present in GeoAPI 3.0).
     add fceec82  Fix missing "s" in "getOrderOptionsType()" for ISO 19115 compliance. https://github.com/opengeospatial/geoapi/issues/21
     add 59b5551  Fix spelling error in method name, but not in XML annotation since the spelling exists in ISO specification. https://github.com/opengeospatial/geoapi/issues/43
     add 9426368  Merge branch 'geoapi-4.0' into geoapi-3.1 but without the change in Objective.getObjectiveOccurences() method name. The old name is kept on GeoAPI 3.1 branch for compatibility reason.
     add 2492289  Rename "polarization" as "polarisation" in two method names for compliance with latest ISO 19115 revision. https://github.com/opengeospatial/geoapi/issues/15
     add d6b8565  Renamed PolarizationOrientation as PolarisationOrientation for compliance with latest ISO 19115-2 revision. Part of https://github.com/opengeospatial/geoapi/issues/23
     add f7fb545  Merge branch 'geoapi-4.0' into geoapi-3.1, taking only the renaming in annotations. Renaming of methods or classes are not taken for compatibility reasons.
     add bf56b15  Renamed getCenterPoint() as getCentrePoint() for compliance with ISO 19115:2014.
     add 8164ff4  Merge branch 'geoapi-4.0' into geoapi-3.1, but replacing method renaming by a comment about future evolution.
     new 09ba94f  Merge branch 'geoapi-3.1' with some methods renamings replaced by comments about future evolution.

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../org/apache/sis/internal/book/GEOAPI.lst        |  2 +-
 .../resources/org/apache/sis/internal/book/OGC.lst |  2 +-
 ...de.java => MI_PolarisationOrientationCode.java} | 12 +++---
 .../apache/sis/metadata/PropertyInformation.java   |  3 +-
 .../metadata/iso/acquisition/DefaultObjective.java | 24 ++++++-----
 .../sis/metadata/iso/content/DefaultBand.java      | 20 ++++++++++
 .../sis/metadata/iso/content/package-info.java     |  6 +--
 .../distribution/DefaultStandardOrderProcess.java  | 46 ++++++++++++++++------
 .../metadata/iso/spatial/DefaultGeorectified.java  |  8 ++++
 .../apache/sis/metadata/iso/AllMetadataTest.java   |  8 +++-
 .../apache/sis/metadata/iso/api-changes.properties |  2 +-
 .../sis/coverage/grid/GridCoordinatesView.java     |  4 +-
 .../org/apache/sis/coverage/grid/GridExtent.java   | 10 +----
 13 files changed, 101 insertions(+), 46 deletions(-)
 rename core/sis-metadata/src/main/java/org/apache/sis/internal/jaxb/code/{MI_PolarizationOrientationCode.java => MI_PolarisationOrientationCode.java} (88%)


[sis] 02/02: Merge branch 'geoapi-3.1' with some methods renamings replaced by comments about future evolution.

Posted by de...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

desruisseaux pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sis.git

commit 09ba94fc57bd2f28da5a99764afe78b1b13cd51d
Merge: cdc04d4 8164ff4
Author: Martin Desruisseaux <ma...@geomatys.com>
AuthorDate: Wed May 1 22:52:56 2019 +0200

    Merge branch 'geoapi-3.1' with some methods renamings replaced by comments about future evolution.

 .../org/apache/sis/internal/book/GEOAPI.lst        |  2 +-
 .../resources/org/apache/sis/internal/book/OGC.lst |  2 +-
 ...de.java => MI_PolarisationOrientationCode.java} | 12 +++---
 .../metadata/iso/acquisition/DefaultObjective.java | 24 ++++++-----
 .../sis/metadata/iso/content/DefaultBand.java      | 20 ++++++++++
 .../sis/metadata/iso/content/package-info.java     |  6 +--
 .../distribution/DefaultStandardOrderProcess.java  | 46 ++++++++++++++++------
 .../metadata/iso/spatial/DefaultGeorectified.java  |  8 ++++
 .../apache/sis/metadata/iso/AllMetadataTest.java   |  8 +++-
 .../apache/sis/metadata/iso/api-changes.properties |  2 +-
 10 files changed, 96 insertions(+), 34 deletions(-)

diff --cc core/sis-metadata/src/main/java/org/apache/sis/metadata/iso/acquisition/DefaultObjective.java
index 22c1e41,2e4ee54..6c3f97b
--- a/core/sis-metadata/src/main/java/org/apache/sis/metadata/iso/acquisition/DefaultObjective.java
+++ b/core/sis-metadata/src/main/java/org/apache/sis/metadata/iso/acquisition/DefaultObjective.java
@@@ -134,14 -134,14 +134,14 @@@ public class DefaultObjective extends I
      public DefaultObjective(final Objective object) {
          super(object);
          if (object != null) {
-             identifiers         = copyCollection(object.getIdentifiers(), Identifier.class);
-             priority            = object.getPriority();
-             types               = copyCollection(object.getTypes(), ObjectiveType.class);
-             functions           = copyCollection(object.getFunctions(), InternationalString.class);
-             extents             = copyCollection(object.getExtents(), Extent.class);
-             objectiveOccurences = copyCollection(object.getObjectiveOccurences(), Event.class);
-             pass                = copyCollection(object.getPass(), PlatformPass.class);
-             sensingInstruments  = copyCollection(object.getSensingInstruments(), Instrument.class);
+             identifiers          = copyCollection(object.getIdentifiers(), Identifier.class);
+             priority             = object.getPriority();
+             types                = copyCollection(object.getTypes(), ObjectiveType.class);
+             functions            = copyCollection(object.getFunctions(), InternationalString.class);
+             extents              = copyCollection(object.getExtents(), Extent.class);
 -            objectiveOccurrences = copyCollection(object.getObjectiveOccurences(), Event.class);
++            objectiveOccurences  = copyCollection(object.getObjectiveOccurences(), Event.class);
+             pass                 = copyCollection(object.getPass(), PlatformPass.class);
+             sensingInstruments   = copyCollection(object.getSensingInstruments(), Instrument.class);
          }
      }
  
@@@ -289,6 -289,18 +289,9 @@@
      /**
       * Returns the event or events associated with objective completion.
       *
 -     * @return events associated with objective completion.
 -     *
 -     * @since 1.0
 -     */
 -    @XmlElement(name = "objectiveOccurence", required = true)
 -    public Collection<Event> getObjectiveOccurrences() {
 -        return objectiveOccurrences = nonNullCollection(objectiveOccurrences, Event.class);
 -    }
 -
 -    /**
 -     * @deprecated Renamed {@link #getObjectiveOccurrences()}.
++     * <div class="warning"><b>Upcoming API change</b><br>
++     * This method is misspelled (missing "r"). Its name may be fixed in GeoAPI 4.0.</div>
+      *
       * @return events associated with objective completion.
       */
      @Override
@@@ -300,10 -312,22 +303,13 @@@
      /**
       * Sets the event or events associated with objective completion.
       *
 -     * @param  newValues  the new objective occurrences values.
 -     *
 -     * @since 1.0
 -     */
 -    public void setObjectiveOccurrences(final Collection<? extends Event> newValues) {
 -        objectiveOccurrences = writeCollection(newValues, objectiveOccurrences, Event.class);
 -    }
 -
 -    /**
 -     * @deprecated Renamed {@link #setObjectiveOccurrences(Collection)}.
++     * <div class="warning"><b>Upcoming API change</b><br>
++     * This method is misspelled (missing "r"). Its name may be fixed in GeoAPI 4.0.</div>
+      *
       * @param  newValues  the new objective occurrences values.
       */
 -    @Deprecated
      public void setObjectiveOccurences(final Collection<? extends Event> newValues) {
 -        setObjectiveOccurrences(newValues);
 +        objectiveOccurences = writeCollection(newValues, objectiveOccurences, Event.class);
      }
  
      /**
diff --cc core/sis-metadata/src/main/java/org/apache/sis/metadata/iso/distribution/DefaultStandardOrderProcess.java
index 856d654,242800a..5ef1bc8
--- a/core/sis-metadata/src/main/java/org/apache/sis/metadata/iso/distribution/DefaultStandardOrderProcess.java
+++ b/core/sis-metadata/src/main/java/org/apache/sis/metadata/iso/distribution/DefaultStandardOrderProcess.java
@@@ -133,10 -129,8 +133,10 @@@ public class DefaultStandardOrderProces
              plannedAvailableDateTime = toMilliseconds(object.getPlannedAvailableDateTime());
              orderingInstructions     = object.getOrderingInstructions();
              turnaround               = object.getTurnaround();
 -            orderOptionsType         = object.getOrderOptionsType();
 -            orderOptions             = object.getOrderOptions();
 +            if (object instanceof DefaultStandardOrderProcess) {
-                 orderOptionType = ((DefaultStandardOrderProcess) object).getOrderOptionType();
-                 orderOptions    = ((DefaultStandardOrderProcess) object).getOrderOptions();
++                orderOptionsType = ((DefaultStandardOrderProcess) object).getOrderOptionsType();
++                orderOptions     = ((DefaultStandardOrderProcess) object).getOrderOptions();
 +            }
          }
      }
  
@@@ -300,11 -295,23 +300,23 @@@
       *
       * @see org.apache.sis.util.iso.DefaultRecord#getRecordType()
       */
 -    @Override
      @XmlElement(name = "orderOptionsType")
      @XmlJavaTypeAdapter(GO_RecordType.Since2014.class)
-     @UML(identifier="orderOptionType", obligation=OPTIONAL, specification=ISO_19115)
++    @UML(identifier="orderOptionsType", obligation=OPTIONAL, specification=ISO_19115)
+     public RecordType getOrderOptionsType() {
+         return orderOptionsType;
+     }
+ 
+     /**
+      * @deprecated Renamed {@link #getOrderOptionsType()} for ISO 19115 conformance.
+      *
+      * @return description of the order options record, or {@code null} if none.
+      *
+      * @since 0.5
+      */
 -    @Deprecated
++//  @Deprecated - omitted for allowing APIVerifier to pass.
      public RecordType getOrderOptionType() {
-         return orderOptionType;
+         return getOrderOptionsType();
      }
  
      /**
diff --cc core/sis-metadata/src/test/java/org/apache/sis/metadata/iso/AllMetadataTest.java
index d300df5,464cdf2a..99dbd13
--- a/core/sis-metadata/src/test/java/org/apache/sis/metadata/iso/AllMetadataTest.java
+++ b/core/sis-metadata/src/test/java/org/apache/sis/metadata/iso/AllMetadataTest.java
@@@ -227,9 -239,9 +227,13 @@@ public final strictfp class AllMetadata
               */
              return null;
          }
++        String identifier = type.getAnnotation(UML.class).identifier();
++        if (identifier.equals("MI_PolarizationOrientationCode")) {
++            identifier = "MI_PolarisationOrientationCode";
++            // https://issues.apache.org/jira/browse/SIS-398
++        }
          final String classname = "org.apache.sis.internal.jaxb." +
-                 (CodeList.class.isAssignableFrom(type) ? "code" : "metadata") +
 -                (ControlledVocabulary.class.isAssignableFrom(type) ? "code" : "metadata") +
--                '.' + type.getAnnotation(UML.class).identifier();
++                (CodeList.class.isAssignableFrom(type) ? "code" : "metadata") + '.' + identifier;
          final Class<?> wrapper = Class.forName(classname);
          Class<?>[] expectedFinalClasses = wrapper.getClasses();   // "Since2014" internal class.
          if (expectedFinalClasses.length == 0) {
diff --cc core/sis-metadata/src/test/resources/org/apache/sis/metadata/iso/api-changes.properties
index f02bb1d,8476d40..8efbceb
--- a/core/sis-metadata/src/test/resources/org/apache/sis/metadata/iso/api-changes.properties
+++ b/core/sis-metadata/src/test/resources/org/apache/sis/metadata/iso/api-changes.properties
@@@ -22,35 -22,3 +22,35 @@@
  # with the changes in the international standard. The UML identifiers of added methods are "number"
  # and "numberType" respectively.
  #
 +org.opengis.metadata.citation.Citation=-getCollectiveTitle +getGraphics:graphic +getOnlineResources:onlineResource
 +org.opengis.metadata.citation.Contact=-getAddress +getAddresses:address +getContactType:contactType -getOnlineResource +getOnlineResources:onlineResource -getPhone +getPhones:phone
 +org.opengis.metadata.citation.OnlineResource=+getProtocolRequest:protocolRequest
 +org.opengis.metadata.citation.ResponsibleParty=-getContactInfo -getIndividualName -getOrganisationName -getPositionName
 +org.opengis.metadata.citation.Telephone=-getFacsimiles +getNumber:number +getNumberType:numberType -getVoices
 +org.opengis.metadata.constraint.Constraints=+getConstraintApplicationScope:constraintApplicationScope +getGraphics:graphic +getReferences:reference +getReleasability:releasability +getResponsibleParties:responsibleParty
 +org.opengis.metadata.content.Band=+getBoundMax:boundMax +getBoundMin:boundMin +getBoundUnits:boundUnits
 +org.opengis.metadata.content.CoverageDescription=+getAttributeGroups:attributeGroup -getContentType -getDimensions +getProcessingLevelCode:processingLevelCode
 +org.opengis.metadata.content.FeatureCatalogueDescription=+getFeatureTypeInfo:featureTypes -getFeatureTypes
 +org.opengis.metadata.content.RangeDimension=+getDescription:description -getDescriptor +getNames:name
 +org.opengis.metadata.distribution.DigitalTransferOptions=+getDistributionFormats:distributionFormat -getOffLine +getOffLines:offLine +getTransferFrequency:transferFrequency
 +org.opengis.metadata.distribution.Distribution=+getDescription:description
 +org.opengis.metadata.distribution.Format=+getFormatSpecificationCitation:formatSpecificationCitation +getMedia:medium -getName -getSpecification -getVersion
 +org.opengis.metadata.distribution.Medium=-getDensities +getDensity:density +getIdentifier:identifier
- org.opengis.metadata.distribution.StandardOrderProcess=+getOrderOptionType:orderOptionType +getOrderOptions:orderOptions
++org.opengis.metadata.distribution.StandardOrderProcess=+getOrderOptionsType:orderOptionsType +getOrderOptions:orderOptions
 +org.opengis.metadata.ExtendedElementInformation=-getDomainCode +getRationale:rationale -getRationales -getShortName
 +org.opengis.metadata.extent.SpatialTemporalExtent=+getVerticalExtent:verticalExtent
 +org.opengis.metadata.identification.AggregateInformation=-getAggregateDataSetIdentifier -getAggregateDataSetName +getMetadataReference:metadataReference +getName:name
 +org.opengis.metadata.identification.BrowseGraphic=+getImageConstraints:imageContraints +getLinkages:linkage
 +org.opengis.metadata.identification.Identification=+getAdditionalDocumentations:additionalDocumentation -getAggregationInfo +getAssociatedResources:associatedResource +getExtents:extent +getProcessingLevel:processingLevel +getSpatialRepresentationTypes:spatialRepresentationType +getSpatialResolutions:spatialResolution ~+getTemporalResolutions:temporalResolution +getTopicCategories:topicCategory
 +org.opengis.metadata.identification.Keywords=+getKeywordClass:keywordClass
 +org.opengis.metadata.identification.Resolution=+getAngularDistance:angularDistance +getLevelOfDetail:levelOfDetail +getVertical:vertical
 +org.opengis.metadata.identification.ServiceIdentification=+getAccessProperties:accessProperties +getContainsChain:containsChain +getContainsOperations:containsOperations +getCoupledResources:coupledResource +getCouplingType:couplingType +getOperatedDatasets:operatedDataset +getOperatesOn:operatesOn +getProfiles:profile +getServiceStandards:serviceStandard +getServiceType:serviceType +getServiceTypeVersions:serviceTypeVersion
 +org.opengis.metadata.identification.Usage=+getAdditionalDocumentation:additionalDocumentation +getIdentifiedIssues:identifiedIssues +getResponses:response
 +org.opengis.metadata.Identifier=+getCodeSpace:codeSpace +getDescription:description +getVersion:version
 +org.opengis.metadata.lineage.Lineage=+getAdditionalDocumentation:additionalDocumentation +getScope:scope
 +org.opengis.metadata.lineage.ProcessStep=-getDate +getReferences:reference +getScope:scope
 +org.opengis.metadata.lineage.Source=-getScaleDenominator +getScope:scope -getSourceExtents +getSourceMetadata:sourceMetadata +getSourceSpatialResolution:sourceSpatialResolution
 +org.opengis.metadata.maintenance.MaintenanceInformation=-getDateOfNextUpdate +getMaintenanceDates:maintenanceDate +getMaintenanceScopes:maintenanceScope -getUpdateScopeDescriptions -getUpdateScopes
 +org.opengis.metadata.Metadata=+getAlternativeMetadataReferences:alternativeMetadataReference -getCharacterSet +getCharacterSets:characterSet -getDataSetUri -getDateStamp +getDateInfo:dateInfo -getFileIdentifier -getHierarchyLevelNames -getHierarchyLevels -getLanguage +getLanguages:defaultLocale+otherLocale -getLocales +getMetadataIdentifier:metadataIdentifier +getMetadataLinkages:metadataLinkage +getMetadataProfiles:metadataProfile +getMetadataScopes:metadataScope -getMetadataStandardNa [...]
 +org.opengis.metadata.quality.Scope=-getExtent +getExtents:extent
 +org.opengis.metadata.spatial.Dimension=+getDimensionDescription:dimensionDescription +getDimensionTitle:dimensionTitle


[sis] 01/02: Merge branch 'geoapi-3.1' excluding the use of `GridEnvelope` interface (because not present in GeoAPI 3.0).

Posted by de...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

desruisseaux pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sis.git

commit cdc04d4c1bce94e9ccc7e24ce484415095b57006
Merge: 4610eab 77720b8
Author: Martin Desruisseaux <ma...@geomatys.com>
AuthorDate: Wed May 1 13:25:34 2019 +0200

    Merge branch 'geoapi-3.1' excluding the use of `GridEnvelope` interface (because not present in GeoAPI 3.0).

 .../main/java/org/apache/sis/metadata/PropertyInformation.java |  3 ++-
 .../java/org/apache/sis/coverage/grid/GridCoordinatesView.java |  4 ++--
 .../src/main/java/org/apache/sis/coverage/grid/GridExtent.java | 10 +---------
 3 files changed, 5 insertions(+), 12 deletions(-)

diff --cc core/sis-raster/src/main/java/org/apache/sis/coverage/grid/GridCoordinatesView.java
index 3e68c4e,1e9dadd..92027c0
--- a/core/sis-raster/src/main/java/org/apache/sis/coverage/grid/GridCoordinatesView.java
+++ b/core/sis-raster/src/main/java/org/apache/sis/coverage/grid/GridCoordinatesView.java
@@@ -24,16 -26,12 +24,16 @@@ import org.apache.sis.util.ArgumentChec
   * A view over the low or high grid envelope coordinates.
   * This is not a general-purpose grid coordinates since it assumes a {@link GridExtent} coordinates layout.
   *
 + * <div class="note"><b>Upcoming API generalization:</b>
 + * this class may implement the {@code GridCoordinates} interface in a future Apache SIS version.
-  * This is pending <a href="https://github.com/opengeospatial/geoapi/issues/36">GeoAPI update</a>.</div>
++ * This is pending GeoAPI update.</div>
 + *
   * @author  Martin Desruisseaux (Geomatys)
   * @version 1.0
   * @since   1.0
   * @module
   */
- final class GridCoordinatesView /* implements GridCoordinates */ {
 -final class GridCoordinatesView implements GridCoordinates {
++final class GridCoordinatesView {
      /**
       * A reference to the coordinate array of the enclosing grid envelope.
       */
diff --cc core/sis-raster/src/main/java/org/apache/sis/coverage/grid/GridExtent.java
index 0de2a04,8cbd609..8bd469b
--- a/core/sis-raster/src/main/java/org/apache/sis/coverage/grid/GridExtent.java
+++ b/core/sis-raster/src/main/java/org/apache/sis/coverage/grid/GridExtent.java
@@@ -66,10 -72,6 +66,10 @@@ import org.apache.sis.util.iso.Types
   * <p>{@code GridExtent} instances are immutable and thread-safe.
   * The same instance can be shared by different {@link GridGeometry} instances.</p>
   *
 + * <div class="note"><b>Upcoming API generalization:</b>
 + * this class may implement the {@code GridEnvelope} interface in a future Apache SIS version.
-  * This is pending <a href="https://github.com/opengeospatial/geoapi/issues/36">GeoAPI update</a>.</div>
++ * This is pending GeoAPI update.</div>
 + *
   * @author  Martin Desruisseaux (IRD, Geomatys)
   * @version 1.0
   * @since   1.0
@@@ -491,11 -531,9 +491,8 @@@ public class GridExtent implements Seri
       * The sequence contains a minimum value for each dimension of the grid coverage.
       *
       * @return the valid minimum grid coordinates, inclusive.
-      *
-      * @todo Pending resolution of <a href="https://github.com/opengeospatial/geoapi/issues/36">GeoAPI update</a>
-      *       before to become public API, in order to use the interface in return type.
       */
 -    @Override
 -    public GridCoordinates getLow() {
 +    GridCoordinatesView getLow() {
          return new GridCoordinatesView(coordinates, 0);
      }
  
@@@ -504,11 -542,9 +501,8 @@@
       * The sequence contains a maximum value for each dimension of the grid coverage.
       *
       * @return the valid maximum grid coordinates, <strong>inclusive</strong>.
-      *
-      * @todo Pending resolution of <a href="https://github.com/opengeospatial/geoapi/issues/36">GeoAPI update</a>
-      *       before to become public API, in order to use the interface in return type.
       */
 -    @Override
 -    public GridCoordinates getHigh() {
 +    GridCoordinatesView getHigh() {
          return new GridCoordinatesView(coordinates, getDimension());
      }
  
@@@ -520,9 -556,10 +514,8 @@@
       * @throws IndexOutOfBoundsException if the given index is negative or is equals or greater
       *         than the {@linkplain #getDimension() grid dimension}.
       *
--     * @see #getLow()
       * @see #getHigh(int)
       */
 -    @Override
      public long getLow(final int index) {
          ArgumentChecks.ensureValidIndex(getDimension(), index);
          return coordinates[index];
@@@ -536,9 -573,10 +529,8 @@@
       * @throws IndexOutOfBoundsException if the given index is negative or is equals or greater
       *         than the {@linkplain #getDimension() grid dimension}.
       *
--     * @see #getHigh()
       * @see #getLow(int)
       */
 -    @Override
      public long getHigh(final int index) {
          final int dimension = getDimension();
          ArgumentChecks.ensureValidIndex(dimension, index);