Class: Webpipe::MapLink

Inherits:
Struct
  • Object
show all
Defined in:
lib/webpipe/types.rb

Overview

A URL discovered by the Map endpoint.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Attribute Details

#descriptionObject

Returns the value of attribute description

Returns:

  • (Object)

    the current value of description



39
40
41
# File 'lib/webpipe/types.rb', line 39

def description
  @description
end

#titleObject

Returns the value of attribute title

Returns:

  • (Object)

    the current value of title



39
40
41
# File 'lib/webpipe/types.rb', line 39

def title
  @title
end

#urlObject

Returns the value of attribute url

Returns:

  • (Object)

    the current value of url



39
40
41
# File 'lib/webpipe/types.rb', line 39

def url
  @url
end

Class Method Details

.from_hash(hash) ⇒ Object



40
41
42
# File 'lib/webpipe/types.rb', line 40

def self.from_hash(hash)
  new(hash["url"], hash["title"], hash["description"])
end