pub struct AttributeWriter<Ctx, State: State> { /* private fields */ }

Implementations§

source§

impl<Ctx: EncoderContext> AttributeWriter<CodeWriter<Ctx, Attributes>, Start>

source

pub fn line_number_table<F>( self, f: F ) -> Result<AttributeWriter<CodeWriter<Ctx, Attributes>, End>, EncodeError>
where F: for<'g> FnOnce(&mut ManyWriter<LineNumberWriter<Ctx, Start>, u16>) -> Result<(), EncodeError>,

source§

impl<Ctx: EncoderContext> AttributeWriter<CodeWriter<Ctx, Attributes>, Start>

source

pub fn local_variable_table<F>( self, f: F ) -> Result<AttributeWriter<CodeWriter<Ctx, Attributes>, End>, EncodeError>
where F: for<'g> FnOnce(&mut ManyWriter<LocalVariableWriter<Ctx, Start>, u16>) -> Result<(), EncodeError>,

source§

impl<Ctx: EncoderContext> AttributeWriter<CodeWriter<Ctx, Attributes>, Start>

source

pub fn local_variable_type_table<F>( self, f: F ) -> Result<AttributeWriter<CodeWriter<Ctx, Attributes>, End>, EncodeError>
where F: for<'g> FnOnce(&mut ManyWriter<LocalVariableTypeWriter<Ctx, Start>, u16>) -> Result<(), EncodeError>,

source§

impl<Ctx: EncoderContext> AttributeWriter<CodeWriter<Ctx, Attributes>, Start>

source

pub fn stack_map_table<F>( self, f: F ) -> Result<AttributeWriter<CodeWriter<Ctx, Attributes>, End>, EncodeError>
where F: FnOnce(&mut StackMapTableWriter<Ctx>) -> Result<(), EncodeError>,

source§

impl<Ctx: EncoderContext> AttributeWriter<Ctx, Start>

source

pub fn code<F>(self, f: F) -> Result<AttributeWriter<Ctx, End>, EncodeError>
where F: FnOnce(CodeWriter<Ctx, MaxStack>) -> Result<CodeWriter<Ctx, End>, EncodeError>,

source§

impl<Ctx: EncoderContext> AttributeWriter<Ctx, Start>

source

pub fn source_file<I>( self, file_name: I ) -> Result<AttributeWriter<Ctx, End>, EncodeError>
where I: Insertable<Utf8>,

source

pub fn source_debug_extension<I>( self, debug_extension: I ) -> Result<AttributeWriter<Ctx, End>, EncodeError>
where I: Into<MString>,

source

pub fn synthetic(self) -> Result<AttributeWriter<Ctx, End>, EncodeError>

source

pub fn deprecated(self) -> Result<AttributeWriter<Ctx, End>, EncodeError>

source

pub fn signature<I>( self, signature: I ) -> Result<AttributeWriter<Ctx, End>, EncodeError>
where I: Insertable<Utf8>,

source§

impl<Ctx: EncoderContext> AttributeWriter<Ctx, Start>

source

pub fn enclosing_method<F>( self, f: F ) -> Result<AttributeWriter<Ctx, End>, EncodeError>
where F: FnOnce(&mut ManyWriter<EnclosingMethodWriter<Ctx, Class>, u16>) -> Result<(), EncodeError>,

source§

impl<Ctx: EncoderContext> AttributeWriter<Ctx, Start>

source

pub fn constant_value<I>( self, value: I ) -> Result<AttributeWriter<Ctx, End>, EncodeError>
where I: Insertable<Item>,

source§

impl<Ctx: EncoderContext> AttributeWriter<Ctx, Start>

source

pub fn inner_classes<F>( self, f: F ) -> Result<AttributeWriter<Ctx, End>, EncodeError>
where F: FnOnce(&mut ManyWriter<InnerClassWriter<Ctx, InnerClass>, u16>) -> Result<(), EncodeError>,

source§

impl<Ctx: EncoderContext> AttributeWriter<Ctx, Start>

source

pub fn exceptions<F>( self, f: F ) -> Result<AttributeWriter<Ctx, End>, EncodeError>
where F: FnOnce(&mut ManyWriter<ExceptionWriter<Ctx, Start>, u16>) -> Result<(), EncodeError>,

source§

impl<Ctx: EncoderContext> AttributeWriter<Ctx, Start>

source

pub fn raw_attribute<I>( self, name: I, bytes: &[u8] ) -> Result<AttributeWriter<Ctx, End>, EncodeError>
where I: Insertable<Utf8>,

Trait Implementations§

source§

impl<Ctx, State: State> Debug for AttributeWriter<Ctx, State>

source§

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

Formats the value using the given formatter. Read more

Auto Trait Implementations§

§

impl<Ctx, State> Freeze for AttributeWriter<Ctx, State>
where State: Sealed, Ctx: Freeze,

§

impl<Ctx, State> RefUnwindSafe for AttributeWriter<Ctx, State>
where State: Sealed + RefUnwindSafe, Ctx: RefUnwindSafe,

§

impl<Ctx, State> Send for AttributeWriter<Ctx, State>
where State: Sealed + Send, Ctx: Send,

§

impl<Ctx, State> Sync for AttributeWriter<Ctx, State>
where State: Sealed + Sync, Ctx: Sync,

§

impl<Ctx, State> Unpin for AttributeWriter<Ctx, State>
where State: Sealed + Unpin, Ctx: Unpin,

§

impl<Ctx, State> UnwindSafe for AttributeWriter<Ctx, State>
where State: Sealed + UnwindSafe, Ctx: UnwindSafe,

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>,

§

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>,

§

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.