pub struct Fields<'p> {
pub parent: FieldParent<'p>,
/* private fields */
}
Fields§
§parent: FieldParent<'p>
Implementations§
source§impl<'f> Fields<'f>
impl<'f> Fields<'f>
pub fn iter(self) -> impl Iterator<Item = Field<'f>> + Clone
pub fn is_empty(self) -> bool
pub fn count(self) -> usize
pub fn are_named(self) -> bool
pub fn are_unnamed(self) -> bool
pub fn are_unit(self) -> bool
pub fn match_tokens(self) -> TokenStream
pub fn builder<F>(&self, f: F) -> TokenStreamwhere F: Fn(Field<'_>) -> TokenStream,
Trait Implementations§
source§impl<'a> ToTokens for Fields<'a>
impl<'a> ToTokens for Fields<'a>
source§fn to_tokens(&self, tokens: &mut TokenStream)
fn to_tokens(&self, tokens: &mut TokenStream)
source§fn to_token_stream(&self) -> TokenStream
fn to_token_stream(&self) -> TokenStream
source§fn into_token_stream(self) -> TokenStreamwhere
Self: Sized,
fn into_token_stream(self) -> TokenStreamwhere Self: Sized,
impl<'p> Copy for Fields<'p>
Auto Trait Implementations§
impl<'p> RefUnwindSafe for Fields<'p>
impl<'p> !Send for Fields<'p>
impl<'p> !Sync for Fields<'p>
impl<'p> Unpin for Fields<'p>
impl<'p> UnwindSafe for Fields<'p>
Blanket Implementations§
source§impl<T> AstItemExt for Twhere
T: ToTokens,
impl<T> AstItemExt for Twhere T: ToTokens,
fn respanned(&self, span: Span) -> Twhere T: Parse,
fn respanned_tokens(&self, span: Span) -> TokenStream
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> Spanned for Twhere
T: Spanned + ?Sized,
impl<T> Spanned for Twhere T: Spanned + ?Sized,
source§fn span(&self) -> Span
fn span(&self) -> Span
Returns a
Span
covering the complete contents of this syntax tree
node, or Span::call_site()
if this node is empty.