Class: Valkyrie::Persistence::Fedora::Persister::ModelConverter::BooleanValue
Instance Attribute Summary
Attributes inherited from ValueMapper
#calling_mapper, #value
Class Method Summary
collapse
Instance Method Summary
collapse
Methods inherited from ValueMapper
for, #initialize, register
Class Method Details
.handles?(value) ⇒ Boolean
195
196
197
|
# File 'lib/valkyrie/persistence/fedora/persister/model_converter.rb', line 195
def self.handles?(value)
value.is_a?(Property) && ([true, false].include? value.value)
end
|
Instance Method Details
#result ⇒ Object
199
200
201
202
203
204
|
# File 'lib/valkyrie/persistence/fedora/persister/model_converter.rb', line 199
def result
map_value(converted_value: RDF::Literal.new(
value.value,
datatype: PermissiveSchema.valkyrie_bool
))
end
|