class ROF::Translators::JsonldToRof::PredicateObjectHandler::NodePredicateObjectHandler

@api private Blank Nodes; Oh how we love thee. Let me count the ways

Attributes

accumulator[R]
object[R]
options[R]
predicate[R]

Public Class Methods

new(predicate, object, accumulator, options) click to toggle source
# File lib/rof/translators/jsonld_to_rof/predicate_object_handler.rb, line 86
def initialize(predicate, object, accumulator, options)
  @predicate = predicate
  @object = object
  @accumulator = accumulator
  @options = options
end

Public Instance Methods

call() click to toggle source
# File lib/rof/translators/jsonld_to_rof/predicate_object_handler.rb, line 93
def call
  blank_node = accumulator.fetch_blank_node(object)
  blank_node.each_pair do |blank_node_predicate, blank_node_objects|
    blank_node_objects.each do |blank_node_object|
      PredicateObjectHandler.call(blank_node_predicate, blank_node_object, accumulator, blank_node: object)
    end
  end
  accumulator
end