Class: JavaClass::StackMapTableAttribute
- Defined in:
- lib/javaclass/attribute.rb
Overview
スタックマップテーブル属性
Instance Attribute Summary collapse
-
#stack_map_frame_entries ⇒ Object
Returns the value of attribute stack_map_frame_entries.
Attributes inherited from Attribute
Instance Method Summary collapse
-
#initialize(java_class, name_index, stack_map_frame_entries = []) ⇒ StackMapTableAttribute
constructor
コンストラクタ.
- #to_bytes ⇒ Object
Methods inherited from Attribute
Methods included from Base
#==, #===, #dump, #eql?, #hash, #to_byte
Constructor Details
#initialize(java_class, name_index, stack_map_frame_entries = []) ⇒ StackMapTableAttribute
コンストラクタ
*java_class::属性の所有者であるJavaクラス *name_index::名前を示すconstant_poolのインデックス *stack_map_frame_entries::スタックマップフレームエントリ
1077 1078 1079 1080 |
# File 'lib/javaclass/attribute.rb', line 1077 def initialize( java_class, name_index, stack_map_frame_entries=[] ) super( java_class, name_index) @stack_map_frame_entries = stack_map_frame_entries end |
Instance Attribute Details
#stack_map_frame_entries ⇒ Object
Returns the value of attribute stack_map_frame_entries.
1090 1091 1092 |
# File 'lib/javaclass/attribute.rb', line 1090 def stack_map_frame_entries @stack_map_frame_entries end |
Instance Method Details
#to_bytes ⇒ Object
1081 1082 1083 1084 1085 1086 1087 1088 1089 |
# File 'lib/javaclass/attribute.rb', line 1081 def to_bytes bytes = super body = to_byte( @stack_map_frame_entries.length, 2 ) @stack_map_frame_entries.each {|e| body += e.to_bytes() } bytes += to_byte( body.length, 4 ) bytes += body end |