Module: Krikri::MappingDSL::RdfSubjects

Included in:
Krikri::MappingDSL
Defined in:
lib/krikri/mapping_dsl/rdf_subjects.rb

Overview

Methods for setting URI/ActiveTriples #rdf_subject values in MappingDSL

Defined Under Namespace

Classes: SubjectDeclaration

Instance Method Summary collapse

Instance Method Details

#uri(value, &block) ⇒ Object


5
6
7
8
# File 'lib/krikri/mapping_dsl/rdf_subjects.rb', line 5

def uri(value, &block)
  properties.delete_if { |prop| prop.is_a? SubjectDeclaration }
  properties << SubjectDeclaration.new(nil, value, &block)
end