GNU Octave  6.2.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
octave::sys::group Class Reference

#include "oct-group.h"

Collaboration diagram for octave::sys::group:

Public Member Functions

 group (const group &gr)
 
 group (void)
 
gid_t gid (void) const
 
string_vector mem (void) const
 
std::string name (void) const
 
bool ok (void) const
 
 operator bool () const
 
groupoperator= (const group &gr)
 
std::string passwd (void) const
 

Static Public Member Functions

static int endgrent (std::string &msg)
 
static int endgrent (void)
 
static group getgrent (std::string &msg)
 
static group getgrent (void)
 
static group getgrgid (gid_t gid)
 
static group getgrgid (gid_t gid, std::string &msg)
 
static group getgrnam (const std::string &nm)
 
static group getgrnam (const std::string &nm, std::string &msg)
 
static int setgrent (std::string &msg)
 
static int setgrent (void)
 

Private Member Functions

 group (void *p, std::string &msg)
 

Private Attributes

gid_t m_gid
 
string_vector m_mem
 
std::string m_name
 
std::string m_passwd
 
bool valid
 

Detailed Description

Definition at line 41 of file oct-group.h.

Constructor & Destructor Documentation

◆ group() [1/3]

octave::sys::group::group ( void  )
inline

Definition at line 47 of file oct-group.h.

Referenced by getgrent(), getgrgid(), and getgrnam().

◆ group() [2/3]

octave::sys::group::group ( const group gr)
inline

Definition at line 51 of file oct-group.h.

◆ group() [3/3]

octave::sys::group::group ( void *  p,
std::string &  msg 
)
private

Definition at line 191 of file oct-group.cc.

References m_gid, m_mem, m_name, m_passwd, NOT_SUPPORTED, string_vector::resize(), and valid.

Member Function Documentation

◆ endgrent() [1/2]

int octave::sys::group::endgrent ( std::string &  msg)
static

Definition at line 179 of file oct-group.cc.

References endgrent(), and NOT_SUPPORTED.

◆ endgrent() [2/2]

int octave::sys::group::endgrent ( void  )
static

Definition at line 172 of file oct-group.cc.

Referenced by endgrent(), and Fendgrent().

◆ getgrent() [1/2]

group octave::sys::group::getgrent ( std::string &  msg)
static

Definition at line 98 of file oct-group.cc.

References group(), getgrent(), and NOT_SUPPORTED.

◆ getgrent() [2/2]

group octave::sys::group::getgrent ( void  )
static

Definition at line 91 of file oct-group.cc.

Referenced by Fgetgrent(), and getgrent().

◆ getgrgid() [1/2]

group octave::sys::group::getgrgid ( gid_t  gid)
static

Definition at line 110 of file oct-group.cc.

References gid().

Referenced by Fgetgrgid(), and getgrgid().

◆ getgrgid() [2/2]

group octave::sys::group::getgrgid ( gid_t  gid,
std::string &  msg 
)
static

Definition at line 117 of file oct-group.cc.

References group(), getgrgid(), gid(), and NOT_SUPPORTED.

◆ getgrnam() [1/2]

group octave::sys::group::getgrnam ( const std::string &  nm)
static

Definition at line 131 of file oct-group.cc.

Referenced by Fgetgrnam(), and getgrnam().

◆ getgrnam() [2/2]

group octave::sys::group::getgrnam ( const std::string &  nm,
std::string &  msg 
)
static

Definition at line 138 of file oct-group.cc.

References group(), getgrnam(), and NOT_SUPPORTED.

◆ gid()

gid_t octave::sys::group::gid ( void  ) const

Definition at line 73 of file oct-group.cc.

References err_invalid(), m_gid, and ok().

Referenced by getgrgid(), and mk_gr_map().

◆ mem()

string_vector octave::sys::group::mem ( void  ) const

Definition at line 82 of file oct-group.cc.

References err_invalid(), m_mem, and ok().

Referenced by mk_gr_map().

◆ name()

std::string octave::sys::group::name ( void  ) const

Definition at line 55 of file oct-group.cc.

References err_invalid(), m_name, and ok().

Referenced by mk_gr_map().

◆ ok()

bool octave::sys::group::ok ( void  ) const
inline

Definition at line 78 of file oct-group.h.

Referenced by gid(), mem(), name(), and passwd().

◆ operator bool()

octave::sys::group::operator bool ( ) const
inline

Definition at line 80 of file oct-group.h.

◆ operator=()

group& octave::sys::group::operator= ( const group gr)
inline

Definition at line 56 of file oct-group.h.

References m_gid, m_mem, m_name, m_passwd, and valid.

◆ passwd()

std::string octave::sys::group::passwd ( void  ) const

Definition at line 64 of file oct-group.cc.

References err_invalid(), m_passwd, and ok().

Referenced by mk_gr_map().

◆ setgrent() [1/2]

int octave::sys::group::setgrent ( std::string &  msg)
static

Definition at line 159 of file oct-group.cc.

References NOT_SUPPORTED, and setgrent().

◆ setgrent() [2/2]

int octave::sys::group::setgrent ( void  )
static

Definition at line 152 of file oct-group.cc.

Referenced by Fsetgrent(), and setgrent().

Member Data Documentation

◆ m_gid

gid_t octave::sys::group::m_gid
private

Definition at line 106 of file oct-group.h.

Referenced by group(), gid(), and operator=().

◆ m_mem

string_vector octave::sys::group::m_mem
private

Definition at line 109 of file oct-group.h.

Referenced by group(), mem(), and operator=().

◆ m_name

std::string octave::sys::group::m_name
private

Definition at line 100 of file oct-group.h.

Referenced by group(), name(), and operator=().

◆ m_passwd

std::string octave::sys::group::m_passwd
private

Definition at line 103 of file oct-group.h.

Referenced by group(), operator=(), and passwd().

◆ valid

bool octave::sys::group::valid
private

Definition at line 112 of file oct-group.h.

Referenced by group(), and operator=().


The documentation for this class was generated from the following files: