wlm_read_classes Subroutine

Purpose

Reads the characteristics of superclasses or subclasses.

Library

Workload Manager Library (libwlm.a)

Syntax

#include <sys/wlm.h>

int wlm_read_classes (wlmargs,  class_tbl,  nclass)
struct wlm_args *wlmargs;
struct class_definition *class_tbl;
int *nclass
;

Description

The wlm_read_classes subroutine is used to get the characteristics of the superclasses or the subclasses of a given subclass of a Workload Manager (WLM) configuration.

This operation does not require any special privileges and is accessible to all users.

Parameter

Item Description
wlmargs Specifies the address of a struct wlm_args data structure.

The following fields of the wlm_args structure and the embedded substructures need to be provided:

versflags
Needs to be initialized with WLM_VERSION.
confdir
Specifies the name of a WLM configuration. It must be either the name of a valid subdirectory of /etc/wlm or a null string (starting with '\0').
name
Specifies the name of a superclass existing in the specified configuration or a null string.

All the other fields can be left uninitialized.

Item Description
class_tbl Specifies the address of an array of structures of type struct class_definition. Upon successful return from wlm_read_classes, this array contains the characteristics of the classes read.
nclass Specifies the address of an integer containing the maximum number of element (class definitions) for wlm_read_classes to copy into the array above. If the call to wlm_read_classes is successful, this integer contains the number of elements actually copied.

Return Values

Upon successful completion, the wlm_read_classes subroutine returns a value of 0. If the wlm_read_classes subroutine is unsuccessful, a nonzero value is returned.

Error Codes

For a list of the possible error codes returned by the WLM API functions, see the description of the wlm.h header file.