Class: Fizzy::Types::Reaction

Inherits:
Data
  • Object
show all
Defined in:
lib/fizzy/generated/types.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Attribute Details

#contentObject (readonly)

Returns the value of attribute content

Returns:

  • (Object)

    the current value of content



784
785
786
# File 'lib/fizzy/generated/types.rb', line 784

def content
  @content
end

#idObject (readonly)

Returns the value of attribute id

Returns:

  • (Object)

    the current value of id



784
785
786
# File 'lib/fizzy/generated/types.rb', line 784

def id
  @id
end

#reacterObject (readonly)

Returns the value of attribute reacter

Returns:

  • (Object)

    the current value of reacter



784
785
786
# File 'lib/fizzy/generated/types.rb', line 784

def reacter
  @reacter
end

#urlObject (readonly)

Returns the value of attribute url

Returns:

  • (Object)

    the current value of url



784
785
786
# File 'lib/fizzy/generated/types.rb', line 784

def url
  @url
end

Class Method Details

.from_json(data) ⇒ Object

Parameters:

  • data (Hash)

    raw JSON response



786
787
788
789
790
791
792
793
# File 'lib/fizzy/generated/types.rb', line 786

def self.from_json(data)
  new(
    id: data["id"],
    content: data["content"],
    reacter: data["reacter"],
    url: data["url"]
  )
end