Class: Furnace::AVM2::ABC::ExceptionInfo

Inherits:
Record show all
Defined in:
lib/furnace-avm2/abc/metadata/exception_info.rb

Instance Attribute Summary collapse

Attributes inherited from Binary::Record

#root

Instance Method Summary collapse

Methods inherited from Record

abc_array_of, flag, pool_array, pool_array_of, pool_ref, subset, xlat_direct, xlat_field, xlat_inverse

Methods inherited from Binary::Record

#byte_length, codegen, codegen_each, inherited, #inspect, method_missing, register, #to_hash, trace, trace_scope, trace_value

Instance Attribute Details

#fromObject (readonly)

Returns the value of attribute from.



9
10
11
# File 'lib/furnace-avm2/abc/metadata/exception_info.rb', line 9

def from
  @from
end

#targetObject (readonly)

Returns the value of attribute target.



9
10
11
# File 'lib/furnace-avm2/abc/metadata/exception_info.rb', line 9

def target
  @target
end

#toObject (readonly)

Returns the value of attribute to.



9
10
11
# File 'lib/furnace-avm2/abc/metadata/exception_info.rb', line 9

def to
  @to
end

Instance Method Details

#initialize_record(options) ⇒ Object



11
12
13
# File 'lib/furnace-avm2/abc/metadata/exception_info.rb', line 11

def initialize_record(options)
  @parent = options[:parent]
end

#lookup!Object



23
24
25
26
27
# File 'lib/furnace-avm2/abc/metadata/exception_info.rb', line 23

def lookup!
  self.from_offset   = @from.offset
  self.to_offset     = @to.offset
  self.target_offset = @target.offset
end

#resolve!Object



15
16
17
18
19
20
21
# File 'lib/furnace-avm2/abc/metadata/exception_info.rb', line 15

def resolve!
  sequence = @parent.code

  @from   = sequence.opcode_at(from_offset)
  @to     = sequence.opcode_at(to_offset)
  @target = sequence.opcode_at(target_offset)
end