Class: JavaClass::AnnotationElementValue
- Inherits:
-
Object
- Object
- JavaClass::AnnotationElementValue
- Includes:
- Base, Converters
- Defined in:
- lib/javaclass/attribute.rb
Overview
アノテーションデータの基底クラス
Direct Known Subclasses
AnnotationAnnotationElementValue, ArrayAnnotationElementValue, ClassAnnotationElementValue, ConstAnnotationElementValue, EnumAnnotationElementValue
Instance Attribute Summary collapse
-
#tag ⇒ Object
Returns the value of attribute tag.
Instance Method Summary collapse
-
#initialize(java_class, tag = nil) ⇒ AnnotationElementValue
constructor
コンストラクタ.
- #to_bytes ⇒ Object
Methods included from Converters
convert_code, convert_field_descriptor, convert_method_descriptor
Methods included from Base
#==, #===, #dump, #eql?, #hash, #to_byte
Constructor Details
#initialize(java_class, tag = nil) ⇒ AnnotationElementValue
コンストラクタ
*java_class::属性の所有者であるJavaクラス *tag::データの種別を示すconstant_poolのインデックス
534 535 536 537 |
# File 'lib/javaclass/attribute.rb', line 534 def initialize( java_class, tag=nil ) @java_class = java_class @tag = tag end |
Instance Attribute Details
#tag ⇒ Object
Returns the value of attribute tag.
542 543 544 |
# File 'lib/javaclass/attribute.rb', line 542 def tag @tag end |
Instance Method Details
#to_bytes ⇒ Object
538 539 540 |
# File 'lib/javaclass/attribute.rb', line 538 def to_bytes to_byte( @tag, 1) end |