2 * Copyright (c) 1995, Index Data.
4 * Permission to use, copy, modify, distribute, and sell this software and
5 * its documentation, in whole or in part, for any purpose, is hereby granted,
8 * 1. This copyright and permission notice appear in all copies of the
9 * software and its documentation. Notices of copyright or attribution
10 * which appear at the beginning of any file must remain unchanged.
12 * 2. The name of Index Data or the individual authors may not be used to
13 * endorse or promote products derived from this software without specific
14 * prior written permission.
16 * THIS SOFTWARE IS PROVIDED "AS IS" AND WITHOUT WARRANTY OF ANY KIND,
17 * EXPRESS, IMPLIED, OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY
18 * WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.
19 * IN NO EVENT SHALL INDEX DATA BE LIABLE FOR ANY SPECIAL, INCIDENTAL,
20 * INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND, OR ANY DAMAGES
21 * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER OR
22 * NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF
23 * LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE
27 * Revision 1.21 1995-08-15 12:00:11 quinn
30 * Revision 1.20 1995/08/10 08:54:35 quinn
33 * Revision 1.19 1995/06/19 12:38:28 quinn
34 * Reorganized include-files. Added small features.
36 * Revision 1.18 1995/06/16 13:16:05 quinn
37 * Fixed Defaultdiagformat.
39 * Revision 1.17 1995/06/15 15:42:05 quinn
42 * Revision 1.16 1995/06/15 07:45:06 quinn
45 * Revision 1.15 1995/06/14 15:26:43 quinn
46 * *** empty log message ***
48 * Revision 1.14 1995/06/07 14:42:34 quinn
51 * Revision 1.13 1995/06/07 14:36:47 quinn
54 * Revision 1.12 1995/06/05 10:53:13 quinn
57 * Revision 1.11 1995/06/02 09:49:47 quinn
60 * Revision 1.10 1995/05/29 08:11:34 quinn
61 * Moved oid from odr/asn to util.
63 * Revision 1.9 1995/05/22 11:31:25 quinn
66 * Revision 1.8 1995/05/17 08:41:35 quinn
67 * Added delete to proto & other little things.
68 * Relaying auth info to backend.
70 * Revision 1.7 1995/05/16 08:50:37 quinn
71 * License, documentation, and memory fixes
73 * Revision 1.6 1995/05/15 11:55:55 quinn
74 * Work on asynchronous activity.
76 * Revision 1.5 1995/04/17 11:28:18 quinn
79 * Revision 1.4 1995/04/10 10:22:47 quinn
82 * Revision 1.3 1995/03/30 12:18:09 quinn
85 * Revision 1.2 1995/03/30 10:26:48 quinn
86 * Added Term structure
88 * Revision 1.1 1995/03/30 09:39:42 quinn
89 * Moved .h files to include directory
91 * Revision 1.11 1995/03/30 09:08:44 quinn
92 * Added Resource control protocol
94 * Revision 1.10 1995/03/29 15:39:39 quinn
95 * Adding some resource control elements, and a null-check to getentbyoid
97 * Revision 1.9 1995/03/29 08:06:18 quinn
98 * Added a few v3 elements
100 * Revision 1.8 1995/03/22 10:12:49 quinn
101 * Added Z_PRES constants.
103 * Revision 1.7 1995/03/20 09:45:12 quinn
106 * Revision 1.5 1995/03/07 16:29:34 quinn
107 * Added authentication stuff.
109 * Revision 1.4 1995/03/07 10:13:00 quinn
110 * Added prototype for z_APDU()
112 * Revision 1.3 1995/02/14 11:54:23 quinn
115 * Revision 1.2 1995/02/09 15:51:40 quinn
118 * Revision 1.1 1995/02/06 16:44:48 quinn
119 * First hack at Z/SR protocol
129 #include <yaz-version.h>
132 * Because we didn't have time to put all of the extra v3 elements in here
133 * before the first applications were written, we have to place them
134 * in #ifdefs in places where they would break existing code. If you are
135 * developing new stuff, we urge you to leave them in, even if you don't
136 * intend to use any v3 features. When we are comfortable that the old
137 * apps have been updated, we'll remove the #ifdefs.
142 /* ----------------- GLOBAL AUXILIARY DEFS ----------------*/
145 typedef struct Z_External Z_External;
147 typedef Odr_oct Z_ReferenceId;
148 typedef char Z_DatabaseName;
149 typedef char Z_ResultSetId;
150 typedef Odr_oct Z_ResultsetId;
152 typedef struct Z_InfoCategory
154 Odr_oid *categoryTypeId; /* OPTIONAL */
158 typedef struct Z_OtherInformationUnit
160 Z_InfoCategory *category; /* OPTIONAL */
163 Z_OtherInfo_characterInfo,
164 Z_OtherInfo_binaryInfo,
165 Z_OtherInfo_externallyDefinedInfo,
172 Z_External *externallyDefinedInfo;
175 } Z_OtherInformationUnit;
177 typedef struct Z_OtherInformation
180 Z_OtherInformationUnit **list;
181 } Z_OtherInformation;
183 typedef struct Z_StringOrNumeric
187 Z_StringOrNumeric_string,
188 Z_StringOrNumeric_numeric
197 typedef struct Z_Unit
199 char *unitSystem; /* OPTIONAL */
200 Z_StringOrNumeric *unitType; /* OPTIONAL */
201 Z_StringOrNumeric *unit; /* OPTIONAL */
202 int *scaleFactor; /* OPTIONAL */
205 typedef struct Z_IntUnit
211 typedef Odr_oct Z_SUTRS;
213 /* ----------------- INIT SERVICE ----------------*/
217 char *groupId; /* OPTIONAL */
218 char *userId; /* OPTIONAL */
219 char *password; /* OPTIONAL */
222 typedef struct Z_IdAuthentication
226 Z_IdAuthentication_open,
227 Z_IdAuthentication_idPass,
228 Z_IdAuthentication_anonymous,
229 Z_IdAuthentication_other
238 } Z_IdAuthentication;
240 #define Z_ProtocolVersion_1 0
241 #define Z_ProtocolVersion_2 1
242 #define Z_ProtocolVersion_3 2
244 #define Z_Options_search 0
245 #define Z_Options_present 1
246 #define Z_Options_delSet 2
247 #define Z_Options_resourceReport 3
248 #define Z_Options_triggerResourceCtrl 4
249 #define Z_Options_resourceCtrl 5
250 #define Z_Options_accessCtrl 6
251 #define Z_Options_scan 7
252 #define Z_Options_sort 8
253 #define Z_Options_reserved 9
254 #define Z_Options_extendedServices 10
255 #define Z_Options_level_1Segmentation 11
256 #define Z_Options_level_2Segmentation 12
257 #define Z_Options_concurrentOperations 13
258 #define Z_Options_namedResultSets 14
260 typedef struct Z_InitRequest
262 Z_ReferenceId *referenceId; /* OPTIONAL */
263 Odr_bitmask *protocolVersion;
264 Odr_bitmask *options;
265 int *preferredMessageSize;
266 int *maximumRecordSize;
267 Z_IdAuthentication* idAuthentication; /* OPTIONAL */
268 char *implementationId; /* OPTIONAL */
269 char *implementationName; /* OPTIONAL */
270 char *implementationVersion; /* OPTIONAL */
271 Z_External *userInformationField; /* OPTIONAL */
273 Z_OtherInformation *otherInfo; /* OPTIONAL */
277 typedef struct Z_InitResponse
279 Z_ReferenceId *referenceId; /* OPTIONAL */
280 Odr_bitmask *protocolVersion;
281 Odr_bitmask *options;
282 int *preferredMessageSize;
283 int *maximumRecordSize;
285 char *implementationId; /* OPTIONAL */
286 char *implementationName; /* OPTIONAL */
287 char *implementationVersion; /* OPTIONAL */
288 Z_External *userInformationField; /* OPTIONAL */
290 Z_OtherInformation *otherInfo; /* OPTIONAL */
294 typedef struct Z_NSRAuthentication
299 } Z_NSRAuthentication;
301 int z_NSRAuthentication(ODR o, Z_NSRAuthentication **p, int opt);
303 int z_StrAuthentication(ODR o, char **p, int opt);
305 /* ------------------ SEARCH SERVICE ----------------*/
307 typedef struct Z_DatabaseSpecificUnit
310 char *elementSetName;
311 } Z_DatabaseSpecificUnit;
313 typedef struct Z_DatabaseSpecific
316 Z_DatabaseSpecificUnit **elements;
317 } Z_DatabaseSpecific;
319 typedef struct Z_ElementSetNames
322 #define Z_ElementSetNames_generic 0
323 #define Z_ElementSetNames_databaseSpecific 1
327 Z_DatabaseSpecific *databaseSpecific;
331 /* ---------------------- RPN QUERY --------------------------- */
333 typedef struct Z_ComplexAttribute
336 Z_StringOrNumeric **list;
337 int num_semanticAction;
338 int **semanticAction; /* OPTIONAL */
339 } Z_ComplexAttribute;
341 typedef struct Z_AttributeElement
344 Odr_oid *attributeSet; /* OPTIONAL - v3 only */
350 Z_AttributeValue_numeric,
351 Z_AttributeValue_complex
356 Z_ComplexAttribute *complex;
361 } Z_AttributeElement;
363 typedef struct Z_Term
369 Z_Term_characterString,
373 Z_Term_integerAndUnit,
378 Odr_oct *general; /* this is required for v2 */
380 char *characterString;
383 Z_External *external;
384 /* Z_IntUnit *integerAndUnit; */
389 typedef struct Z_AttributesPlusTerm
392 Z_AttributeElement **attributeList;
394 } Z_AttributesPlusTerm;
396 typedef struct Z_ResultSetPlusAttributes
400 Z_AttributeElement **attributeList;
401 } Z_ResultSetPlusAttributes;
403 typedef struct Z_ProximityOperator
405 bool_t *exclusion; /* OPTIONAL */
409 #define Z_Prox_lessThan 1
410 #define Z_Prox_lessThanOrEqual 2
411 #define Z_Prox_equal 3
412 #define Z_Prox_greaterThanOrEqual 4
413 #define Z_Prox_greaterThan 5
414 #define Z_Prox_notEqual 6
420 int *proximityUnitCode;
421 #define Z_ProxUnit_character 1
422 #define Z_ProxUnit_word 2
423 #define Z_ProxUnit_sentence 3
424 #define Z_ProxUnit_paragraph 4
425 #define Z_ProxUnit_section 5
426 #define Z_ProxUnit_chapter 6
427 #define Z_ProxUnit_document 7
428 #define Z_ProxUnit_element 8
429 #define Z_ProxUnit_subelement 9
430 #define Z_ProxUnit_elementType 10
431 #define Z_ProxUnit_byte 11 /* v3 only */
432 } Z_ProximityOperator;
434 typedef struct Z_Operator
445 Odr_null *and; /* these guys are nulls. */
448 Z_ProximityOperator *prox;
452 typedef struct Z_Operand
457 Z_Operand_resultSetId,
458 Z_Operand_resultAttr /* v3 only */
462 Z_AttributesPlusTerm *attributesPlusTerm;
463 Z_ResultSetId *resultSetId;
464 Z_ResultSetPlusAttributes *resultAttr;
468 typedef struct Z_Complex
470 struct Z_RPNStructure *s1;
471 struct Z_RPNStructure *s2;
472 Z_Operator *operator;
475 typedef struct Z_RPNStructure
479 Z_RPNStructure_simple,
480 Z_RPNStructure_complex
489 typedef struct Z_RPNQuery
491 Odr_oid *attributeSetId;
492 Z_RPNStructure *RPNStructure;
495 /* -------------------------- SEARCHREQUEST -------------------------- */
497 typedef struct Z_Query
510 Z_RPNQuery *type_101;
514 typedef struct Z_SearchRequest
516 Z_ReferenceId *referenceId; /* OPTIONAL */
517 int *smallSetUpperBound;
518 int *largeSetLowerBound;
519 int *mediumSetPresentNumber;
520 bool_t *replaceIndicator;
522 int num_databaseNames;
523 char **databaseNames;
524 Z_ElementSetNames *smallSetElementSetNames; /* OPTIONAL */
525 Z_ElementSetNames *mediumSetElementSetNames; /* OPTIONAL */
526 Odr_oid *preferredRecordSyntax; /* OPTIONAL */
529 Z_OtherInformation *additionalSearchInfo; /* OPTIONAL */
530 Z_OtherInformation *otherInfo; /* OPTIONAL */
534 /* ------------------------ RECORD -------------------------- */
536 typedef Z_External Z_DatabaseRecord;
540 typedef struct Z_DefaultDiagFormat
542 Odr_oid *diagnosticSetId; /* This is opt'l to interwork with bad targets */
544 /* until the whole character set issue becomes more definite,
545 * you can probably ignore this on input. */
548 Z_DiagForm_v2AddInfo,
552 } Z_DefaultDiagFormat;
554 typedef struct Z_DiagRec
558 Z_DiagRec_defaultFormat,
559 Z_DiagRec_externallyDefined
563 Z_DefaultDiagFormat *defaultFormat;
564 Z_External *externallyDefined;
570 typedef struct Z_DiagRec
572 Odr_oid *diagnosticSetId; /* This is opt'l to interwork with bad targets */
579 typedef struct Z_DiagRecs
582 Z_DiagRec **diagRecs;
585 typedef struct Z_NamePlusRecord
587 char *databaseName; /* OPTIONAL */
590 Z_NamePlusRecord_databaseRecord,
591 Z_NamePlusRecord_surrogateDiagnostic
596 Z_DatabaseRecord *databaseRecord;
597 Z_DiagRec *surrogateDiagnostic;
601 typedef struct Z_NamePlusRecordList
604 Z_NamePlusRecord **records;
605 } Z_NamePlusRecordList;
607 typedef struct Z_Records
613 Z_Records_multipleNSD
617 Z_NamePlusRecordList *databaseOrSurDiagnostics;
618 Z_DiagRec *nonSurrogateDiagnostic;
619 Z_DiagRecs *multipleNonSurDiagnostics;
623 /* ------------------------ SEARCHRESPONSE ------------------ */
625 typedef struct Z_SearchResponse
627 Z_ReferenceId *referenceId; /* OPTIONAL */
629 int *numberOfRecordsReturned;
630 int *nextResultSetPosition;
631 bool_t *searchStatus;
632 int *resultSetStatus; /* OPTIONAL */
633 #define Z_RES_SUBSET 1
634 #define Z_RES_INTERIM 2
636 int *presentStatus; /* OPTIONAL */
637 #define Z_PRES_SUCCESS 0
638 #define Z_PRES_PARTIAL_1 1
639 #define Z_PRES_PARTIAL_2 2
640 #define Z_PRES_PARTIAL_3 3
641 #define Z_PRES_PARTIAL_4 4
642 #define Z_PRES_FAILURE 5
643 Z_Records *records; /* OPTIONAL */
645 Z_OtherInformation *additionalSearchInfo;
646 Z_OtherInformation *otherInfo;
650 /* ------------------------- PRESENT SERVICE -----------------*/
652 typedef struct Z_ElementSpec
656 Z_ElementSpec_elementSetName,
657 Z_ElementSpec_externalSpec
661 char *elementSetName;
662 Z_External *externalSpec;
666 typedef struct Z_Specification
668 Odr_oid *schema; /* OPTIONAL */
669 Z_ElementSpec *elementSpec; /* OPTIONAL */
672 typedef struct Z_DbSpecific
675 Z_Specification *spec;
678 typedef struct Z_CompSpec
680 bool_t *selectAlternativeSyntax;
681 Z_Specification *generic; /* OPTIONAL */
683 Z_DbSpecific **dbSpecific; /* OPTIONAL */
684 int num_recordSyntax;
685 Odr_oid **recordSyntax; /* OPTIONAL */
688 typedef struct Z_RecordComposition
697 Z_ElementSetNames *simple;
700 } Z_RecordComposition;
702 typedef struct Z_Range
704 int *startingPosition;
705 int *numberOfRecords;
708 typedef struct Z_PresentRequest
710 Z_ReferenceId *referenceId; /* OPTIONAL */
711 Z_ResultSetId *resultSetId;
712 int *resultSetStartPoint;
713 int *numberOfRecordsRequested;
716 Z_Range **additionalRanges; /* OPTIONAL */
717 Z_RecordComposition *recordComposition; /* OPTIONAL */
719 Z_ElementSetNames *elementSetNames; /* OPTIONAL */
721 Odr_oid *preferredRecordSyntax; /* OPTIONAL */
723 int *maxSegmentCount; /* OPTIONAL */
724 int *maxRecordSize; /* OPTIONAL */
725 int *maxSegmentSize; /* OPTIONAL */
726 Z_OtherInformation *otherInfo; /* OPTIONAL */
730 typedef struct Z_PresentResponse
732 Z_ReferenceId *referenceId; /* OPTIONAL */
733 int *numberOfRecordsReturned;
734 int *nextResultSetPosition;
738 Z_OtherInformation *otherInfo; /* OPTIONAL */
742 /* ------------------ RESOURCE CONTROL ----------------*/
744 typedef struct Z_TriggerResourceControlRequest
746 Z_ReferenceId *referenceId; /* OPTIONAL */
747 int *requestedAction;
748 #define Z_TriggerResourceCtrl_resourceReport 1
749 #define Z_TriggerResourceCtrl_resourceControl 2
750 #define Z_TriggerResourceCtrl_cancel 3
751 Odr_oid *prefResourceReportFormat; /* OPTIONAL */
752 bool_t *resultSetWanted; /* OPTIONAL */
754 Z_OtherInformation *otherInfo;
756 } Z_TriggerResourceControlRequest;
758 typedef struct Z_ResourceControlRequest
760 Z_ReferenceId *referenceId; /* OPTIONAL */
761 bool_t *suspendedFlag; /* OPTIONAL */
762 Z_External *resourceReport; /* OPTIONAL */
763 int *partialResultsAvailable; /* OPTIONAL */
764 #define Z_ResourceControlRequest_subset 1
765 #define Z_ResourceControlRequest_interim 2
766 #define Z_ResourceControlRequest_none 3
767 bool_t *responseRequired;
768 bool_t *triggeredRequestFlag; /* OPTIONAL */
770 Z_OtherInformation *otherInfo;
772 } Z_ResourceControlRequest;
774 typedef struct Z_ResourceControlResponse
776 Z_ReferenceId *referenceId; /* OPTIONAL */
777 bool_t *continueFlag;
778 bool_t *resultSetWanted; /* OPTIONAL */
780 Z_OtherInformation *otherInfo;
782 } Z_ResourceControlResponse;
785 /* ------------------ ACCESS CTRL SERVICE ----------------*/
787 typedef struct Z_AccessControlRequest
789 Z_ReferenceId *referenceId; /* OPTIONAL */
792 Z_AccessRequest_simpleForm,
793 Z_AccessRequest_externallyDefined
798 Z_External *externallyDefined;
801 Z_OtherInformation *otherInfo; /* OPTIONAL */
803 } Z_AccessControlRequest;
805 typedef struct Z_AccessControlResponse
807 Z_ReferenceId *referenceId; /* OPTIONAL */
810 Z_AccessResponse_simpleForm,
811 Z_AccessResponse_externallyDefined
816 Z_External *externallyDefined;
818 Z_DiagRec *diagnostic; /* OPTIONAL */
820 Z_OtherInformation *otherInfo; /* OPTIONAL */
822 } Z_AccessControlResponse;
824 /* ------------------------ SCAN SERVICE -------------------- */
826 typedef struct Z_AttributeList
829 Z_AttributeElement **attributes;
832 typedef struct Z_AlternativeTerm
835 Z_AttributesPlusTerm **terms;
838 typedef struct Z_OccurrenceByAttributes
840 Z_AttributeList *attributes;
852 /* Z_ByDatabase *byDatabase; */
855 } Z_OccurrenceByAttributes;
857 typedef struct Z_TermInfo
860 Z_AttributeList *suggestedAttributes; /* OPTIONAL */
861 Z_AlternativeTerm *alternativeTerm; /* OPTIONAL */
862 int *globalOccurrences; /* OPTIONAL */
863 Z_OccurrenceByAttributes *byAttributes; /* OPTIONAL */
866 typedef struct Z_Entry
871 Z_Entry_surrogateDiagnostic
875 Z_TermInfo *termInfo;
876 Z_DiagRec *surrogateDiagnostic;
880 typedef struct Z_Entries
886 typedef struct Z_ListEntries
890 Z_ListEntries_entries,
891 Z_ListEntries_nonSurrogateDiagnostics
896 Z_DiagRecs *nonSurrogateDiagnostics;
900 typedef struct Z_ScanRequest
902 Z_ReferenceId *referenceId; /* OPTIONAL */
903 int num_databaseNames;
904 char **databaseNames;
905 Odr_oid *attributeSet; /* OPTIONAL */
906 Z_AttributesPlusTerm *termListAndStartPoint;
907 int *stepSize; /* OPTIONAL */
908 int *numberOfTermsRequested;
909 int *preferredPositionInResponse; /* OPTIONAL */
911 Z_OtherInformation *otherInfo;
915 typedef struct Z_ScanResponse
917 Z_ReferenceId *referenceId; /* OPTIONAL */
918 int *stepSize; /* OPTIONAL */
920 #define Z_Scan_success 0
921 #define Z_Scan_partial_1 1
922 #define Z_Scan_partial_2 2
923 #define Z_Scan_partial_3 3
924 #define Z_Scan_partial_4 4
925 #define Z_Scan_partial_5 5
926 #define Z_Scan_failure 6
927 int *numberOfEntriesReturned;
928 int *positionOfTerm; /* OPTIONAL */
929 Z_ListEntries *entries; /* OPTIONAL */
930 Odr_oid *attributeSet; /* OPTIONAL */
932 Z_OtherInformation *otherInfo;
937 /* ------------------------ DELETE -------------------------- */
939 #define Z_DeleteStatus_success 0
940 #define Z_DeleteStatus_resultSetDidNotExist 1
941 #define Z_DeleteStatus_previouslyDeletedByTarget 2
942 #define Z_DeleteStatus_systemProblemAtTarget 3
943 #define Z_DeleteStatus_accessNotAllowed 4
944 #define Z_DeleteStatus_resourceControlAtOrigin 5
945 #define Z_DeleteStatus_resourceControlAtTarget 6
946 #define Z_DeleteStatus_bulkDeleteNotSupported 7
947 #define Z_DeleteStatus_notAllRsltSetsDeletedOnBulkDlte 8
948 #define Z_DeleteStatus_notAllRequestedResultSetsDeleted 9
949 #define Z_DeleteStatus_resultSetInUse 10
951 typedef struct Z_ListStatus
957 typedef struct Z_DeleteResultSetRequest
959 Z_ReferenceId *referenceId; /* OPTIONAL */
961 #define Z_DeleteRequest_list 0
962 #define Z_DeleteRequest_all 1
964 Z_ResultSetId **resultSetList; /* OPTIONAL */
966 Z_OtherInformation *otherInfo;
968 } Z_DeleteResultSetRequest;
970 typedef struct Z_DeleteResultSetResponse
972 Z_ReferenceId *referenceId; /* OPTIONAL */
973 int *deleteOperationStatus;
975 Z_ListStatus *deleteListStatuses; /* OPTIONAL */
976 int *numberNotDeleted; /* OPTIONAL */
977 int num_bulkStatuses;
978 Z_ListStatus *bulkStatuses; /* OPTIONAL */
979 char *deleteMessage; /* OPTIONAL */
981 Z_OtherInformation *otherInfo;
983 } Z_DeleteResultSetResponse;
985 /* ------------------------ CLOSE SERVICE ------------------- */
987 typedef struct Z_Close
989 Z_ReferenceId *referenceId; /* OPTIONAL */
991 #define Z_Close_finished 0
992 #define Z_Close_shutdown 1
993 #define Z_Close_systemProblem 2
994 #define Z_Close_costLimit 3
995 #define Z_Close_resources 4
996 #define Z_Close_securityViolation 5
997 #define Z_Close_protocolError 6
998 #define Z_Close_lackOfActivity 7
999 #define Z_Close_peerAbort 8
1000 #define Z_Close_unspecified 9
1001 char *diagnosticInformation; /* OPTIONAL */
1002 Odr_oid *resourceReportFormat; /* OPTIONAL */
1003 Z_External *resourceReport; /* OPTIONAL */
1005 Z_OtherInformation *otherInfo; /* OPTIONAL */
1009 /* ------------------------ SEGMENTATION -------------------- */
1011 typedef struct Z_Segment
1013 Z_ReferenceId *referenceId; /* OPTIONAL */
1014 int *numberOfRecordsReturned;
1015 int num_segmentRecords;
1016 Z_NamePlusRecord **segmentRecords;
1017 Z_OtherInformation *otherInfo; /* OPTIONAL */
1021 /* ------------------------ APDU ---------------------------- */
1023 typedef struct Z_APDU
1028 Z_APDU_initResponse,
1029 Z_APDU_searchRequest,
1030 Z_APDU_searchResponse,
1031 Z_APDU_presentRequest,
1032 Z_APDU_presentResponse,
1033 Z_APDU_deleteResultSetRequest,
1034 Z_APDU_deleteResultSetResponse,
1035 Z_APDU_resourceControlRequest,
1036 Z_APDU_resourceControlResponse,
1037 Z_APDU_triggerResourceControlRequest,
1039 Z_APDU_scanResponse,
1040 Z_APDU_segmentRequest,
1045 Z_InitRequest *initRequest;
1046 Z_InitResponse *initResponse;
1047 Z_SearchRequest *searchRequest;
1048 Z_SearchResponse *searchResponse;
1049 Z_PresentRequest *presentRequest;
1050 Z_PresentResponse *presentResponse;
1051 Z_DeleteResultSetRequest *deleteResultSetRequest;
1052 Z_DeleteResultSetResponse *deleteResultSetResponse;
1053 Z_ResourceControlRequest *resourceControlRequest;
1054 Z_ResourceControlResponse *resourceControlResponse;
1055 Z_TriggerResourceControlRequest *triggerResourceControlRequest;
1056 Z_ScanRequest *scanRequest;
1057 Z_ScanResponse *scanResponse;
1058 Z_Segment *segmentRequest;
1063 int z_APDU(ODR o, Z_APDU **p, int opt);
1064 int z_SUTRS(ODR o, Odr_oct **p, int opt);
1066 Z_InitRequest *zget_InitRequest(ODR o);
1067 Z_InitResponse *zget_InitResponse(ODR o);
1068 Z_SearchRequest *zget_SearchRequest(ODR o);
1069 Z_SearchResponse *zget_SearchResponse(ODR o);
1070 Z_PresentRequest *zget_PresentRequest(ODR o);
1071 Z_PresentResponse *zget_PresentResponse(ODR o);
1072 Z_DeleteResultSetRequest *zget_DeleteResultSetRequest(ODR o);
1073 Z_DeleteResultSetResponse *zget_DeleteResultSetResponse(ODR o);
1074 Z_ScanRequest *zget_ScanRequest(ODR o);
1075 Z_ScanResponse *zget_ScanResponse(ODR o);
1076 Z_TriggerResourceControlRequest *zget_TriggerResourceControlRequest(ODR o);
1077 Z_ResourceControlRequest *zget_ResourceControlRequest(ODR o);
1078 Z_ResourceControlResponse *zget_ResourceControlResponse(ODR o);
1079 Z_Close *zget_Close(ODR o);
1080 int z_InternationalString(ODR o, char **p, int opt);
1081 int z_OtherInformation(ODR o, Z_OtherInformation **p, int opt);
1082 int z_ElementSetName(ODR o, char **p, int opt);
1083 int z_IntUnit(ODR o, Z_IntUnit **p, int opt);
1084 int z_Unit(ODR o, Z_Unit **p, int opt);
1085 int z_DatabaseName(ODR o, Z_DatabaseName **p, int opt);
1086 int z_StringOrNumeric(ODR o, Z_StringOrNumeric **p, int opt);
1087 int z_OtherInformationUnit(ODR o, Z_OtherInformationUnit **p, int opt);
1088 int z_Term(ODR o, Z_Term **p, int opt);
1089 int z_Specification(ODR o, Z_Specification **p, int opt);
1090 Z_APDU *zget_APDU(ODR o, enum Z_APDU_which which);
1092 #include <prt-rsc.h>
1093 #include <prt-acc.h>
1094 #include <prt-exp.h>
1095 #include <prt-ext.h>