Struct genco::java::Field
[−]
[src]
pub struct Field<'el> { pub annotations: Tokens<'el, Java<'el>>, pub modifiers: Vec<Modifier>, // some fields omitted }
Model for Java Fields.
Fields
annotations: Tokens<'el, Java<'el>>
Annotations of field.
modifiers: Vec<Modifier>
Modifiers of field.
Methods
impl<'el> Field<'el>
[src]
fn new<T, N>(ty: T, name: N) -> Field<'el> where
T: Into<Java<'el>>,
N: Into<Cons<'el>>,
[src]
T: Into<Java<'el>>,
N: Into<Cons<'el>>,
Create a new field.
fn annotation<A>(&mut self, annotation: A) where
A: IntoTokens<'el, Java<'el>>,
[src]
A: IntoTokens<'el, Java<'el>>,
Push an annotation.
fn initializer<I>(&mut self, initializer: I) where
I: IntoTokens<'el, Java<'el>>,
[src]
I: IntoTokens<'el, Java<'el>>,
Set initializer for field.
fn var(&self) -> Cons<'el>
[src]
The variable of the field.
fn ty(&self) -> Java<'el>
[src]
The type of the field.
Trait Implementations
impl<'el> Debug for Field<'el>
[src]
impl<'el> Clone for Field<'el>
[src]
fn clone(&self) -> Field<'el>
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl<'el> IntoTokens<'el, Java<'el>> for Field<'el>
[src]
fn into_tokens(self) -> Tokens<'el, Java<'el>>
[src]
Convert the type into tokens.