Struct redox_users::AllGroups
source · pub struct AllGroups { /* private fields */ }Expand description
Implementations§
source§impl AllGroups
impl AllGroups
sourcepub fn add_group(&mut self, builder: GroupBuilder) -> Result<&Group, Error>
pub fn add_group(&mut self, builder: GroupBuilder) -> Result<&Group, Error>
Consumes a builder, adding a new group to this AllGroups. Returns a
reference to the created Group.
Make sure to call AllGroups::save in order for the new group to be
applied to the system.
Defaults
If a builder is not passed a group id (GroupBuilder::gid) before
being passed to this function, AllGroups::get_unique_id is used.
If the builder is not passed any users (GroupBuilder::user), the
group will still be created.
Trait Implementations§
source§impl All for AllGroups
impl All for AllGroups
source§fn get_mut_by_name(
&mut self,
name: impl AsRef<str>
) -> Option<&mut <Self as AllInner>::Gruser>
fn get_mut_by_name( &mut self, name: impl AsRef<str> ) -> Option<&mut <Self as AllInner>::Gruser>
Mutable version of
All::get_by_name.source§fn get_mut_by_id(
&mut self,
id: usize
) -> Option<&mut <Self as AllInner>::Gruser>
fn get_mut_by_id( &mut self, id: usize ) -> Option<&mut <Self as AllInner>::Gruser>
Mutable version of
All::get_by_id.source§fn get_unique_id(&self) -> Option<usize>
fn get_unique_id(&self) -> Option<usize>
source§fn remove_by_id(&mut self, id: usize) -> bool
fn remove_by_id(&mut self, id: usize) -> bool
Id version of
All::remove_by_name.Auto Trait Implementations§
impl RefUnwindSafe for AllGroups
impl Send for AllGroups
impl Sync for AllGroups
impl Unpin for AllGroups
impl UnwindSafe for AllGroups
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