Trait alloy_sol_macro_input::ContainsSolAttrs

source ·
pub trait ContainsSolAttrs {
    // Required method
    fn attrs(&self) -> &[Attribute];

    // Provided method
    fn split_attrs(&self) -> Result<(SolAttrs, Vec<Attribute>)> { ... }
}
Expand description

Trait for items that contain #[sol(...)] attributes among other attributes. This is usually a shortcut for SolAttrs::parse.

Required Methods§

source

fn attrs(&self) -> &[Attribute]

Get the list of attributes.

Provided Methods§

source

fn split_attrs(&self) -> Result<(SolAttrs, Vec<Attribute>)>

Parse the #[sol(...)] attributes from the list of attributes.

Implementations on Foreign Types§

source§

impl ContainsSolAttrs for File

source§

fn attrs(&self) -> &[Attribute]

source§

impl ContainsSolAttrs for ItemContract

source§

fn attrs(&self) -> &[Attribute]

source§

impl ContainsSolAttrs for ItemEnum

source§

fn attrs(&self) -> &[Attribute]

source§

impl ContainsSolAttrs for ItemError

source§

fn attrs(&self) -> &[Attribute]

source§

impl ContainsSolAttrs for ItemEvent

source§

fn attrs(&self) -> &[Attribute]

source§

impl ContainsSolAttrs for ItemFunction

source§

fn attrs(&self) -> &[Attribute]

source§

impl ContainsSolAttrs for ItemStruct

source§

fn attrs(&self) -> &[Attribute]

source§

impl ContainsSolAttrs for ItemUdt

source§

fn attrs(&self) -> &[Attribute]

Implementors§