Struct anitomy_sys::Elements [−][src]
#[repr(C)]pub struct Elements { /* fields omitted */ }
The collection of elements parsed from a filename by Anitomy.
Methods
impl Elements
[src]
impl Elements
pub unsafe fn empty<C: Into<Option<ElementCategory>>>(
&self,
category: C
) -> bool
[src]
pub unsafe fn empty<C: Into<Option<ElementCategory>>>(
&self,
category: C
) -> bool
Determines whether there are no elements of a given category.
Passing None
will check for any elements at all.
pub unsafe fn count<C: Into<Option<ElementCategory>>>(
&self,
category: C
) -> usize
[src]
pub unsafe fn count<C: Into<Option<ElementCategory>>>(
&self,
category: C
) -> usize
Counts the number of elements of a given category.
Passing None
will count all elements.
pub unsafe fn at(&self, pos: usize) -> Option<Element>
[src]
pub unsafe fn at(&self, pos: usize) -> Option<Element>
Get the element at the given position if one exists.
pub unsafe fn get(&self, category: ElementCategory) -> String
[src]
pub unsafe fn get(&self, category: ElementCategory) -> String
Gets the first element of a category if one exists, otherwise returns an empty string.
pub unsafe fn get_all(&self, category: ElementCategory) -> Vec<String>
[src]
pub unsafe fn get_all(&self, category: ElementCategory) -> Vec<String>
Gets all elements of a category.