Class: DOWL::Person
Instance Attribute Summary
Attributes inherited from DocObject
Instance Method Summary collapse
- #<=>(other) ⇒ Object
-
#initialize(resource, schema) ⇒ Person
constructor
A new instance of Person.
- #name ⇒ Object
- #uri ⇒ Object
Methods inherited from DocObject
Constructor Details
#initialize(resource, schema) ⇒ Person
Returns a new instance of Person.
6 7 8 |
# File 'lib/dowl/ontology.rb', line 6 def initialize(resource, schema) super(resource, schema) end |
Instance Method Details
#<=>(other) ⇒ Object
22 23 24 |
# File 'lib/dowl/ontology.rb', line 22 def <=>(other) return name() <=> other.name() end |
#name ⇒ Object
14 15 16 17 18 19 20 |
# File 'lib/dowl/ontology.rb', line 14 def name() name = get_literal(DOWL::Namespaces::FOAF.name) if name == nil name = uri() end return name end |
#uri ⇒ Object
10 11 12 |
# File 'lib/dowl/ontology.rb', line 10 def uri() return @resource.to_s end |