Class: Wings::ActiveFedoraConverter::NestedResource
- Inherits:
-
ActiveTriples::Resource
- Object
- ActiveTriples::Resource
- Wings::ActiveFedoraConverter::NestedResource
- Includes:
- Hyrax::BasicMetadata
- Defined in:
- lib/wings/active_fedora_converter/nested_resource.rb
Instance Method Summary collapse
-
#initialize(uri = RDF::Node.new, _parent = ActiveTriples::Resource.new) ⇒ NestedResource
constructor
A new instance of NestedResource.
Constructor Details
#initialize(uri = RDF::Node.new, _parent = ActiveTriples::Resource.new) ⇒ NestedResource
Returns a new instance of NestedResource.
13 14 15 16 17 18 19 20 |
# File 'lib/wings/active_fedora_converter/nested_resource.rb', line 13 def initialize(uri = RDF::Node.new, _parent = ActiveTriples::Resource.new) uri = if uri.try(:node?) RDF::URI("#nested_resource_#{uri.to_s.gsub('_:', '')}") elsif uri.to_s.include?('#') RDF::URI(uri) end super end |