Next: , Previous: , Up: system group   [Contents][Index]


19.2.3 Searching entries from /etc/group

We are meant to call these function after a call to mbfl_system_group_read(). The following functions inspect entries from /etc/group and locate them using numeric indexes; such indexes are valid only until the next call to mbfl_system_group_reset().

Function: mbfl_system_group_find_entry_by_name name
Function: mbfl_system_group_find_entry_by_name_var _RV name

Search the entries of /etc/group for one whose group name is name. When successful: print to stdout the index of the entry and return true; otherwise return false. We can use the index with the functions described in Inspecting entries from /etc/group.

The function variant _var stores the result in the variable _RV, rather than print it; Result variables.

Function: mbfl_system_group_find_entry_by_gid gid
Function: mbfl_system_group_find_entry_by_gid_var _RV gid

Search the entries of /etc/group for one whose group id is gid. When successful: print to stdout the index of the entry and return true; otherwise return false. We can use the index with the functions described in Inspecting entries from /etc/group.

The function variant _var stores the result in the variable _RV, rather than print it; Result variables.


Next: , Previous: , Up: system group   [Contents][Index]

This document describes version 3.0.0-devel.0 of Marcos Bash Functions Library.