gbif / gbif-api

GBIF API
Apache License 2.0
27 stars 5 forks source link

Add two assertions: GEOREFERENCED_DATE_UNLIKELY GEOREFERENCED_DATE_INVALID #61

Closed qifeng-bai closed 3 years ago

qifeng-bai commented 3 years ago

DwC geoReferencedDate has been added into LocationRecord now.
Similar with DwC.dateIdentified, We would like to add two relevant assertions , GEOREFERENCED_DATE_UNLIKELY, GEOREFERENCED_DATE_INVALID

MattBlissett commented 3 years ago

Thanks, I will add this.

  /**
   * The date given for dwc:georeferencedDate is in the future or before Linnean times (1700).
   */
  GEOREFERENCED_DATE_UNLIKELY(WARNING, DwcTerm.georeferencedDate),

  /**
   * The date given for dwc:georeferencedDate is invalid and can't be interpreted at all.
   */
  GEOREFERENCED_DATE_INVALID(WARNING, DwcTerm.georeferencedDate);

Do you know what the earliest date could be? It's just for the comment, but it would be good to be correct. Pre 1700, or before the eventDate (but maybe the georeferenced fields would be set and reused for later samples at the same location)…?