Manual page for yaz-comp
[yaz-moved-to-github.git] / doc / asn.xml
1 <!-- $Id: asn.xml,v 1.12 2001-10-26 20:13:44 adam Exp $ -->
2  <chapter id="asn"><title>The Z39.50 ASN.1 Module</title>
3   <sect1 id="asn.introduction"><title>Introduction</title>
4    <para>
5     The &asn; module provides you with a set of C struct definitions for the
6     various PDUs of the Z39.50 protocol, as well as for the complex types
7     appearing within the PDUs. For the primitive data types, the C
8     representation often takes the form of an ordinary C language type,
9     such as <literal>int</literal>. For ASN.1 constructs that have no direct
10     representation in C, such as general octet strings and bit strings,
11     the &odr; module (see section <link linkend="odr">The ODR Module</link>)
12     provides auxiliary definitions.
13    </para>
14    <para>
15     The &asn; module is located in sub directory <filename>z39.50</filename>.
16     There you'll find C files that implements encoders and decoders for the
17     Z39.50 types. You'll also find the protocol definitions:
18     <filename>z3950v3.asn</filename>, <filename>esupdate.asn</filename>, 
19     and others.
20    </para>
21   </sect1>
22   <sect1 id="asn.preparing"><title>Preparing PDUs</title>
23    
24    <para>
25     A structure representing a complex ASN.1 type doesn't in itself contain the
26     members of that type. Instead, the structure contains
27     <emphasis>pointers</emphasis> to the members of the type.
28     This is necessary, in part, to allow a mechanism for specifying which
29     of the optional structure (SEQUENCE) members are present, and which
30     are not. It follows that you will need to somehow provide space for
31     the individual members of the structure, and set the pointers to
32     refer to the members.
33    </para>
34    <para>
35     The conversion routines don't care how you allocate and maintain your
36     C structures - they just follow the pointers that you provide.
37     Depending on the complexity of your application, and your personal
38     taste, there are at least three different approaches that you may take
39     when you allocate the structures.
40    </para>
41    
42    <para>
43     You can use static or automatic local variables in the function that
44     prepares the PDU. This is a simple approach, and it provides the most
45     efficient form of memory management. While it works well for flat
46     PDUs like the InitReqest, it will generally not be sufficient for say,
47     the generation of an arbitrarily complex RPN query structure.
48    </para>
49    <para>
50     You can individually create the structure and its members using the
51     <function>malloc(2)</function> function. If you want to ensure that
52     the data is freed when it is no longer needed, you will have to
53     define a function that individually releases each member of a
54     structure before freeing the structure itself.
55    </para>
56    <para>
57     You can use the <function>odr_malloc()</function> function (see section 
58     <link linkend="odr-use">Using ODR</link> for details). When you use
59     <function>odr_malloc()</function>, you can release all of the
60     allocated data in a single operation, independent of any pointers and
61     relations between the data. <function>odr_malloc()</function> is based on a
62     &quot;nibble-memory&quot;
63     scheme, in which large portions of memory are allocated, and then
64     gradually handed out with each call to <function>odr_malloc()</function>.
65     The next time you call <function>odr_reset()</function>, all of the
66     memory allocated since the last call is recycled for future use (actually,
67     it is placed on a free-list).
68    </para>
69    <para>
70     You can combine all of the methods described here. This will often be
71     the most practical approach. For instance, you might use
72     <function>odr_malloc()</function> to allocate an entire structure and
73     some of its elements, while you leave other elements pointing to global
74     or per-session default variables.
75    </para>
76    
77    <para>
78     The &asn; module provides an important aid in creating new PDUs. For
79     each of the PDU types (say, <function>Z_InitRequest</function>), a
80     function is provided that allocates and initializes an instance of
81     that PDU type for you. In the case of the InitRequest, the function is
82     simply named <function>zget_InitRequest()</function>, and it sets up
83     reasonable default value for all of the mandatory members. The optional
84     members are generally initialized to null pointers. This last aspect
85     is very important: it ensures that if the PDU definitions are
86     extended after you finish your implementation (to accommodate
87     new versions of the protocol, say), you won't get into trouble with
88     uninitialized pointers in your structures. The functions use
89     <function>odr_malloc()</function> to
90     allocate the PDUs and its members, so you can free everything again with a
91     single call to <function>odr_reset()</function>. We strongly recommend
92     that you use the <literal>zget_*</literal>
93     functions whenever you are preparing a PDU (in a C++ API, the
94     <literal>zget_</literal>
95     functions would probably be promoted to constructors for the
96     individual types).
97    </para>
98    <para>
99    The prototype for the individual PDU types generally look like this:
100    </para>
101    <synopsis>
102     Z_&lt;type> *zget_&lt;type>(ODR o);
103    </synopsis>
104    
105    <para>
106     eg.:
107    </para>
108    
109    <synopsis>
110     Z_InitRequest *zget_InitRequest(ODR o);
111    </synopsis>
112
113    <para>
114    The &odr; handle should generally be your encoding stream, but it
115     needn't be.
116    </para>
117    <para>
118    As well as the individual PDU functions, a function
119     <function>zget_APDU()</function> is provided, which allocates
120     a top-level Z-APDU of the type requested:
121    </para>
122    
123    <synopsis>
124     Z_APDU *zget_APDU(ODR o, int which);
125    </synopsis>
126    
127    <para>
128     The <varname>which</varname> parameter is (of course) the discriminator
129     belonging to the <varname>Z_APDU</varname> <literal>CHOICE</literal> type.
130     All of the interface described here is provided by the &asn; module, and
131     you access it through the <filename>proto.h</filename> header file.
132     
133    </para>
134   </sect1>
135   <sect1 id="asn.oid"><title id="oid">Object Identifiers</title>
136   <para>
137     When you refer to object identifiers in your application, you need to
138     be aware that SR and Z39.50 use two different set of OIDs to refer to
139     the same objects. To handle this easily, &yaz; provides a utility module
140     to &asn; which provides an internal representation of the OIDs used in
141     both protocols. Each oid is described by a structure:
142    </para>
143    
144    <screen>
145 typedef struct oident
146 {
147     enum oid_proto proto;
148     enum oid_class class;
149     enum oid_value value;
150     int oidsuffix[OID_SIZE];
151     char *desc;
152 } oident;
153    </screen>
154    
155    <para>
156     The <literal>proto</literal> field can be set to either
157     <literal>PROTO_SR</literal> or <literal>PROTO_Z3950</literal>.
158     The <literal>class</literal> might be, say,
159     <literal>CLASS_RECSYN</literal>, and the <literal>value</literal> might be
160     <literal>VAL_USMARC</literal> for the USMARC record format. Functions
161    </para>
162    
163    <screen>
164 int *oid_ent_to_oid(struct oident *ent, int *dst);
165 struct oident *oid_getentbyoid(int *o);
166    </screen>
167    
168    <para>
169     are provided to map between object identifiers and database entries.
170     If you store a member of the <literal>oid_proto</literal> type in
171     your association state information, it's a simple matter, at runtime,
172     to generate the correct OID when you need it. For decoding, you can
173     simply ignore the proto field, or if you're strict, you can verify
174     that your peer is using the OID family from the correct protocol.
175     The <literal>desc</literal> field is a short, human-readable name
176     for the PDU, useful mainly for diagnostic output.
177    </para>
178    
179    <note>
180     <para>
181      The old function <function>oid_getoidbyent</function> still exists but
182      is not thread safe. Use <function>oid_ent_to_oid</function> instead
183      and pass an array of size <literal>OID_SIZE</literal>.
184     </para>
185    </note>
186    
187    <note>
188     <para>
189      Plans are underway to merge the two protocols into a single
190      definition, with one set of object identifiers. When this happens, the
191      oid module will no longer be required to support protocol
192      independence, but it should still be useful as a simple OID database.
193     </para>
194    </note>
195   
196   </sect1>
197   <sect1 id="asn.external"><title>EXTERNAL Data</title>
198    
199    <para>
200     In order to achieve extensibility and adaptability to different
201     application domains, the new version of the protocol defines many
202     structures outside of the main ASN.1 specification, referencing them
203     through ASN.1 EXTERNAL constructs. To simplify the construction and
204     access to the externally referenced data, the &asn; module defines a
205     specialized version of the EXTERNAL construct, called
206     <literal>Z_External</literal>.It is defined thus:
207    </para>
208    
209    <screen>
210 typedef struct Z_External
211 {
212     Odr_oid *direct_reference;
213     int *indirect_reference;
214     char *descriptor;
215     enum
216     {
217         /* Generic types */
218         Z_External_single = 0,
219         Z_External_octet,
220         Z_External_arbitrary,
221
222         /* Specific types */
223         Z_External_SUTRS,
224         Z_External_explainRecord,
225         Z_External_resourceReport1,
226         Z_External_resourceReport2
227
228     ...
229
230     } which;
231     union
232     {
233         /* Generic types */
234         Odr_any *single_ASN1_type;
235         Odr_oct *octet_aligned;
236         Odr_bitmask *arbitrary;
237
238         /* Specific types */
239         Z_SUTRS *sutrs;
240         Z_ExplainRecord *explainRecord;
241         Z_ResourceReport1 *resourceReport1;
242         Z_ResourceReport2 *resourceReport2;
243
244         ...
245
246     } u;
247 } Z_External;
248    </screen>
249    
250    <para>
251     When decoding, the &asn; module will attempt to determine which
252     syntax describes the data by looking at the reference fields
253     (currently only the direct-reference). For ASN.1 structured data, you
254     need only consult the <literal>which</literal> field to determine the
255     type of data. You can the access  the data directly through the union.
256     When constructing data for encoding, you set the union pointer to point
257     to the data, and set the <literal>which</literal> field accordingly.
258     Remember also to set the direct (or indirect) reference to the correct
259     OID for the data type.
260     For non-ASN.1 data such as MARC records, use the
261     <literal>octet_aligned</literal> arm of the union.
262    </para>
263    
264    <para>
265     Some servers return ASN.1 structured data values (eg. database
266     records) as BER-encoded records placed in the
267     <literal>octet-aligned</literal> branch of the EXTERNAL CHOICE.
268     The ASN-module will <emphasis>not</emphasis> automatically decode
269     these records. To help you decode the records in the application, the
270     function
271    </para>
272    
273    <screen>
274    Z_ext_typeent *z_ext_gettypebyref(oid_value ref);
275    </screen>
276
277    <para>
278     Can be used to retrieve information about the known, external data
279     types. The function return a pointer to a static area, or NULL, if no
280     match for the given direct reference is found. The
281     <literal>Z_ext_typeent</literal>
282     is defined as:
283    </para>
284   
285    <screen>
286 typedef struct Z_ext_typeent
287 {
288     oid_value dref;    /* the direct-reference OID value. */
289     int what;          /* discriminator value for the external CHOICE */
290     Odr_fun fun;       /* decoder function */
291 } Z_ext_typeent;
292    </screen>
293    
294    <para>
295     The <literal>what</literal> member contains the
296     <literal>Z_External</literal> union discriminator value for the
297     given type: For the SUTRS record syntax, the value would be
298     <literal>Z_External_sutrs</literal>.
299     The <literal>fun</literal> member contains a pointer to the
300     function which encodes/decodes the given type. Again, for the SUTRS
301     record syntax, the value of <literal>fun</literal> would be
302     <literal>z_SUTRS</literal> (a function pointer).
303    </para>
304    
305    <para>
306     If you receive an EXTERNAL which contains an octet-string value that
307     you suspect of being an ASN.1-structured data value, you can use
308     <literal>z_ext_gettypebyref</literal> to look for the provided
309     direct-reference.
310     If the return value is different from NULL, you can use the provided
311     function to decode the BER string (see section <link linkend="odr-use">
312      Using ODR</link>).
313    </para>
314    
315    <para>
316     If you want to <emphasis>send</emphasis> EXTERNALs containing
317     ASN.1-structured values in the occtet-aligned branch of the CHOICE, this
318     is possible too. However, on the encoding phase, it requires a somewhat
319     involved juggling around of the various buffers involved.
320    </para>
321    <para>
322     If you need to add new, externally defined data types, you must update
323     the struct above, in the source file <filename>prt-ext.h</filename>, as
324     well as the encoder/decoder in the file <filename>prt-ext.c</filename>.
325     When changing the latter, remember to update both the
326     <literal>arm</literal> arrary and the list
327     <literal>type_table</literal>, which drives the CHOICE biasing that
328     is necessary to tell the different, structured types apart
329     on decoding.
330    </para>
331    
332    <note>
333     <para>
334      Eventually, the EXTERNAL processing will most likely
335      automatically insert the correct OIDs or indirect-refs. First,
336      however, we need to determine how application-context management
337      (specifically the presentation-context-list) should fit into the
338      various modules.
339     </para>
340    </note>
341   
342   </sect1>
343   <sect1 id="asn.pdu"><title>PDU Contents Table</title>
344    
345   <para>
346     We include, for reference, a listing of the fields of each top-level
347     PDU, as well as their default settings.
348    </para>
349    
350    <table frame="top"><title>Default settings for PDU Initialize Request</title>
351     <tgroup cols="3">
352      <colspec colwidth="7*" colname="field"></colspec>
353      <colspec colwidth="5*" colname="type"></colspec>
354      <colspec colwidth="7*" colname="value"></colspec>
355     <thead>
356      <row>
357       <entry>Field</entry>
358       <entry>Type</entry>
359       <entry>Default Value</entry>
360      </row>
361     </thead>
362     <tbody>
363      <row><entry>
364        referenceId</entry><entry>Z_ReferenceId</entry><entry>NULL
365       </entry></row>
366      <row><entry>
367        protocolVersion</entry><entry>Odr_bitmask</entry><entry>Empty bitmask
368       </entry></row>
369      <row><entry>
370        options</entry><entry>Odr_bitmask</entry><entry>Empty bitmask
371       </entry></row>
372      <row><entry>
373        preferredMessageSize</entry><entry>int</entry><entry>30*1024
374       </entry></row>
375      <row><entry>
376        maximumRecordSize</entry><entry>int</entry><entry>30*1024
377       </entry></row>
378      <row><entry>
379        idAuthentication</entry><entry>Z_IdAuthentication</entry><entry>NULL
380       </entry></row>
381      <row><entry>
382        implementationId</entry><entry>char*</entry><entry>"81"
383       </entry></row>
384      <row><entry>
385        implementationName</entry><entry>char*</entry><entry>"YAZ"
386       </entry></row>
387      <row><entry>
388        implementationVersion</entry><entry>char*</entry><entry>YAZ_VERSION
389       </entry></row>
390      <row><entry>
391        userInformationField</entry><entry>Z_UserInformation</entry><entry>NULL
392       </entry></row>
393      <row><entry>
394        otherInfo</entry><entry>Z_OtherInformation</entry><entry>NULL
395       </entry></row>
396     </tbody>
397    </tgroup>
398   </table>
399
400   <table frame="top"><title>Default settings for PDU Initialize
401     Response</title>
402    <tgroup cols="3">
403      <colspec colwidth="7*" colname="field"></colspec>
404      <colspec colwidth="5*" colname="type"></colspec>
405      <colspec colwidth="7*" colname="value"></colspec>
406     <thead>
407       <row>
408        <entry>Field</entry>
409        <entry>Type</entry>
410        <entry>Default Value</entry>
411       </row>
412      </thead>
413      <tbody>
414       <row><entry>
415         referenceId</entry><entry>Z_ReferenceId</entry><entry>NULL
416        </entry></row>
417       <row><entry>
418         protocolVersion</entry><entry>Odr_bitmask</entry><entry>Empty bitmask
419        </entry></row>
420       <row><entry>
421         options</entry><entry>Odr_bitmask</entry><entry>Empty bitmask
422        </entry></row>
423       <row><entry>
424         preferredMessageSize</entry><entry>int</entry><entry>30*1024
425        </entry></row>
426       <row><entry>
427         maximumRecordSize</entry><entry>int</entry><entry>30*1024
428        </entry></row>
429       <row><entry>
430         result</entry><entry>bool_t</entry><entry>TRUE
431        </entry></row>
432       <row><entry>
433         implementationId</entry><entry>char*</entry><entry>"id)"
434        </entry></row>
435       <row><entry>
436         implementationName</entry><entry>char*</entry><entry>"YAZ"
437        </entry></row>
438       <row><entry>
439         implementationVersion</entry><entry>char*</entry><entry>YAZ_VERSION
440        </entry></row>
441       <row><entry>
442         userInformationField</entry><entry>Z_UserInformation</entry><entry>NULL
443        </entry></row>
444       <row><entry>
445         otherInfo</entry><entry>Z_OtherInformation</entry><entry>NULL
446        </entry></row>
447      </tbody>
448     </tgroup>
449    </table>
450
451    <table frame="top"><title>Default settings for PDU Search Request</title>
452     <tgroup cols="3">
453      <colspec colwidth="7*" colname="field"></colspec>
454      <colspec colwidth="5*" colname="type"></colspec>
455      <colspec colwidth="7*" colname="value"></colspec>
456      <thead>
457       <row>
458        <entry>Field</entry>
459        <entry>Type</entry>
460        <entry>Default Value</entry>
461       </row>
462      </thead>
463      <tbody>
464       <row><entry>
465         referenceId</entry><entry>Z_ReferenceId</entry><entry>NULL
466        </entry></row>
467       <row><entry>
468         smallSetUpperBound</entry><entry>int</entry><entry>0
469        </entry></row>
470       <row><entry>
471         largeSetLowerBound</entry><entry>int</entry><entry>1
472        </entry></row>
473       <row><entry>
474         mediumSetPresentNumber</entry><entry>int</entry><entry>0
475        </entry></row>
476       <row><entry>
477         replaceIndicator</entry><entry>bool_t</entry><entry>TRUE
478        </entry></row>
479       <row><entry>
480         resultSetName</entry><entry>char *</entry><entry>"default"
481        </entry></row>
482       <row><entry>
483         num_databaseNames</entry><entry>int</entry><entry>0
484        </entry></row>
485       <row><entry>
486         databaseNames</entry><entry>char **</entry><entry>NULL
487        </entry></row>
488       <row><entry>
489         smallSetElementSetNames</entry><entry>Z_ElementSetNames
490        </entry><entry>NULL
491        </entry></row>
492       <row><entry>
493         mediumSetElementSetNames</entry><entry>Z_ElementSetNames
494        </entry><entry>NULL
495        </entry></row>
496       <row><entry>
497         preferredRecordSyntax</entry><entry>Odr_oid</entry><entry>NULL
498        </entry></row>
499       <row><entry>
500         query</entry><entry>Z_Query</entry><entry>NULL
501        </entry></row>
502       <row><entry>
503         additionalSearchInfo</entry><entry>Z_OtherInformation
504        </entry><entry>NULL
505        </entry></row>
506       <row><entry>
507         otherInfo</entry><entry>Z_OtherInformation</entry><entry>NULL
508        </entry></row>
509      </tbody>
510     </tgroup>
511    </table>
512
513    <table frame="top"><title>Default settings for PDU Search Response</title>
514     <tgroup cols="3">
515      <colspec colwidth="7*" colname="field"></colspec>
516      <colspec colwidth="5*" colname="type"></colspec>
517      <colspec colwidth="7*" colname="value"></colspec>
518      <thead>
519       <row>
520        <entry>Field</entry>
521        <entry>Type</entry>
522        <entry>Default Value</entry>
523       </row>
524      </thead>
525      <tbody>
526       
527       <row><entry>
528         referenceId</entry><entry>Z_ReferenceId</entry><entry>NULL
529        </entry></row>
530       <row><entry>
531         resultCount</entry><entry>int</entry><entry>0
532        </entry></row>
533       <row><entry>
534         numberOfRecordsReturned</entry><entry>int</entry><entry>0
535        </entry></row>
536       <row><entry>
537         nextResultSetPosition</entry><entry>int</entry><entry>0
538        </entry></row>
539       <row><entry>
540         searchStatus</entry><entry>bool_t</entry><entry>TRUE
541        </entry></row>
542       <row><entry>
543         resultSetStatus</entry><entry>int</entry><entry>NULL
544        </entry></row>
545       <row><entry>
546         presentStatus</entry><entry>int</entry><entry>NULL
547        </entry></row>
548       <row><entry>
549         records</entry><entry>Z_Records</entry><entry>NULL
550        </entry></row>
551       <row><entry>
552         additionalSearchInfo</entry>
553        <entry>Z_OtherInformation</entry><entry>NULL
554        </entry></row>
555       <row><entry>
556         otherInfo</entry><entry>Z_OtherInformation</entry><entry>NULL
557        </entry></row>
558      </tbody>
559     </tgroup>
560    </table>
561
562    <table frame="top"><title>Default settings for PDU Present Request</title>
563     <tgroup cols="3">
564      <colspec colwidth="7*" colname="field"></colspec>
565      <colspec colwidth="5*" colname="type"></colspec>
566      <colspec colwidth="7*" colname="value"></colspec>
567      <thead>
568       <row>
569        <entry>Field</entry>
570        <entry>Type</entry>
571        <entry>Default Value</entry>
572       </row>
573      </thead>
574      <tbody>
575       <row><entry>
576         referenceId</entry><entry>Z_ReferenceId</entry><entry>NULL
577        </entry></row>
578       <row><entry>
579         resultSetId</entry><entry>char*</entry><entry>"default"
580        </entry></row>
581       <row><entry>
582         resultSetStartPoint</entry><entry>int</entry><entry>1
583        </entry></row>
584       <row><entry>
585         numberOfRecordsRequested</entry><entry>int</entry><entry>10
586        </entry></row>
587       <row><entry>
588         num_ranges</entry><entry>int</entry><entry>0
589        </entry></row>
590       <row><entry>
591         additionalRanges</entry><entry>Z_Range</entry><entry>NULL
592        </entry></row>
593       <row><entry>
594         recordComposition</entry><entry>Z_RecordComposition</entry><entry>NULL
595        </entry></row>
596       <row><entry>
597         preferredRecordSyntax</entry><entry>Odr_oid</entry><entry>NULL
598        </entry></row>
599       <row><entry>
600         maxSegmentCount</entry><entry>int</entry><entry>NULL
601        </entry></row>
602       <row><entry>
603         maxRecordSize</entry><entry>int</entry><entry>NULL
604        </entry></row>
605       <row><entry>
606         maxSegmentSize</entry><entry>int</entry><entry>NULL
607        </entry></row>
608       <row><entry>
609         otherInfo</entry><entry>Z_OtherInformation</entry><entry>NULL
610        </entry></row>
611      </tbody>
612     </tgroup>
613    </table>
614    
615    <table frame="top"><title>Default settings for PDU Present Response</title>
616     <tgroup cols="3">
617      <colspec colwidth="7*" colname="field"></colspec>
618      <colspec colwidth="5*" colname="type"></colspec>
619      <colspec colwidth="7*" colname="value"></colspec>
620      <thead>
621       <row>
622        <entry>Field</entry>
623        <entry>Type</entry>
624        <entry>Default Value</entry>
625       </row>
626      </thead>
627      <tbody>
628       <row><entry>
629         referenceId</entry><entry>Z_ReferenceId</entry><entry>NULL
630        </entry></row>
631       <row><entry>
632         numberOfRecordsReturned</entry><entry>int</entry><entry>0
633        </entry></row>
634       <row><entry>
635         nextResultSetPosition</entry><entry>int</entry><entry>0
636        </entry></row>
637       <row><entry>
638         presentStatus</entry><entry>int</entry><entry>Z_PRES_SUCCESS
639        </entry></row>
640       <row><entry>
641         records</entry><entry>Z_Records</entry><entry>NULL
642        </entry></row>
643       <row><entry>
644         otherInfo</entry><entry>Z_OtherInformation</entry><entry>NULL
645        </entry></row>
646      </tbody>
647     </tgroup>
648    </table>
649    
650    <table frame="top"><title>Default settings for Delete Result Set Request
651     </title>
652     <tgroup cols="3">
653      <colspec colwidth="7*" colname="field"></colspec>
654      <colspec colwidth="5*" colname="type"></colspec>
655      <colspec colwidth="7*" colname="value"></colspec>
656      <thead>
657       <row>
658        <entry>Field</entry>
659        <entry>Type</entry>
660        <entry>Default Value</entry>
661       </row>
662      </thead>
663      <tbody>
664       <row><entry>referenceId
665        </entry><entry>Z_ReferenceId</entry><entry>NULL
666        </entry></row>
667       <row><entry>
668         deleteFunction</entry><entry>int</entry><entry>Z_DeleteRequest_list
669        </entry></row>
670       <row><entry>
671         num_ids</entry><entry>int</entry><entry>0
672        </entry></row>
673       <row><entry>
674         resultSetList</entry><entry>char**</entry><entry>NULL
675        </entry></row>
676       <row><entry>
677         otherInfo</entry><entry>Z_OtherInformation</entry><entry>NULL
678        </entry></row>
679      </tbody>
680     </tgroup>
681    </table>
682
683    <table frame="top"><title>Default settings for Delete Result Set Response
684     </title>
685     <tgroup cols="3">
686      <colspec colwidth="7*" colname="field"></colspec>
687      <colspec colwidth="5*" colname="type"></colspec>
688      <colspec colwidth="7*" colname="value"></colspec>
689      <thead>
690       <row>
691        <entry>Field</entry>
692        <entry>Type</entry>
693        <entry>Default Value</entry>
694       </row>
695      </thead>
696      <tbody>
697       <row><entry>
698         referenceId</entry><entry>Z_ReferenceId</entry><entry>NULL
699        </entry></row>
700       <row><entry>
701         deleteOperationStatus</entry><entry>int</entry>
702        <entry>Z_DeleteStatus_success</entry></row>
703       <row><entry>
704         num_statuses</entry><entry>int</entry><entry>0
705        </entry></row>
706       <row><entry>
707         deleteListStatuses</entry><entry>Z_ListStatus**</entry><entry>NULL
708        </entry></row>
709       <row><entry>
710         numberNotDeleted</entry><entry>int</entry><entry>NULL
711        </entry></row>
712       <row><entry>
713         num_bulkStatuses</entry><entry>int</entry><entry>0
714        </entry></row>
715       <row><entry>
716         bulkStatuses</entry><entry>Z_ListStatus</entry><entry>NUL
717         L</entry></row>
718       <row><entry>
719         deleteMessage</entry><entry>char*</entry><entry>NULL
720        </entry></row>
721       <row><entry>
722         otherInfo</entry><entry>Z_OtherInformation</entry><entry>NULL
723        </entry></row>
724      </tbody>
725     </tgroup>
726    </table>
727
728    <table frame="top"><title>Default settings for Scan Request
729     </title>
730     <tgroup cols="3">
731      <colspec colwidth="7*" colname="field"></colspec>
732      <colspec colwidth="5*" colname="type"></colspec>
733      <colspec colwidth="7*" colname="value"></colspec>
734      <thead>
735       <row>
736        <entry>Field</entry>
737        <entry>Type</entry>
738        <entry>Default Value</entry>
739       </row>
740      </thead>
741      <tbody>
742       <row><entry>
743         referenceId</entry><entry>Z_ReferenceId</entry><entry>NULL
744        </entry></row>
745       <row><entry>
746         num_databaseNames</entry><entry>int</entry><entry>0
747        </entry></row>
748       <row><entry>
749         databaseNames</entry><entry>char**</entry><entry>NULL
750        </entry></row>
751       <row><entry>
752         attributeSet</entry><entry>Odr_oid</entry><entry>NULL
753        </entry></row>
754       <row><entry>
755         termListAndStartPoint</entry><entry>Z_AttributesPlus...
756        </entry><entry>NULL</entry></row>
757       <row><entry>
758         stepSize</entry><entry>int</entry><entry>NULL
759        </entry></row>
760       <row><entry>
761         numberOfTermsRequested</entry><entry>int</entry><entry>20
762        </entry></row>
763       <row><entry>
764         preferredPositionInResponse</entry><entry>int</entry><entry>NULL
765        </entry></row>
766       <row><entry>
767         otherInfo</entry><entry>Z_OtherInformation</entry><entry>NULL
768        </entry></row>
769      </tbody>
770     </tgroup>
771    </table>
772
773    <table frame="top"><title>Default settings for Scan Response
774     </title>
775     <tgroup cols="3">
776      <colspec colwidth="7*" colname="field"></colspec>
777      <colspec colwidth="5*" colname="type"></colspec>
778      <colspec colwidth="7*" colname="value"></colspec>
779      <thead>
780       <row>
781        <entry>Field</entry>
782        <entry>Type</entry>
783        <entry>Default Value</entry>
784       </row>
785      </thead>
786      <tbody>
787       
788       <row><entry>
789         referenceId</entry><entry>Z_ReferenceId</entry><entry>NULL
790        </entry></row>
791       <row><entry>
792         stepSize</entry><entry>int</entry><entry>NULL
793        </entry></row>
794       <row><entry>
795         scanStatus</entry><entry>int</entry><entry>Z_Scan_success
796        </entry></row>
797       <row><entry>
798         numberOfEntriesReturned</entry><entry>int</entry><entry>0
799        </entry></row>
800       <row><entry>
801         positionOfTerm</entry><entry>int</entry><entry>NULL
802        </entry></row>
803       <row><entry>
804         entries</entry><entry>Z_ListEntris</entry><entry>NULL
805        </entry></row>
806       <row><entry>
807         attributeSet</entry><entry>Odr_oid</entry><entry>NULL
808        </entry></row>
809       <row><entry>
810         otherInfo</entry><entry>Z_OtherInformation</entry><entry>NULL
811        </entry></row>
812      </tbody>
813     </tgroup>
814    </table>
815
816    <table frame="top"><title>Default settings for Trigger Resource
817      Control Request </title>
818     <tgroup cols="3">
819      <colspec colwidth="7*" colname="field"></colspec>
820      <colspec colwidth="5*" colname="type"></colspec>
821      <colspec colwidth="7*" colname="value"></colspec>
822      <thead>
823       <row>
824        <entry>Field</entry>
825        <entry>Type</entry>
826        <entry>Default Value</entry>
827       </row>
828      </thead>
829      <tbody>
830       
831       <row><entry>
832         referenceId</entry><entry>Z_ReferenceId</entry><entry>NULL
833        </entry></row>
834       <row><entry>
835         requestedAction</entry><entry>int</entry><entry>
836         Z_TriggerResourceCtrl_resou..
837        </entry></row>
838       <row><entry>
839         prefResourceReportFormat</entry><entry>Odr_oid</entry><entry>NULL
840        </entry></row>
841       <row><entry>
842         resultSetWanted</entry><entry>bool_t</entry><entry>NULL
843        </entry></row>
844       <row><entry>
845         otherInfo</entry><entry>Z_OtherInformation</entry><entry>NULL
846        </entry></row>
847       
848      </tbody>
849     </tgroup>
850    </table>
851
852    <table frame="top"><title>Default settings for Resource
853      Control Request</title>
854     <tgroup cols="3">
855      <colspec colwidth="7*" colname="field"></colspec>
856      <colspec colwidth="5*" colname="type"></colspec>
857      <colspec colwidth="7*" colname="value"></colspec>
858      <thead>
859       <row>
860        <entry>Field</entry>
861        <entry>Type</entry>
862        <entry>Default Value</entry>
863       </row>
864      </thead>
865      <tbody>
866       
867       <row><entry>
868         referenceId</entry><entry>Z_ReferenceId</entry><entry>NULL
869        </entry></row>
870       <row><entry>
871         suspendedFlag</entry><entry>bool_t</entry><entry>NULL
872        </entry></row>
873       <row><entry>
874         resourceReport</entry><entry>Z_External</entry><entry>NULL
875        </entry></row>
876       <row><entry>
877         partialResultsAvailable</entry><entry>int</entry><entry>NULL
878        </entry></row>
879       <row><entry>
880         responseRequired</entry><entry>bool_t</entry><entry>FALSE
881        </entry></row>
882       <row><entry>
883         triggeredRequestFlag</entry><entry>bool_t</entry><entry>NULL
884        </entry></row>
885       <row><entry>
886         otherInfo</entry><entry>Z_OtherInformation</entry><entry>NULL
887        </entry></row>
888      </tbody>
889     </tgroup>
890    </table>
891
892    <table frame="top"><title>Default settings for Resource
893      Control Response</title>
894     <tgroup cols="3">
895      <colspec colwidth="7*" colname="field"></colspec>
896      <colspec colwidth="5*" colname="type"></colspec>
897      <colspec colwidth="7*" colname="value"></colspec>
898      <thead>
899       <row>
900        <entry>Field</entry>
901        <entry>Type</entry>
902        <entry>Default Value</entry>
903       </row>
904      </thead>
905      <tbody>
906       
907       <row><entry>
908         referenceId</entry><entry>Z_ReferenceId</entry><entry>NULL
909        </entry></row>
910       <row><entry>
911         continueFlag</entry><entry>bool_t</entry><entry>TRUE
912        </entry></row>
913       <row><entry>
914         resultSetWanted</entry><entry>bool_t</entry><entry>NULL
915        </entry></row>
916       <row><entry>
917         otherInfo</entry><entry>Z_OtherInformation</entry><entry>NULL
918        </entry></row>
919      </tbody>
920     </tgroup>
921    </table>
922    
923    <table frame="top"><title>Default settings for Access
924      Control Request</title>
925     <tgroup cols="3">
926      <colspec colwidth="7*" colname="field"></colspec>
927      <colspec colwidth="5*" colname="type"></colspec>
928      <colspec colwidth="7*" colname="value"></colspec>
929      <thead>
930       <row>
931        <entry>Field</entry>
932        <entry>Type</entry>
933        <entry>Default Value</entry>
934       </row>
935      </thead>
936      <tbody>
937       
938       <row><entry>
939         referenceId</entry><entry>Z_ReferenceId</entry><entry>NULL
940        </entry></row>
941       <row><entry>
942         which</entry><entry>enum</entry><entry>Z_AccessRequest_simpleForm;
943        </entry></row>
944       <row><entry>
945         u</entry><entry>union</entry><entry>NULL
946        </entry></row>
947       <row><entry>
948         otherInfo</entry><entry>Z_OtherInformation</entry><entry>NULL
949        </entry></row>
950      </tbody>
951     </tgroup>
952    </table>
953
954    <table frame="top"><title>Default settings for Access
955      Control Response</title>
956     <tgroup cols="3">
957      <colspec colwidth="7*" colname="field"></colspec>
958      <colspec colwidth="5*" colname="type"></colspec>
959      <colspec colwidth="7*" colname="value"></colspec>
960      <thead>
961       <row>
962        <entry>Field</entry>
963        <entry>Type</entry>
964        <entry>Default Value</entry>
965       </row>
966      </thead>
967      <tbody>
968       
969       <row><entry>
970         referenceId</entry><entry>Z_ReferenceId</entry><entry>NULL
971        </entry></row>
972       <row><entry>
973         which</entry><entry>enum</entry><entry>Z_AccessResponse_simpleForm
974        </entry></row>
975       <row><entry>
976         u</entry><entry>union</entry><entry>NULL
977        </entry></row>
978       <row><entry>
979         diagnostic</entry><entry>Z_DiagRec</entry><entry>NULL
980        </entry></row>
981       <row><entry>
982         otherInfo</entry><entry>Z_OtherInformation</entry><entry>NULL
983        </entry></row>
984      </tbody>
985     </tgroup>
986    </table>
987
988    <table frame="top"><title>Default settings for Segment</title>
989     <tgroup cols="3">
990      <colspec colwidth="7*" colname="field"></colspec>
991      <colspec colwidth="5*" colname="type"></colspec>
992      <colspec colwidth="7*" colname="value"></colspec>
993      <thead>
994       <row>
995        <entry>Field</entry>
996        <entry>Type</entry>
997        <entry>Default Value</entry>
998       </row>
999      </thead>
1000      <tbody>
1001       
1002       <row><entry>
1003         referenceId</entry><entry>Z_ReferenceId</entry><entry>NULL
1004        </entry></row>
1005       <row><entry>
1006         numberOfRecordsReturned</entry><entry>int</entry><entry>value=0
1007        </entry></row>
1008       <row><entry>
1009         num_segmentRecords</entry><entry>int</entry><entry>0
1010        </entry></row>
1011       <row><entry>
1012         segmentRecords</entry><entry>Z_NamePlusRecord</entry><entry>NULL
1013        </entry></row>
1014       <row><entry>otherInfo</entry><entry>Z_OtherInformation</entry><entry>NULL
1015        </entry></row>
1016      </tbody>
1017     </tgroup>
1018    </table>
1019
1020    <table frame="top"><title>Default settings for Close</title>
1021     <tgroup cols="3">
1022      <colspec colwidth="7*" colname="field"></colspec>
1023      <colspec colwidth="5*" colname="type"></colspec>
1024      <colspec colwidth="7*" colname="value"></colspec>
1025      <thead>
1026       <row>
1027        <entry>Field</entry>
1028        <entry>Type</entry>
1029        <entry>Default Value</entry>
1030       </row>
1031      </thead>
1032      <tbody>
1033
1034       <row><entry>
1035         referenceId</entry><entry>Z_ReferenceId</entry><entry>NULL
1036        </entry></row>
1037       <row><entry>
1038         closeReason</entry><entry>int</entry><entry>Z_Close_finished
1039        </entry></row>
1040       <row><entry>
1041         diagnosticInformation</entry><entry>char*</entry><entry>NULL
1042        </entry></row>
1043       <row><entry>
1044         resourceReportFormat</entry><entry>Odr_oid</entry><entry>NULL
1045        </entry></row>
1046       <row><entry>
1047         resourceFormat</entry><entry>Z_External</entry><entry>NULL
1048        </entry></row>
1049       <row><entry>
1050         otherInfo</entry><entry>Z_OtherInformation</entry><entry>NULL
1051        </entry></row>
1052       
1053      </tbody>
1054     </tgroup>
1055    </table>
1056
1057   </sect1>
1058  </chapter>
1059
1060  <!-- Keep this comment at the end of the file
1061  Local variables:
1062  mode: sgml
1063  sgml-omittag:t
1064  sgml-shorttag:t
1065  sgml-minimize-attributes:nil
1066  sgml-always-quote-attributes:t
1067  sgml-indent-step:1
1068  sgml-indent-data:t
1069  sgml-parent-document: "yaz.xml"
1070  sgml-local-catalogs: nil
1071  sgml-namecase-general:t
1072  End:
1073  -->