class Java::Class

Constants

ACC_ABSTRACT
ACC_ANNOTATION
ACC_ENUM
ACC_FINAL
ACC_INTERFACE
ACC_PUBLIC
ACC_SUPER
ACC_SYNTHETIC

Attributes

fields[R]
flags[R]
interfaces[R]
methods[R]
super_klass[R]
this_klass[R]

Public Class Methods

new(major, minor, flags, this_klass, super_klass, interfaces, fields, methods, annotations) click to toggle source
Calls superclass method Java::Annotatable::new
# File lib/java_dissassembler/class.rb, line 14
def initialize(major, minor, flags, this_klass, super_klass, interfaces, fields, methods, annotations)
  super(annotations)
  @major = major
  @minor = minor
  @flags = flags
  @this_klass = this_klass
  @super_klass = super_klass
  @interfaces = interfaces
  @fields = fields
  @methods = methods
end

Public Instance Methods

is_abstract?() click to toggle source
# File lib/java_dissassembler/class.rb, line 42
def is_abstract?
  (@flags & ACC_ABSTRACT) != 0
end
is_annotation?() click to toggle source
# File lib/java_dissassembler/class.rb, line 50
def is_annotation?
  (@flags & ACC_ANNOTATION) != 0
end
is_enum?() click to toggle source
# File lib/java_dissassembler/class.rb, line 54
def is_enum?
  (@flags & ACC_ENUM) != 0
end
is_final?() click to toggle source
# File lib/java_dissassembler/class.rb, line 30
def is_final?
  (@flags & ACC_FINAL) != 0
end
is_interface?() click to toggle source
# File lib/java_dissassembler/class.rb, line 38
def is_interface?
  (@flags & ACC_INTERFACE) != 0
end
is_public?() click to toggle source
# File lib/java_dissassembler/class.rb, line 26
def is_public?
  (@flags & ACC_PUBLIC) != 0
end
is_super?() click to toggle source
# File lib/java_dissassembler/class.rb, line 34
def is_super?
  (@flags & ACC_SUPER) != 0
end
is_synthetic?() click to toggle source
# File lib/java_dissassembler/class.rb, line 46
def is_synthetic?
  (@flags & ACC_SYNTHETIC) != 0
end
java_version() click to toggle source
# File lib/java_dissassembler/class.rb, line 58
def java_version
  case @major
  when 46 then "1.2"
  when 47 then "1.3"
  when 48 then "1.4"
  when 49 then "5"
  when 50 then "6"
  when 51 then "7"
  when 52 then "8"
  when 53 then "9"
  end
end