You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Interfaces in org.opengis.metadata packages use very specific types for numerical values, for example java.lang.Integer (fixed to 32 bits) or java.lang.Double (fixed to 64 bits). Those types are not always appropriate; an implementation may need to use a Long or even a BigInteger instead than 32 bits integers, or a BigDecimal instead than IEEE 754 floating point. We should leave that flexibility by using the more general Number type instead than a specific subtypes. In particular for the following properties:
MD_FeatureTypeInfo.featureInstanceCount: 32-bits integer type is insufficient.
For floating point values, many of them are actually measurements. For those ones, we should consider javax.measurement.Quantity.
Historical note: the decision to use specific subtypes was done in the GeoAPI 2 days for compatibility with technologies like JAXB or Hibernate. But even with this goal in mind, abstract types could have been used with the help of adapters.
The text was updated successfully, but these errors were encountered:
Interfaces in
org.opengis.metadata
packages use very specific types for numerical values, for examplejava.lang.Integer
(fixed to 32 bits) orjava.lang.Double
(fixed to 64 bits). Those types are not always appropriate; an implementation may need to use aLong
or even aBigInteger
instead than 32 bits integers, or aBigDecimal
instead than IEEE 754 floating point. We should leave that flexibility by using the more generalNumber
type instead than a specific subtypes. In particular for the following properties:MD_FeatureTypeInfo.featureInstanceCount
: 32-bits integer type is insufficient.For floating point values, many of them are actually measurements. For those ones, we should consider
javax.measurement.Quantity
.Historical note: the decision to use specific subtypes was done in the GeoAPI 2 days for compatibility with technologies like JAXB or Hibernate. But even with this goal in mind, abstract types could have been used with the help of adapters.
The text was updated successfully, but these errors were encountered: