pub struct ClassFile {
pub minor_version: u16,
pub major_version: u16,
pub constant_pool: Vec<ConstantPoolEntry>,
pub access_flags: ClassAccessFlags,
pub this_class: u16,
pub super_class: u16,
pub interfaces: Vec<u16>,
pub fields: Vec<FieldInfo>,
pub methods: Vec<MethodInfo>,
pub attributes: Vec<AttributeInfo>,
}Expand description
Parsed Java class file.
Fields§
§minor_version: u16§major_version: u16§constant_pool: Vec<ConstantPoolEntry>§access_flags: ClassAccessFlags§this_class: u16§super_class: u16§interfaces: Vec<u16>§fields: Vec<FieldInfo>§methods: Vec<MethodInfo>§attributes: Vec<AttributeInfo>Implementations§
Source§impl ClassFile
impl ClassFile
Sourcepub fn this_class_name(&self) -> Option<&str>
pub fn this_class_name(&self) -> Option<&str>
Resolve the class name from this_class index.
Sourcepub fn super_class_name(&self) -> Option<&str>
pub fn super_class_name(&self) -> Option<&str>
Resolve the super class name from super_class index.
Sourcepub fn method_name(&self, method: &MethodInfo) -> Option<&str>
pub fn method_name(&self, method: &MethodInfo) -> Option<&str>
Get the name of a method from its name_index.
Sourcepub fn method_descriptor(&self, method: &MethodInfo) -> Option<&str>
pub fn method_descriptor(&self, method: &MethodInfo) -> Option<&str>
Get the descriptor of a method from its descriptor_index.
Sourcepub fn field_name(&self, field: &FieldInfo) -> Option<&str>
pub fn field_name(&self, field: &FieldInfo) -> Option<&str>
Get the name of a field from its name_index.
Sourcepub fn field_descriptor(&self, field: &FieldInfo) -> Option<&str>
pub fn field_descriptor(&self, field: &FieldInfo) -> Option<&str>
Get the descriptor of a field from its descriptor_index.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for ClassFile
impl RefUnwindSafe for ClassFile
impl Send for ClassFile
impl Sync for ClassFile
impl Unpin for ClassFile
impl UnsafeUnpin for ClassFile
impl UnwindSafe for ClassFile
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more