Class: ImgToScript::AbstractToken::DrawChunkByHexValue

Inherits:
AbstractToken
  • Object
show all
Defined in:
lib/img_to_script/abstract_token/draw_chunk_by_hex_value.rb

Overview

Draw 8x1 px block of pixels encoded by a hex value.

Instance Attribute Summary collapse

Attributes inherited from AbstractToken

#require_nl, #type

Instance Method Summary collapse

Constructor Details

#initialize(hex_values:) ⇒ DrawChunkByHexValue

Returns a new instance of DrawChunkByHexValue.



11
12
13
14
15
16
# File 'lib/img_to_script/abstract_token/draw_chunk_by_hex_value.rb', line 11

def initialize(hex_values:, **)
  @type = AbsTokenType::DRAW_CHUNK_BY_HEX_VALUE
  @hex_values = Array(hex_values)

  super
end

Instance Attribute Details

#hex_valuesObject (readonly)

Returns the value of attribute hex_values.



9
10
11
# File 'lib/img_to_script/abstract_token/draw_chunk_by_hex_value.rb', line 9

def hex_values
  @hex_values
end