Class: Panchira::PanchiraResult

Inherits:
Object
  • Object
show all
Defined in:
lib/panchira/panchira_result.rb

Overview

Result class for Panchira.fetch.

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#authorsObject

Returns the value of attribute authors.



11
12
13
# File 'lib/panchira/panchira_result.rb', line 11

def authors
  @authors
end

#canonical_urlObject

Returns the value of attribute canonical_url.



11
12
13
# File 'lib/panchira/panchira_result.rb', line 11

def canonical_url
  @canonical_url
end

#circleObject

Returns the value of attribute circle.



11
12
13
# File 'lib/panchira/panchira_result.rb', line 11

def circle
  @circle
end

#descriptionObject

Returns the value of attribute description.



11
12
13
# File 'lib/panchira/panchira_result.rb', line 11

def description
  @description
end

#imageObject

Returns the value of attribute image.



11
12
13
# File 'lib/panchira/panchira_result.rb', line 11

def image
  @image
end

#resolverObject

Returns the value of attribute resolver.



11
12
13
# File 'lib/panchira/panchira_result.rb', line 11

def resolver
  @resolver
end

#tagsObject

Returns the value of attribute tags.



11
12
13
# File 'lib/panchira/panchira_result.rb', line 11

def tags
  @tags
end

#titleObject

Returns the value of attribute title.



11
12
13
# File 'lib/panchira/panchira_result.rb', line 11

def title
  @title
end

Instance Method Details

#authorObject



13
14
15
# File 'lib/panchira/panchira_result.rb', line 13

def author
  authors&.join(' ')
end

#author=(value) ⇒ Object



17
18
19
# File 'lib/panchira/panchira_result.rb', line 17

def author=(value)
  self.authors = [value] if value
end