OSF DCE Application Development Guide--Core Components

The Extended Attribute API
released.
The following calls allocate, initialize, and release a sec_attr_cursor_t for use with the
sec_rgy_attr_sch_scan( ) call:
sec_rgy_attr_sch_cursor_init()
The sec_rgy_attr_sch_cursor_init( ) call allocates resources to the cursor and
initializes the cursor to the first attribute type entry in the attribute schema. This call
also supplies the total number of entries in the attribute schema as part of its output.
The cursor allocation is a local operation. The cursor initialization is a remote
operation and makes a remote call to the registry.
sec_rgy_attr_sch_cursor_alloc( )
The sec_rgy_attr_sch_cursor_alloc( ) call allocates resources to the cursor but does
not initialize the cursor. However, since the sec_rgy_attr_sch_scan( ) call will
initialize the cursor if it is passed in uninitialized, you may prefer this call to limit
the number of remote calls performed by an application. Be aware that the sec_rgy_-
attr_sch_cursor_init( ) call provides the total number of entries in the named
schema, a piece of information not provided by the sec_rgy_attr_sch_cursor_-
alloc( ) call.
sec_rgy_attr_sch_cursor_release( )
The sec_rgy_attr_sch_cursor_release( ) call releases all resources allocated to a
sec_attr_cursor_t cursor used with the sec_rgy_attr_sch_scan( ) call.
sec_rgy_attr_sch_cursor_reset( )
The sec_rgy_attr_sch_cursor_reset( ) call initializes a sec_attr_cursor_t cursor
used with the sec_rgy_attr_sch_scan( ) call. The reset cursor can then be used
without releasing and reallocating.
28.2.3.2 The sec_rgy_attr_sch_scan( ) Call
The sec_rgy_attr_sch_scan( ) call reads a specified number of schema entries from the
attribute schema.
The number of entries to read is specified as an unsigned 32-bit integer. The read begins
at the entry at which the sec_attr_cursor_t cursor is positioned and continues through
the number of entries specified. The cursor must be allocated but can be initialized or
uninitialized since sec_rgy_attr_sch_scan( ) initializes any uninitialized cursor it
receives as input.
The call output includes an array of sec_attr_schema_entry_t values and a 32-bit
integer that specifies the number of schema entries returned.
To read through all entries in a schema, continue making sec_rgy_attr_sch_scan()
calls, until the no_more_entries message is received. When all calls are complete,
release the resources allocated to the sec_attr_cursor_t cursor by using the sec_rgy_-
attr_sch_cursor_release( ) call.
124245 Tandem Computers Incorporated 28 13