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.
96 97 98 99 |
# File 'lib/valkyrie/persistence/fedora/list_node.rb', line 96 def initialize(uri, graph) @uri = uri @graph = graph end |
Instance Attribute Details
#graph ⇒ Object (readonly)
Returns the value of attribute graph.
92 93 94 |
# File 'lib/valkyrie/persistence/fedora/list_node.rb', line 92 def graph @graph end |
#uri ⇒ Object (readonly)
Returns the value of attribute uri.
92 93 94 |
# File 'lib/valkyrie/persistence/fedora/list_node.rb', line 92 def uri @uri end |
Instance Method Details
#populate(instance) ⇒ Object
Populates attributes for the LinkedNode
103 104 105 106 107 108 |
# File 'lib/valkyrie/persistence/fedora/list_node.rb', line 103 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 |