Skip to content

Commit

Permalink
add Agent class
Browse files Browse the repository at this point in the history
  • Loading branch information
elrayle committed Feb 18, 2015
1 parent 5f167cc commit 6a181ff
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 1 deletion.
1 change: 1 addition & 0 deletions lib/ld4l/foaf_rdf.rb
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ def self.configure
# autoload classes
autoload :Configuration, 'ld4l/foaf_rdf/configuration'
autoload :Person, 'ld4l/foaf_rdf/person'
autoload :Agent, 'ld4l/foaf_rdf/agent'

def self.class_from_string(class_name, container_class=Kernel)
container_class = container_class.name if container_class.is_a? Module
Expand Down
13 changes: 13 additions & 0 deletions lib/ld4l/foaf_rdf/agent.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
module LD4L
module FoafRDF
class Agent < ActiveTriples::Resource

class << self; attr_reader :localname_prefix end
@localname_prefix="a"

configure :type => RDF::FOAF.Agent, :base_uri => LD4L::FoafRDF.configuration.base_uri, :repository => :default

property :label, :predicate => RDF::RDFS.label
end
end
end
2 changes: 1 addition & 1 deletion lib/ld4l/foaf_rdf/version.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
module LD4L
module FoafRDF
VERSION = "0.0.6"
VERSION = "0.0.7"
end
end

0 comments on commit 6a181ff

Please sign in to comment.