Class: LD4L::WorksRDF::PopulateGraphFromTurtle
- Inherits:
-
Object
- Object
- LD4L::WorksRDF::PopulateGraphFromTurtle
- Defined in:
- lib/ld4l/works_rdf/services/repository_services/populate_graph_from_turtle.rb
Class Method Summary collapse
-
.call(turtle) ⇒ Object
Create an RDF::Graph populated turtle triples.
Class Method Details
.call(turtle) ⇒ Object
Create an RDF::Graph populated turtle triples
11 12 13 14 15 16 |
# File 'lib/ld4l/works_rdf/services/repository_services/populate_graph_from_turtle.rb', line 11 def self.call( turtle ) raise ArgumentError, 'turtle argument must be a non-empty string' unless turtle.kind_of?(String) && turtle.size > 0 RDF::Graph.new.from_ttl turtle end |