Class: TRMNL::API::Models::Display

Inherits:
Struct
  • Object
show all
Defined in:
lib/trmnl/api/models/display.rb

Overview

Models data for API display responses.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeDisplay

Returns a new instance of Display.



19
20
21
22
23
# File 'lib/trmnl/api/models/display.rb', line 19

def initialize(**)
  super
  apply_defaults
  freeze
end

Instance Attribute Details

#filenameObject

Returns the value of attribute filename

Returns:

  • (Object)

    the current value of filename



7
8
9
# File 'lib/trmnl/api/models/display.rb', line 7

def filename
  @filename
end

#firmware_urlObject

Returns the value of attribute firmware_url

Returns:

  • (Object)

    the current value of firmware_url



7
8
9
# File 'lib/trmnl/api/models/display.rb', line 7

def firmware_url
  @firmware_url
end

#image_urlObject

Returns the value of attribute image_url

Returns:

  • (Object)

    the current value of image_url



7
8
9
# File 'lib/trmnl/api/models/display.rb', line 7

def image_url
  @image_url
end

#image_url_timeoutObject

Returns the value of attribute image_url_timeout

Returns:

  • (Object)

    the current value of image_url_timeout



7
8
9
# File 'lib/trmnl/api/models/display.rb', line 7

def image_url_timeout
  @image_url_timeout
end

#refresh_rateObject

Returns the value of attribute refresh_rate

Returns:

  • (Object)

    the current value of refresh_rate



7
8
9
# File 'lib/trmnl/api/models/display.rb', line 7

def refresh_rate
  @refresh_rate
end

#reset_firmwareObject

Returns the value of attribute reset_firmware

Returns:

  • (Object)

    the current value of reset_firmware



7
8
9
# File 'lib/trmnl/api/models/display.rb', line 7

def reset_firmware
  @reset_firmware
end

#special_functionObject

Returns the value of attribute special_function

Returns:

  • (Object)

    the current value of special_function



7
8
9
# File 'lib/trmnl/api/models/display.rb', line 7

def special_function
  @special_function
end

#update_firmwareObject

Returns the value of attribute update_firmware

Returns:

  • (Object)

    the current value of update_firmware



7
8
9
# File 'lib/trmnl/api/models/display.rb', line 7

def update_firmware
  @update_firmware
end

Class Method Details

.for(attributes) ⇒ Object



17
# File 'lib/trmnl/api/models/display.rb', line 17

def self.for(attributes) = new(**attributes)

Instance Method Details

#to_jsonObject



25
# File 'lib/trmnl/api/models/display.rb', line 25

def to_json(*) = to_h.to_json(*)