Class: Accessionable::Base::Tag::FieldSerializer
- Inherits:
-
Object
- Object
- Accessionable::Base::Tag::FieldSerializer
show all
- Defined in:
- app/models/accessionable/base.rb
Overview
Value serialization for accessioning XML generation It will return the same value without any changes and it applies to all tags
Constant Summary
collapse
- NOT_COLLECTED =
'not collected'
- NOT_PROVIDED =
'not provided'
- RESTRICTED_ACCESS =
'restricted access'
- NOT_APPLICABLE_CONTROL_SAMPLE =
'not applicable: control sample'
- NOT_APPLICABLE_SAMPLE_GROUP =
'not applicable: sample group'
- MISSING_SYNTHETIC_CONSTRUCT =
'missing: synthetic construct'
- MISSING_LAB_STOCK =
'missing: lab stock'
- MISING_THIRD_PARTY_DATA =
'missing: third party data'
- MISSING_DATA_AGGREEMENT_PRE2023 =
'missing: data agreement established pre-2023'
- MISSING_ENDANGERED_SPECIES =
'missing: endangered species'
- MISSING_HUMAN_IDENTIFIABLE =
'missing: human-identifiable'
- MISSING_CONTROL_SAMPLE =
'missing: control sample'
- MISSING_SAMPLE_GROUP =
'missing: sample group'
- OTHER_DEFAULT_SETTINGS =
[
NOT_COLLECTED,
NOT_PROVIDED,
RESTRICTED_ACCESS,
NOT_APPLICABLE_CONTROL_SAMPLE,
NOT_APPLICABLE_SAMPLE_GROUP,
MISSING_SYNTHETIC_CONSTRUCT,
MISSING_LAB_STOCK,
MISING_THIRD_PARTY_DATA,
MISSING_DATA_AGGREEMENT_PRE2023,
MISSING_ENDANGERED_SPECIES,
MISSING_HUMAN_IDENTIFIABLE,
MISSING_CONTROL_SAMPLE,
MISSING_SAMPLE_GROUP
].freeze
Instance Method Summary
collapse
Instance Method Details
#applies_to?(_name) ⇒ Boolean
120
121
122
|
# File 'app/models/accessionable/base.rb', line 120
def applies_to?(_name)
true
end
|
123
124
125
|
# File 'app/models/accessionable/base.rb', line 123
def incorrect_format_value
NOT_PROVIDED
end
|
#value_for(value) ⇒ Object
117
118
119
|
# File 'app/models/accessionable/base.rb', line 117
def value_for(value)
value
end
|