class Eol::Search

Contains search results from the Encyclopedia of Life database.

Attributes

content[RW]

@return [String] classification content

id[RW]

@return [Integer] the id of the species

title[RW]

@return [String] title of the entry

Public Class Methods

new(response) click to toggle source
# File lib/eol/search.rb, line 16
def initialize(response)
  self.id = response['id']
  self.title = response['title']
  self.link = response['link']
  self.content = response['content']
end

Public Instance Methods

each() { |id| ... } click to toggle source
# File lib/eol/search.rb, line 23
def each
  yield @id
  yield @title
  yield @link
  yield @content
end