Module: Rankable
- Extended by:
- ActiveSupport::Concern
- Defined in:
- app/models/concerns/rankable.rb
Defined Under Namespace
Modules: ClassMethods
Instance Method Summary collapse
Instance Method Details
#build_rdf(document, subject, suppress_extra_labels = false) ⇒ Object
6 7 8 9 10 11 12 13 14 15 16 |
# File 'app/models/concerns/rankable.rb', line 6 def build_rdf(document, subject, suppress_extra_labels = false) super if self.class.rankable? predicate = "ranked#{rdf_predicate.titleize}" subject.Schema.build_predicate(predicate) do |blank_node| blank_node.Schema.relationWeight(rank) blank_node.Schema.relationTarget(IqRdf.build_uri(target.origin)) end end end |