IBM® Carrier Grade Server X3650 T
Revision
3.0
90
17.2.8.1 Synopsis
#include <syscon.h>
int syscon_log_query_create(const char *query_string, int purpose,
syscon_log_query_t *query, char *errbuf, size_t errlen);
int syscon_log_query_get(const syscon_log_query_t *query, int *purpose,
char *qsbuf, size_t qslen, size_t *reqlen);
17.2.8.2 Description
17.2.8.2.1 syscon_log_query_create()
The
syscon_log_query_create
() function shall initialize the query object pointed to by the
query
argument
according to the textual query expression pointed to by the
query_string
argument. If the query object
was previously initialized by
syscon_log_query_create
(), but not subsequently destroyed by
syscon_log_query_destroy
(), the result of re-initializing it shall be undefined.
The arguments
errbuf
and
errlen
specify the location and size (in bytes), respectively, of a buffer. If
syscon_log_query
() rejects the aforementioned query expression because it contains syntactic or
semantic errors, and
errbuf
is not
NULL
and
errlen
is greater than zero, an implementation-defined error
message shall be stored in that buffer. If the error message is too long to fit in the buffer, the first
errlen
-1
bytes of the message, followed by a null character, shall be stored in the buffer. If
syscon_log_query
()
succeeds, the contents of the buffer shall be unchanged.
The query object shall be initialized for the purpose(s) specified by the
purpose
argument, which shall be
the bitwise OR of one or more of the purpose flags defined in the header
<syscon.h>
. Each purpose
flag shall be a constant of type int. The header
<syscon.h>
shall define at least the purpose flags listed
in Table 2.
Table 2. Query Purpose Flags
Name
Description
SYSCONLOG_PRPS_NOTIFY
The query object is to be used for notification purposes -- i.e., passed to
syscon_log_notify_add
().
SYSCONLOG_PRPS_SEEK
The query object is to be used for seek operations -- i.e., passed to
syscon_log_seek
().
SYSCONLOG_PRPS_GENERAL The query object can be used for any purpose that does not require a limited
query.
The value of (SYSCONLOG_PRPS_SEEK & SYSCONLOG_PRPS_GENERAL) shall be non-zero. That
is, the implementation shall not require that only limited queries are used for seek operations.
If the implementation allows general queries (as opposed to just limited queries) to be used for
notification purposes, the value of (SYSCONLOG_PRPS_NOTIFY & SYSCONLOG_PRPS_GENERAL)
shall be non-zero. Otherwise, if the
purpose
argument has the SYSCONLOG_PRPS_NOTIFY flag set,
and the query object specified by
query_string
does not qualify as a limited query,
syscon_log_query_create
() shall fail.
All flags set in the
purpose
argument shall also be set in the query object’s purpose flags. The query
object’s purpose flags may also include implementation-defined flags.
Summary of Contents for Carrier Grade X3650 T
Page 8: ...IBM Carrier Grade Server X3650 T Revision 3 0 viii This page intentionally left blank...
Page 12: ...IBM Carrier Grade Server X3650 T Revision 3 0 4...
Page 15: ...IBM Carrier Grade Server X3650 T Revision 3 0 7...
Page 17: ...IBM Carrier Grade Server X3650 T Revision 3 0 9...
Page 25: ...IBM Carrier Grade Server X3650 T Revision 3 0 17...
Page 43: ...IBM Carrier Grade Server X3650 T Revision 3 0 35...