IntoItem

Trait IntoItem 

Source
pub trait IntoItem {
    // Required method
    fn into_item(self, visibility: Visibility) -> Item;

    // Provided methods
    fn into_inherited_item(self) -> Item
       where Self: Sized { ... }
    fn into_public_item(self) -> Item
       where Self: Sized { ... }
    fn into_scoped_item(self, scope: VisibilityScope) -> Item
       where Self: Sized { ... }
}

Required Methods§

Source

fn into_item(self, visibility: Visibility) -> Item

Creates an item with the given visibility.

Provided Methods§

Source

fn into_inherited_item(self) -> Item
where Self: Sized,

Creates an item with inherited (mostly private) visibility.

Source

fn into_public_item(self) -> Item
where Self: Sized,

Creates an item with public visibility.

Source

fn into_scoped_item(self, scope: VisibilityScope) -> Item
where Self: Sized,

Creates an item with the given visibility scope.

Implementors§