pub struct Group { /* private fields */ }Expand description
A group of fields displayed together.
Implementations§
Source§impl Group
impl Group
Sourcepub fn description(self, description: impl Into<String>) -> Self
pub fn description(self, description: impl Into<String>) -> Self
Sets the group description.
Sourcepub fn hide_func<F: Fn() -> bool + Send + Sync + 'static>(self, f: F) -> Self
pub fn hide_func<F: Fn() -> bool + Send + Sync + 'static>(self, f: F) -> Self
Sets a function to determine if the group should be hidden.
Returns whether this group should be hidden.
Sourcepub fn current_field(&self) -> Option<&dyn Field>
pub fn current_field(&self) -> Option<&dyn Field>
Returns a reference to the current field.
Sourcepub fn current_field_mut(&mut self) -> Option<&mut Box<dyn Field>>
pub fn current_field_mut(&mut self) -> Option<&mut Box<dyn Field>>
Returns a mutable reference to the current field.
Sourcepub fn header(&self) -> String
pub fn header(&self) -> String
Returns the header portion of the group (title and description).
This is useful for custom layouts that want to render the header separately from the content.
Sourcepub fn content(&self) -> String
pub fn content(&self) -> String
Returns the content portion of the group (just the fields).
This is useful for custom layouts that want to render the content separately from the header and footer.
Returns the footer portion of the group (currently errors).
This is useful for custom layouts that want to render the footer separately from the content.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Group
impl !RefUnwindSafe for Group
impl Send for Group
impl Sync for Group
impl Unpin for Group
impl !UnwindSafe for Group
Blanket Implementations§
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