1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
use crate::header::AccessFlags;
use crate::mutf8;
use crate::reader::cpool;
use crate::reader::decoding::*;
use crate::MStr;

use super::FromAttribute;

dec_structure! {
    pub struct Exceptions<'input> into {
        exceptions: DecodeMany<'input, cpool::Index<cpool::Class<'input>>, u16>,
    }
}

impl<'input> FromAttribute<'input> for Exceptions<'input> {
    const NAME: &'static MStr = mutf8!("Exceptions");
}

dec_structure! {
    pub struct MethodParameters<'input> into {
        parameters: DecodeMany<'input, MethodParameter<'input>, u8>,
    }
}

impl<'input> FromAttribute<'input> for MethodParameters<'input> {
    const NAME: &'static MStr = mutf8!("MethodParameters");
}

dec_structure! {
    pub struct MethodParameter<'input> {
        name: cpool::Index<cpool::Utf8<'input>>,
        access_flags: AccessFlags,
    }
}