1 | // basic elements for text
|
---|
2 |
|
---|
3 | module gsdlInterface {
|
---|
4 |
|
---|
5 | typedef sequence<unsigned short> usString;
|
---|
6 |
|
---|
7 | typedef sequence<string> stringSeq;
|
---|
8 |
|
---|
9 | //
|
---|
10 | // Used to textual arguments backwards and forwards across
|
---|
11 | // the interface. The encoding is 0 for full unicode character
|
---|
12 | // data and undefined otherwise.
|
---|
13 | //
|
---|
14 |
|
---|
15 | struct corbatext_t
|
---|
16 | {
|
---|
17 | usString text;
|
---|
18 | unsigned short encoding;
|
---|
19 | unsigned long length;
|
---|
20 | };
|
---|
21 |
|
---|
22 | typedef sequence<corbatext_t> corbatext_tarray;
|
---|
23 |
|
---|
24 | typedef corbatext_tarray corbatext_tset;
|
---|
25 |
|
---|
26 | //
|
---|
27 | // A map of names to values. Names may occur twice. Used largely
|
---|
28 | // for passing metadata around
|
---|
29 | //
|
---|
30 |
|
---|
31 | struct corbatext_tmap
|
---|
32 | {
|
---|
33 | corbatext_tarray names;
|
---|
34 | corbatext_tarray values;
|
---|
35 | };
|
---|
36 |
|
---|
37 | // standard error values
|
---|
38 |
|
---|
39 | enum corbaComError
|
---|
40 | {
|
---|
41 | // There were no errors
|
---|
42 | corbaNoError,
|
---|
43 | // The server could not authenticate the client or the
|
---|
44 | // authentication indicated insufficient priviledges
|
---|
45 | corbaAuthenticationFailure,
|
---|
46 | // ??
|
---|
47 | corbaProtocolError,
|
---|
48 | // ??
|
---|
49 | corbaConfigurationError,
|
---|
50 | // The server is unable to provide service due to an
|
---|
51 | // unspecified system problem on the server side.
|
---|
52 | corbaSystemProblem
|
---|
53 | };
|
---|
54 |
|
---|
55 | //
|
---|
56 | // getColInfo response
|
---|
57 | //
|
---|
58 |
|
---|
59 | struct corbaShortColInfo
|
---|
60 | {
|
---|
61 | // the textual name of the collection
|
---|
62 | corbatext_t name;
|
---|
63 | // the textual name of the server
|
---|
64 | corbatext_t host;
|
---|
65 | // ???
|
---|
66 | long response;
|
---|
67 | };
|
---|
68 |
|
---|
69 | struct corbaColInfoResponse
|
---|
70 | {
|
---|
71 | corbaShortColInfo shoftInfo;
|
---|
72 | // the collection is public
|
---|
73 | boolean isPublic;
|
---|
74 | // the collection is reliable
|
---|
75 | boolean isBeta;
|
---|
76 | // the timestamp of the collection building
|
---|
77 | unsigned long buildDate;
|
---|
78 | // ???
|
---|
79 | corbatext_tarray ccsCols; // Added 05/04/2000
|
---|
80 | // ???
|
---|
81 | corbatext_tarray languages;
|
---|
82 | // the number of documents in the collection
|
---|
83 | unsigned long numDocs;
|
---|
84 | // the number of words in the collection
|
---|
85 | unsigned long numWords;
|
---|
86 | // the number of bytes in the collection
|
---|
87 | unsigned long numBytes;
|
---|
88 | // the collection level metadata
|
---|
89 | corbatext_tmap collectionMeta;
|
---|
90 | // ???
|
---|
91 | corbatext_tmap format;
|
---|
92 | // ???
|
---|
93 | corbatext_tmap building;
|
---|
94 | // the domain for http request for associated files and images
|
---|
95 | corbatext_t httpdomain ; // Added 27/07/2000
|
---|
96 | // the domain for prefix request for associated files and images
|
---|
97 | corbatext_t httpprefix; // Added 27/07/2000
|
---|
98 | // the textual name of the receptionist
|
---|
99 | corbatext_t receptionist;
|
---|
100 | };
|
---|
101 |
|
---|
102 | //
|
---|
103 | // getDocument request
|
---|
104 | //
|
---|
105 |
|
---|
106 | struct corbaDocRequest
|
---|
107 | {
|
---|
108 | // the document ID
|
---|
109 | corbatext_t OID;
|
---|
110 | // the mine type the Doc should be in, or "" for any
|
---|
111 | corbatext_t docType;
|
---|
112 | // ??
|
---|
113 | corbatext_t docFormat;
|
---|
114 | };
|
---|
115 |
|
---|
116 | //
|
---|
117 | // getDocument response
|
---|
118 | //
|
---|
119 |
|
---|
120 | struct corbaDocResponse
|
---|
121 | {
|
---|
122 | // the actual document
|
---|
123 | corbatext_t doc;
|
---|
124 | };
|
---|
125 |
|
---|
126 | enum corbaFilterType
|
---|
127 | {
|
---|
128 | booleanType,
|
---|
129 | integerType,
|
---|
130 | enumeratedType,
|
---|
131 | stringType
|
---|
132 | };
|
---|
133 |
|
---|
134 | enum corbaFilterRepeatable
|
---|
135 | {
|
---|
136 | onePerQuery,
|
---|
137 | onePerTerm,
|
---|
138 | nPerTerm
|
---|
139 | };
|
---|
140 |
|
---|
141 | struct corbaFilterOption
|
---|
142 | {
|
---|
143 | corbatext_t name;
|
---|
144 | corbaFilterType type;
|
---|
145 | corbaFilterRepeatable repeatable;
|
---|
146 | corbatext_t defaultValue;
|
---|
147 | corbatext_tarray validValues;
|
---|
148 | };
|
---|
149 |
|
---|
150 | typedef sequence<corbaFilterOption> corbaFilterOptionList;
|
---|
151 |
|
---|
152 | struct corbaFilterOptionsResponse
|
---|
153 | {
|
---|
154 | corbaFilterOptionList options;
|
---|
155 | corbatext_tarray names;
|
---|
156 | };
|
---|
157 |
|
---|
158 | //
|
---|
159 | // structures for filter call
|
---|
160 | //
|
---|
161 |
|
---|
162 | struct corbaOptionValue
|
---|
163 | {
|
---|
164 | corbatext_t name;
|
---|
165 | corbatext_t value;
|
---|
166 | };
|
---|
167 |
|
---|
168 | typedef sequence<corbaOptionValue> corbaOptionValue_array;
|
---|
169 |
|
---|
170 | struct corbaFilterRequest
|
---|
171 | {
|
---|
172 | corbatext_t filter;
|
---|
173 | corbaOptionValue_array filterOptions;
|
---|
174 | corbatext_tarray docSet;
|
---|
175 | long filterResultOptions;
|
---|
176 | corbatext_t requestParams;
|
---|
177 | corbatext_t refParams;
|
---|
178 | corbatext_tset fields;
|
---|
179 | boolean getParents;
|
---|
180 | };
|
---|
181 |
|
---|
182 | struct corbaTermInfo
|
---|
183 | {
|
---|
184 | corbatext_t term;
|
---|
185 | long frequency;
|
---|
186 | corbatext_tarray matchTerms;
|
---|
187 | };
|
---|
188 |
|
---|
189 | typedef sequence<corbaTermInfo> corbaTermInfo_array;
|
---|
190 |
|
---|
191 | struct corbaMetadataInfo
|
---|
192 | {
|
---|
193 | corbatext_t params;
|
---|
194 | boolean isRef;
|
---|
195 | corbatext_tarray values;
|
---|
196 | long id;
|
---|
197 | long parentid; // dodge for avoiding pointers for the moment
|
---|
198 | };
|
---|
199 |
|
---|
200 | typedef sequence<corbaMetadataInfo> corbaMetadataInfo_array;
|
---|
201 |
|
---|
202 | struct corbaMetadataInfo_map
|
---|
203 | {
|
---|
204 | corbatext_tarray names;
|
---|
205 | corbaMetadataInfo_array values;
|
---|
206 | };
|
---|
207 |
|
---|
208 | typedef sequence<long> corbaDocFreq_array;
|
---|
209 |
|
---|
210 | struct corbaResultDocInfo
|
---|
211 | {
|
---|
212 | corbatext_t OID;
|
---|
213 | long resultNum;
|
---|
214 | long ranking;
|
---|
215 | long termsMatched;
|
---|
216 | long phraseMatched;
|
---|
217 | corbaDocFreq_array docFreq;
|
---|
218 | corbaMetadataInfo_map metadata;
|
---|
219 | corbatext_t classifierMetadataType; // Added 05/04/2000
|
---|
220 | long classifierMetadataOffset; // Added 05/04/2000
|
---|
221 | corbaMetadataInfo_array metaparents;
|
---|
222 | };
|
---|
223 |
|
---|
224 | typedef sequence<corbaResultDocInfo> corbaResultDocInfo_array;
|
---|
225 |
|
---|
226 | enum corbaIsApprox
|
---|
227 | {
|
---|
228 | resultExact,
|
---|
229 | resultApprox,
|
---|
230 | resultMany
|
---|
231 | };
|
---|
232 |
|
---|
233 | struct corbaFilterResponse
|
---|
234 | {
|
---|
235 | long numDocs;
|
---|
236 | corbaIsApprox isApprox;
|
---|
237 | corbaTermInfo_array termInfo;
|
---|
238 | corbaResultDocInfo_array docInfo;
|
---|
239 | };
|
---|
240 |
|
---|
241 | interface corbaiface
|
---|
242 | {
|
---|
243 | boolean initialise(inout corbaComError error);
|
---|
244 | void configure(in corbatext_t key, in corbatext_tarray cfgline,
|
---|
245 | inout corbaComError error);
|
---|
246 | void collectionList(inout corbatext_tarray collist,
|
---|
247 | inout corbaComError error);
|
---|
248 | void hasCollection(in corbatext_t corbaCollection, inout boolean has,
|
---|
249 | inout corbaComError error);
|
---|
250 | void ping(in corbatext_t collection, inout boolean wasSuccess, inout corbaComError error);
|
---|
251 | void getDocument(in corbatext_t collection,
|
---|
252 | inout corbaDocRequest request, inout corbaDocResponse response,
|
---|
253 | inout corbaComError error);
|
---|
254 | void getCollectInfo(in corbatext_t collection,
|
---|
255 | inout corbaColInfoResponse response,
|
---|
256 | inout corbaComError error);
|
---|
257 | void getFilterInfo(in corbatext_t collection,
|
---|
258 | inout corbatext_tarray filterNames,
|
---|
259 | inout corbaComError error);
|
---|
260 | void getFilterOptions(in corbatext_t collection,
|
---|
261 | in corbatext_t option,
|
---|
262 | inout corbaFilterOptionsResponse response,
|
---|
263 | inout corbaComError error);
|
---|
264 | void filter(in corbatext_t collection,
|
---|
265 | in corbaFilterRequest request,
|
---|
266 | inout corbaFilterResponse response,
|
---|
267 | inout corbaComError error);
|
---|
268 | };
|
---|
269 |
|
---|
270 | };
|
---|