Module: Gbif::Occurrences
- Defined in:
- lib/gbifrb/Occurrences.rb
Class Method Summary collapse
-
.get(key:, verbose: nil, options: nil) ⇒ hash
Gets details for a single, interpreted occurrence.
-
.get_fragment(key:, verbose: nil, options: nil) ⇒ Object
Get a single occurrence fragment in its raw form (xml or json).
-
.get_verbatim(key:, verbose: nil, options: nil) ⇒ hash
Gets a verbatim occurrence record without any interpretation.
-
.search(taxonKey: nil, repatriated: nil, kingdomKey: nil, phylumKey: nil, classKey: nil, orderKey: nil, familyKey: nil, genusKey: nil, subgenusKey: nil, scientificName: nil, country: nil, publishingCountry: nil, hasCoordinate: nil, typeStatus: nil, recordNumber: nil, lastInterpreted: nil, continent: nil, geometry: nil, recordedBy: nil, basisOfRecord: nil, datasetKey: nil, eventDate: nil, catalogNumber: nil, year: nil, month: nil, decimalLatitude: nil, decimalLongitude: nil, elevation: nil, depth: nil, institutionCode: nil, collectionCode: nil, hasGeospatialIssue: nil, issue: nil, q: nil, spellCheck: nil, mediatype: nil, limit: 300, offset: 0, establishmentMeans: nil, facet: nil, facetMincount: nil, facetMultiselect: nil, verbose: nil, options: nil) ⇒ Hash
Search GBIF occurrences.
Class Method Details
.get(key:, verbose: nil, options: nil) ⇒ hash
Gets details for a single, interpreted occurrence
352 353 354 355 |
# File 'lib/gbifrb/Occurrences.rb', line 352 def self.get(key:, verbose: nil, options: nil) url = 'occurrence/' + key.to_s Request.new(url, {}, verbose, ).perform end |
.get_fragment(key:, verbose: nil, options: nil) ⇒ Object
Get a single occurrence fragment in its raw form (xml or json)
@return: [hash]
391 392 393 394 |
# File 'lib/gbifrb/Occurrences.rb', line 391 def self.get_fragment(key:, verbose: nil, options: nil) url = 'occurrence/' + key.to_s + '/fragment' Request.new(url, {}, verbose, ).perform end |
.get_verbatim(key:, verbose: nil, options: nil) ⇒ hash
Gets a verbatim occurrence record without any interpretation
371 372 373 374 |
# File 'lib/gbifrb/Occurrences.rb', line 371 def self.get_verbatim(key:, verbose: nil, options: nil) url = 'occurrence/' + key.to_s + '/verbatim' Request.new(url, {}, verbose, ).perform end |
.search(taxonKey: nil, repatriated: nil, kingdomKey: nil, phylumKey: nil, classKey: nil, orderKey: nil, familyKey: nil, genusKey: nil, subgenusKey: nil, scientificName: nil, country: nil, publishingCountry: nil, hasCoordinate: nil, typeStatus: nil, recordNumber: nil, lastInterpreted: nil, continent: nil, geometry: nil, recordedBy: nil, basisOfRecord: nil, datasetKey: nil, eventDate: nil, catalogNumber: nil, year: nil, month: nil, decimalLatitude: nil, decimalLongitude: nil, elevation: nil, depth: nil, institutionCode: nil, collectionCode: nil, hasGeospatialIssue: nil, issue: nil, q: nil, spellCheck: nil, mediatype: nil, limit: 300, offset: 0, establishmentMeans: nil, facet: nil, facetMincount: nil, facetMultiselect: nil, verbose: nil, options: nil) ⇒ Hash
Search GBIF occurrences
303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 |
# File 'lib/gbifrb/Occurrences.rb', line 303 def self.search(taxonKey: nil, repatriated: nil, kingdomKey: nil, phylumKey: nil, classKey: nil, orderKey: nil, familyKey: nil, genusKey: nil, subgenusKey: nil, scientificName: nil, country: nil, publishingCountry: nil, hasCoordinate: nil, typeStatus: nil, recordNumber: nil, lastInterpreted: nil, continent: nil, geometry: nil, recordedBy: nil, basisOfRecord: nil, datasetKey: nil, eventDate: nil, catalogNumber: nil, year: nil, month: nil, decimalLatitude: nil, decimalLongitude: nil, elevation: nil, depth: nil, institutionCode: nil, collectionCode: nil, hasGeospatialIssue: nil, issue: nil, q: nil, spellCheck: nil, mediatype: nil, limit: 300, offset: 0, establishmentMeans: nil, facet: nil, facetMincount: nil, facetMultiselect: nil, verbose: nil, options: nil) arguments = { taxonKey: taxonKey, repatriated: repatriated, kingdomKey: kingdomKey, phylumKey: phylumKey, classKey: classKey, orderKey: orderKey, familyKey: familyKey, genusKey: genusKey, subgenusKey: subgenusKey, scientificName: scientificName, country: country, publishingCountry: publishingCountry, hasCoordinate: hasCoordinate, typeStatus: typeStatus, recordNumber: recordNumber, lastInterpreted: lastInterpreted, continent: continent, geometry: geometry, recordedBy: recordedBy, basisOfRecord: basisOfRecord, datasetKey: datasetKey, eventDate: eventDate, catalogNumber: catalogNumber, year: year, month: month, decimalLatitude: decimalLatitude, decimalLongitude: decimalLongitude, elevation: elevation, depth: depth, institutionCode: institutionCode, collectionCode: collectionCode, hasGeospatialIssue: hasGeospatialIssue, issue: issue, q: q, spellCheck: spellCheck, mediatype: mediatype, limit: limit, offset: offset, establishmentMeans: establishmentMeans, facetMincount: facetMincount, facet: facet, facetMultiselect: facetMultiselect}.tostrings opts = arguments.delete_if { |k, v| v.nil? } return Request.new('occurrence/search', opts, verbose, ).perform end |