Class: JavaClass::AppendFrame

Inherits:
StackMapFrame show all
Defined in:
lib/javaclass/attribute.rb

Overview

append_frame

Instance Attribute Summary collapse

Attributes inherited from StackMapFrame

#frame_type

Instance Method Summary collapse

Methods included from Base

#==, #===, #dump, #eql?, #hash, #to_byte

Constructor Details

#initialize(frame_type, offset_delta, verification_type_info = []) ⇒ AppendFrame

コンストラクタ

*frame_type::種別

*offset_delta

オフセットデルタ

*verification_type_info

型情報



1232
1233
1234
1235
1236
# File 'lib/javaclass/attribute.rb', line 1232

def initialize(frame_type, offset_delta, verification_type_info=[])
  super(frame_type)
  @offset_delta = offset_delta
  @verification_type_info = verification_type_info
end

Instance Attribute Details

#offset_deltaObject

オフセットデルタ



1246
1247
1248
# File 'lib/javaclass/attribute.rb', line 1246

def offset_delta
  @offset_delta
end

#verification_type_infoObject

型情報



1248
1249
1250
# File 'lib/javaclass/attribute.rb', line 1248

def verification_type_info
  @verification_type_info
end

Instance Method Details

#to_bytesObject



1237
1238
1239
1240
1241
1242
1243
1244
# File 'lib/javaclass/attribute.rb', line 1237

def to_bytes
  bytes = super
  bytes += to_byte( offset_delta, 2 )
  verification_type_info.each {|v|
    bytes += v.to_bytes 
  }
  bytes
end