Class: C8dasm::CommentBase

Inherits:
Object
  • Object
show all
Defined in:
lib/c8dasm/comments/comment_base.rb

Instance Method Summary collapse

Constructor Details

#initialize(opcode) ⇒ CommentBase

Returns a new instance of CommentBase.



5
6
7
# File 'lib/c8dasm/comments/comment_base.rb', line 5

def initialize(opcode)
  @opcode = opcode
end

Instance Method Details

#kkObject



13
14
15
# File 'lib/c8dasm/comments/comment_base.rb', line 13

def kk
  @opcode[2, 2]
end

#nnnObject



9
10
11
# File 'lib/c8dasm/comments/comment_base.rb', line 9

def nnn
  @opcode[1, 3]
end

#xObject



17
18
19
# File 'lib/c8dasm/comments/comment_base.rb', line 17

def x
  @opcode[1]
end

#yObject



21
22
23
# File 'lib/c8dasm/comments/comment_base.rb', line 21

def y
  @opcode[2]
end