class Camdram::Person
Attributes
name[RW]
slug[RW]
Public Class Methods
url()
click to toggle source
Returns the URL stub assocaited with all people
@return [String] The URL stub.
# File lib/camdram/person.rb, line 30 def self.url '/people' end
Public Instance Methods
info()
click to toggle source
Return a hash of the person's attributes
@return [Hash] Hash with symbolized keys.
# File lib/camdram/person.rb, line 12 def info { id: id, name: name, slug: slug, } end
url_slug()
click to toggle source
Returns the URL+slug of the person
@return [String] The full URL and slug.
# File lib/camdram/person.rb, line 23 def url_slug "#{self.class.url}/#{slug}.json" end