Struct genco::csharp::Enum [−][src]
pub struct Enum<'el> { pub variants: Tokens<'el, Csharp<'el>>, pub modifiers: Vec<Modifier>, pub implements: Vec<Csharp<'el>>, // some fields omitted }
Model for Csharp Enums.
Fields
variants: Tokens<'el, Csharp<'el>>
Variants of the enum.
modifiers: Vec<Modifier>
Enum modifiers.
implements: Vec<Csharp<'el>>
What this enum implements.
Methods
impl<'el> Enum<'el>
[src]
impl<'el> Enum<'el>
pub fn new<N>(name: N) -> Enum<'el> where
N: Into<Cons<'el>>,
[src]
pub fn new<N>(name: N) -> Enum<'el> where
N: Into<Cons<'el>>,
Build a new empty interface.
pub fn attribute<T>(&mut self, attribute: T) where
T: IntoTokens<'el, Csharp<'el>>,
[src]
pub fn attribute<T>(&mut self, attribute: T) where
T: IntoTokens<'el, Csharp<'el>>,
Push an attribute.
pub fn name(&self) -> Cons<'el>
[src]
pub fn name(&self) -> Cons<'el>
Name of enum.
Trait Implementations
impl<'el> Debug for Enum<'el>
[src]
impl<'el> Debug for Enum<'el>
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl<'el> Clone for Enum<'el>
[src]
impl<'el> Clone for Enum<'el>
fn clone(&self) -> Enum<'el>
[src]
fn clone(&self) -> Enum<'el>
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
1.0.0
[src]Performs copy-assignment from source
. Read more
impl<'el> From<Enum<'el>> for Tokens<'el, Csharp<'el>>
[src]
impl<'el> From<Enum<'el>> for Tokens<'el, Csharp<'el>>
impl<'el> IntoTokens<'el, Csharp<'el>> for Enum<'el>
[src]
impl<'el> IntoTokens<'el, Csharp<'el>> for Enum<'el>
fn into_tokens(self) -> Tokens<'el, Csharp<'el>>
[src]
fn into_tokens(self) -> Tokens<'el, Csharp<'el>>
Convert the type into tokens.