Class: Identifier::Global::ZoologicalRecord

Inherits:
WebOfScience show all
Defined in:
app/models/identifier/global/zoological_record.rb

Overview

Zoological Record is a type of Web of Science ID namespaced with ZOOREC:ZOOR

Constant Summary

Constants inherited from WebOfScience

WebOfScience::NAMESPACES, WebOfScience::URI_BASE

Constants included from SoftValidation

SoftValidation::ANCESTORS_WITH_SOFT_VALIDATIONS

Instance Attribute Summary

Attributes inherited from Identifier::Global

#relation

Instance Method Summary collapse

Methods inherited from WebOfScience

#source_use_only, #upcase_identifier, #uri

Methods inherited from Identifier::Global

#build_cached, #dwc_occurrences, #is_global?, #sv_resolves?

Methods included from SoftValidation

#clear_soft_validations, #fix_for, #fix_soft_validations, #soft_fixed?, #soft_valid?, #soft_validate, #soft_validated?, #soft_validations, #soft_validators

Instance Method Details

#namespace_formatObject (private)

Examples: ZOOR15303016510, ZOOR15307044227



9
10
11
# File 'app/models/identifier/global/zoological_record.rb', line 9

def namespace_format
  errors.add(:identifier, 'Identifier is not prefixed with an recognized "namespace".') unless identifier =~ /^ZOOREC:ZOOR\d{11}/
end