Enum Attribute

Source
pub enum Attribute {
    ConstantValue {
        attribute_name_index: u16,
        attribute_length: u32,
        constantvalue_index: u16,
    },
    Code {
        attribute_name_index: u16,
        attribute_length: u32,
        max_stack: u16,
        max_locals: u16,
        code_length: u32,
        code: Vec<Instruction>,
        exception_table_length: u16,
        exception_table: Vec<ExceptionTableEntry>,
        attributes_count: u16,
        attributes: Vec<Attribute>,
    },
    InnerClasses {
        attribute_name_index: u16,
        attribute_length: u32,
        number_of_classes: u16,
        classes: Vec<InnerClassAttribute>,
    },
    SourceFile {
        attribute_name_index: u16,
        attribute_length: u32,
        sourcefile_index: u16,
    },
    LineNumberTable {
        attribute_name_index: u16,
        attribute_length: u32,
        line_number_table_length: u16,
        line_number_table: Vec<LineNumberTableEntry>,
    },
    BootstrapMethods {
        attribute_name_index: u16,
        attribute_length: u32,
        num_bootstrap_methods: u16,
        bootstrap_methods: Vec<BootstrapMethodAttribute>,
    },
    MethodParameters {
        attribute_name_index: u16,
        attribute_length: u32,
        parameters_count: u8,
        parameters: Vec<ParameterAttribute>,
    },
    NestMembers {
        attribute_name_index: u16,
        attribute_length: u32,
        number_of_classes: u16,
        classes: Vec<u16>,
    },
}

Variants§

§

ConstantValue

Fields

§attribute_name_index: u16
§attribute_length: u32
§constantvalue_index: u16
§

Code

Fields

§attribute_name_index: u16
§attribute_length: u32
§max_stack: u16
§max_locals: u16
§code_length: u32
§exception_table_length: u16
§exception_table: Vec<ExceptionTableEntry>
§attributes_count: u16
§attributes: Vec<Attribute>
§

InnerClasses

Fields

§attribute_name_index: u16
§attribute_length: u32
§number_of_classes: u16
§

SourceFile

Fields

§attribute_name_index: u16
§attribute_length: u32
§sourcefile_index: u16
§

LineNumberTable

Fields

§attribute_name_index: u16
§attribute_length: u32
§line_number_table_length: u16
§line_number_table: Vec<LineNumberTableEntry>
§

BootstrapMethods

Fields

§attribute_name_index: u16
§attribute_length: u32
§num_bootstrap_methods: u16
§bootstrap_methods: Vec<BootstrapMethodAttribute>
§

MethodParameters

Fields

§attribute_name_index: u16
§attribute_length: u32
§parameters_count: u8
§

NestMembers

Fields

§attribute_name_index: u16
§attribute_length: u32
§number_of_classes: u16
§classes: Vec<u16>

Trait Implementations§

Source§

impl Debug for Attribute

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.