Class: Valkyrie::Persistence::Fedora::ListNode::Builder
- Inherits:
-
Object
- Object
- Valkyrie::Persistence::Fedora::ListNode::Builder
- Defined in:
- lib/valkyrie/persistence/fedora/list_node.rb
Overview
Class used to populate the RDF graph structure for the linked lists
Instance Attribute Summary collapse
-
#graph ⇒ Object
readonly
Returns the value of attribute graph.
-
#uri ⇒ Object
readonly
Returns the value of attribute uri.
Instance Method Summary collapse
-
#initialize(uri, graph) ⇒ Builder
constructor
A new instance of Builder.
-
#populate(instance) ⇒ Object
Populates attributes for the LinkedNode.
Constructor Details
#initialize(uri, graph) ⇒ Builder
Returns a new instance of Builder.
99 100 101 102 |
# File 'lib/valkyrie/persistence/fedora/list_node.rb', line 99 def initialize(uri, graph) @uri = uri @graph = graph end |
Instance Attribute Details
#graph ⇒ Object (readonly)
Returns the value of attribute graph.
95 96 97 |
# File 'lib/valkyrie/persistence/fedora/list_node.rb', line 95 def graph @graph end |
#uri ⇒ Object (readonly)
Returns the value of attribute uri.
95 96 97 |
# File 'lib/valkyrie/persistence/fedora/list_node.rb', line 95 def uri @uri end |
Instance Method Details
#populate(instance) ⇒ Object
Populates attributes for the LinkedNode
106 107 108 109 110 111 |
# File 'lib/valkyrie/persistence/fedora/list_node.rb', line 106 def populate(instance) instance.proxy_for = resource.proxy_for instance.proxy_in = resource.proxy_in instance.next_uri = resource.next instance.prev_uri = resource.prev end |