File: deprecation.html

package info (click to toggle)
xapian-core 1.4.3-2%2Bdeb9u3
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 21,412 kB
  • sloc: cpp: 113,868; ansic: 8,723; sh: 4,433; perl: 836; makefile: 566; tcl: 317; python: 40
file content (1358 lines) | stat: -rw-r--r-- 58,376 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
<?xml version="1.0" encoding="utf-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="generator" content="Docutils 0.13.1: http://docutils.sourceforge.net/" />
<title>Deprecation</title>
<style type="text/css">

/*
:Author: David Goodger (goodger@python.org)
:Id: $Id: html4css1.css 7952 2016-07-26 18:15:59Z milde $
:Copyright: This stylesheet has been placed in the public domain.

Default cascading style sheet for the HTML output of Docutils.

See http://docutils.sf.net/docs/howto/html-stylesheets.html for how to
customize this style sheet.
*/

/* used to remove borders from tables and images */
.borderless, table.borderless td, table.borderless th {
  border: 0 }

table.borderless td, table.borderless th {
  /* Override padding for "table.docutils td" with "! important".
     The right padding separates the table cells. */
  padding: 0 0.5em 0 0 ! important }

.first {
  /* Override more specific margin styles with "! important". */
  margin-top: 0 ! important }

.last, .with-subtitle {
  margin-bottom: 0 ! important }

.hidden {
  display: none }

.subscript {
  vertical-align: sub;
  font-size: smaller }

.superscript {
  vertical-align: super;
  font-size: smaller }

a.toc-backref {
  text-decoration: none ;
  color: black }

blockquote.epigraph {
  margin: 2em 5em ; }

dl.docutils dd {
  margin-bottom: 0.5em }

object[type="image/svg+xml"], object[type="application/x-shockwave-flash"] {
  overflow: hidden;
}

/* Uncomment (and remove this text!) to get bold-faced definition list terms
dl.docutils dt {
  font-weight: bold }
*/

div.abstract {
  margin: 2em 5em }

div.abstract p.topic-title {
  font-weight: bold ;
  text-align: center }

div.admonition, div.attention, div.caution, div.danger, div.error,
div.hint, div.important, div.note, div.tip, div.warning {
  margin: 2em ;
  border: medium outset ;
  padding: 1em }

div.admonition p.admonition-title, div.hint p.admonition-title,
div.important p.admonition-title, div.note p.admonition-title,
div.tip p.admonition-title {
  font-weight: bold ;
  font-family: sans-serif }

div.attention p.admonition-title, div.caution p.admonition-title,
div.danger p.admonition-title, div.error p.admonition-title,
div.warning p.admonition-title, .code .error {
  color: red ;
  font-weight: bold ;
  font-family: sans-serif }

/* Uncomment (and remove this text!) to get reduced vertical space in
   compound paragraphs.
div.compound .compound-first, div.compound .compound-middle {
  margin-bottom: 0.5em }

div.compound .compound-last, div.compound .compound-middle {
  margin-top: 0.5em }
*/

div.dedication {
  margin: 2em 5em ;
  text-align: center ;
  font-style: italic }

div.dedication p.topic-title {
  font-weight: bold ;
  font-style: normal }

div.figure {
  margin-left: 2em ;
  margin-right: 2em }

div.footer, div.header {
  clear: both;
  font-size: smaller }

div.line-block {
  display: block ;
  margin-top: 1em ;
  margin-bottom: 1em }

div.line-block div.line-block {
  margin-top: 0 ;
  margin-bottom: 0 ;
  margin-left: 1.5em }

div.sidebar {
  margin: 0 0 0.5em 1em ;
  border: medium outset ;
  padding: 1em ;
  background-color: #ffffee ;
  width: 40% ;
  float: right ;
  clear: right }

div.sidebar p.rubric {
  font-family: sans-serif ;
  font-size: medium }

div.system-messages {
  margin: 5em }

div.system-messages h1 {
  color: red }

div.system-message {
  border: medium outset ;
  padding: 1em }

div.system-message p.system-message-title {
  color: red ;
  font-weight: bold }

div.topic {
  margin: 2em }

h1.section-subtitle, h2.section-subtitle, h3.section-subtitle,
h4.section-subtitle, h5.section-subtitle, h6.section-subtitle {
  margin-top: 0.4em }

h1.title {
  text-align: center }

h2.subtitle {
  text-align: center }

hr.docutils {
  width: 75% }

img.align-left, .figure.align-left, object.align-left, table.align-left {
  clear: left ;
  float: left ;
  margin-right: 1em }

img.align-right, .figure.align-right, object.align-right, table.align-right {
  clear: right ;
  float: right ;
  margin-left: 1em }

img.align-center, .figure.align-center, object.align-center {
  display: block;
  margin-left: auto;
  margin-right: auto;
}

table.align-center {
  margin-left: auto;
  margin-right: auto;
}

.align-left {
  text-align: left }

.align-center {
  clear: both ;
  text-align: center }

.align-right {
  text-align: right }

/* reset inner alignment in figures */
div.align-right {
  text-align: inherit }

/* div.align-center * { */
/*   text-align: left } */

.align-top    {
  vertical-align: top }

.align-middle {
  vertical-align: middle }

.align-bottom {
  vertical-align: bottom }

ol.simple, ul.simple {
  margin-bottom: 1em }

ol.arabic {
  list-style: decimal }

ol.loweralpha {
  list-style: lower-alpha }

ol.upperalpha {
  list-style: upper-alpha }

ol.lowerroman {
  list-style: lower-roman }

ol.upperroman {
  list-style: upper-roman }

p.attribution {
  text-align: right ;
  margin-left: 50% }

p.caption {
  font-style: italic }

p.credits {
  font-style: italic ;
  font-size: smaller }

p.label {
  white-space: nowrap }

p.rubric {
  font-weight: bold ;
  font-size: larger ;
  color: maroon ;
  text-align: center }

p.sidebar-title {
  font-family: sans-serif ;
  font-weight: bold ;
  font-size: larger }

p.sidebar-subtitle {
  font-family: sans-serif ;
  font-weight: bold }

p.topic-title {
  font-weight: bold }

pre.address {
  margin-bottom: 0 ;
  margin-top: 0 ;
  font: inherit }

pre.literal-block, pre.doctest-block, pre.math, pre.code {
  margin-left: 2em ;
  margin-right: 2em }

pre.code .ln { color: grey; } /* line numbers */
pre.code, code { background-color: #eeeeee }
pre.code .comment, code .comment { color: #5C6576 }
pre.code .keyword, code .keyword { color: #3B0D06; font-weight: bold }
pre.code .literal.string, code .literal.string { color: #0C5404 }
pre.code .name.builtin, code .name.builtin { color: #352B84 }
pre.code .deleted, code .deleted { background-color: #DEB0A1}
pre.code .inserted, code .inserted { background-color: #A3D289}

span.classifier {
  font-family: sans-serif ;
  font-style: oblique }

span.classifier-delimiter {
  font-family: sans-serif ;
  font-weight: bold }

span.interpreted {
  font-family: sans-serif }

span.option {
  white-space: nowrap }

span.pre {
  white-space: pre }

span.problematic {
  color: red }

span.section-subtitle {
  /* font-size relative to parent (h1..h6 element) */
  font-size: 80% }

table.citation {
  border-left: solid 1px gray;
  margin-left: 1px }

table.docinfo {
  margin: 2em 4em }

table.docutils {
  margin-top: 0.5em ;
  margin-bottom: 0.5em }

table.footnote {
  border-left: solid 1px black;
  margin-left: 1px }

table.docutils td, table.docutils th,
table.docinfo td, table.docinfo th {
  padding-left: 0.5em ;
  padding-right: 0.5em ;
  vertical-align: top }

table.docutils th.field-name, table.docinfo th.docinfo-name {
  font-weight: bold ;
  text-align: left ;
  white-space: nowrap ;
  padding-left: 0 }

/* "booktabs" style (no vertical lines) */
table.docutils.booktabs {
  border: 0px;
  border-top: 2px solid;
  border-bottom: 2px solid;
  border-collapse: collapse;
}
table.docutils.booktabs * {
  border: 0px;
}
table.docutils.booktabs th {
  border-bottom: thin solid;
  text-align: left;
}

h1 tt.docutils, h2 tt.docutils, h3 tt.docutils,
h4 tt.docutils, h5 tt.docutils, h6 tt.docutils {
  font-size: 100% }

ul.auto-toc {
  list-style-type: none }

</style>
</head>
<body>
<div class="document" id="deprecation">
<h1 class="title">Deprecation</h1>

<!-- This document was originally written by Richard Boulton. -->
<!-- Copyright (C) 2007 Lemur Consulting Ltd -->
<!-- Copyright (C) 2007,2008,2009,2010,2011,2012,2013,2015,2016 Olly Betts -->
<div class="contents topic" id="table-of-contents">
<p class="topic-title first">Table of contents</p>
<ul class="simple">
<li><a class="reference internal" href="#introduction" id="id22">Introduction</a></li>
<li><a class="reference internal" href="#deprecation-procedure" id="id23">Deprecation Procedure</a><ul>
<li><a class="reference internal" href="#deprecation-markers" id="id24">Deprecation markers</a></li>
<li><a class="reference internal" href="#api-and-abi-compatibility" id="id25">API and ABI compatibility</a></li>
<li><a class="reference internal" href="#experimental-features" id="id26">Experimental features</a></li>
<li><a class="reference internal" href="#deprecation-in-the-bindings" id="id27">Deprecation in the bindings</a></li>
</ul>
</li>
<li><a class="reference internal" href="#support-for-other-software" id="id28">Support for Other Software</a></li>
<li><a class="reference internal" href="#how-to-avoid-using-deprecated-features" id="id29">How to avoid using deprecated features</a></li>
<li><a class="reference internal" href="#features-currently-marked-for-deprecation" id="id30">Features currently marked for deprecation</a><ul>
<li><a class="reference internal" href="#native-c-api" id="id31">Native C++ API</a></li>
<li><a class="reference internal" href="#bindings" id="id32">Bindings</a></li>
<li><a class="reference internal" href="#omega" id="id33">Omega</a></li>
</ul>
</li>
<li><a class="reference internal" href="#features-removed-from-xapian" id="id34">Features removed from Xapian</a><ul>
<li><a class="reference internal" href="#id1" id="id35">Native C++ API</a></li>
<li><a class="reference internal" href="#id2" id="id36">Bindings</a></li>
<li><a class="reference internal" href="#id21" id="id37">Omega</a></li>
</ul>
</li>
</ul>
</div>
<div class="section" id="introduction">
<h1><a class="toc-backref" href="#id22">Introduction</a></h1>
<p>Xapian's API is fairly stable and has been polished piece by piece over time,
but it still occasionally needs to be changed.  This may be because a new
feature has been implemented and the interface needs to allow access to it, but
it may also be required in order to polish a rough edge which has been missed
in earlier versions of Xapian, or simply to reflect an internal change which
requires a modification to the external interface.</p>
<p>We aim to make such changes in a way that allows developers to work against a
stable API, while avoiding the need for the Xapian developers to maintain too
many old historical interface artefacts.  This document describes the process
we use to deprecate old pieces of the API, lists parts of the API which are
currently marked as deprecated, and also describes parts of the API which have
been deprecated for some time, and are now removed from the Xapian library.</p>
<p>It is possible for functions, methods, constants, types or even whole classes
to be deprecated, but to save words this document will often use the term
&quot;features&quot; to refer collectively to any of these types of interface items.</p>
</div>
<div class="section" id="deprecation-procedure">
<h1><a class="toc-backref" href="#id23">Deprecation Procedure</a></h1>
<div class="section" id="deprecation-markers">
<h2><a class="toc-backref" href="#id24">Deprecation markers</a></h2>
<p>At any particular point, some parts of the C++ API will be marked as
&quot;deprecated&quot;.  Deprecated features are annotated in the API headers with macros
such as <tt class="docutils literal">XAPIAN_DEPRECATED()</tt>, which will cause compilers with appropriate
support (such as GCC 3.1 or later, and MSVC 7.0 or later) to emit compile-time
warnings if these features are used.</p>
<p>If a feature is marked with one of these markers, you should avoid using it in
new code, and should migrate your code to use a replacement when possible.  The
documentation comments for the feature, or the list at the end
of this file, will describe possible alternatives to the deprecated feature.</p>
<p>If you want to disable deprecation warnings temporarily, you can do so
by passing <tt class="docutils literal"><span class="pre">&quot;-DXAPIAN_DEPRECATED(X)=X&quot;</span></tt> to the compiler (the quotes are
needed to protect the brackets from the shell).  If your build system uses
make, you might do this like so:</p>
<pre class="literal-block">
make 'CPPFLAGS=&quot;-DXAPIAN_DEPRECATED(X)=X&quot;'
</pre>
</div>
<div class="section" id="api-and-abi-compatibility">
<h2><a class="toc-backref" href="#id25">API and ABI compatibility</a></h2>
<p>Releases are given three-part version numbers (e.g. 1.2.9), the three parts
being termed &quot;major&quot; (1), &quot;minor&quot; (2), and &quot;revision&quot; (9).  Releases with
the same major and minor version are termed a &quot;release series&quot;.</p>
<p>For Xapian releases 1.0.0 and higher, an even minor version indicates a stable
release series, while an odd minor version indicates a development release
series.</p>
<p>Within a stable release series, we strive to maintain API and ABI forwards
compatibility.  This means that an application written and compiled against
version <cite>X.Y.a</cite> of Xapian should work, without any source changes or need to
recompile, with a later version <cite>X.Y.b</cite>, for all <cite>b</cite> &gt;= <cite>a</cite>.
Stable releases which increase the minor or major version number will usually
change the ABI incompatibly (so that code will need to be recompiled against
the newer release series.  They may also make incompatible API changes,
though we will attempt to do this in a way which makes it reasonably easy to
migrate applications, and document how to do so in this document.</p>
<p>It is possible that a feature may be marked as deprecated within a minor
release series - that is from version <cite>X.Y.c</cite>
onwards, where <cite>c</cite> is not zero.  The API and ABI will not be changed by this
deprecation, since the feature will still be available in the API (though the
change may cause the compiler to emit new warnings when rebuilding code
which uses the now-deprecated feature).</p>
<p>Users should generally be able to expect working code which uses Xapian not to
stop working without reason.  We attempt to codify this in the following
policy, but we reserve the right not to slavishly follow this.  The spirit of
the rule should kept in mind - for example if we discovered a feature which
didn't actually work, making an incompatible API change at the next ABI bump
would be reasonable.</p>
<p>Normally a feature will be supported after being deprecated for an entire
stable release series.  For example, if a feature is deprecated in release
1.2.0, it will be supported for the entire 1.2.x release series, and removed in
development release 1.3.0.  If a feature is deprecated in release 1.2.1, it
will be supported for the 1.2.x <em>and</em> 1.4.x stable release series (and of
course the 1.3.x release series in between), and won't be removed until
1.5.0.</p>
</div>
<div class="section" id="experimental-features">
<h2><a class="toc-backref" href="#id26">Experimental features</a></h2>
<p>During a development release series (such as the 1.1.x series), some features
may be marked as &quot;experimental&quot;.  Such features are liable to change without
going through the normal deprecation procedure.  This includes changing on-disk
formats for data stored by the feature, and breaking API and ABI compatibility
between releases for the feature.  Such features are included in releases to
get wider use and corresponding feedback about them.</p>
</div>
<div class="section" id="deprecation-in-the-bindings">
<h2><a class="toc-backref" href="#id27">Deprecation in the bindings</a></h2>
<p>When the Xapian API changes, the interface provided by the Xapian bindings will
usually change in step.  In addition, it is sometimes necessary to change the
way in which Xapian is wrapped by bindings - for example, to provide a better
convenience wrapper for iterators in Python.  Again, we aim to ensure that an
application written (and compiled, if the language being bound is a compiled
language) for version <cite>X.Y.a</cite> of Xapian should work without any changes or need
to recompile, with a later version <cite>X.Y.b</cite>, for all <cite>a</cite> &lt;= <cite>b</cite>.</p>
<p>However, the bindings are a little less mature than the core C++ API, so we
don't intend to give the same guarantee that a feature present and not
deprecated in version <cite>X.Y.a</cite> will work in all versions <cite>X+1.Y.b</cite>.  In other
words, we may remove features which have been deprecated without waiting for
an entire release series to pass.</p>
<p>Any planned deprecations will be documented in the list of deprecations and
removed features at the end of this file.</p>
</div>
</div>
<div class="section" id="support-for-other-software">
<h1><a class="toc-backref" href="#id28">Support for Other Software</a></h1>
<p>Support for other software doesn't follow the same deprecation rules as
for API features.</p>
<p>Our guiding principle for supporting version of other software is that
we don't aim to actively support versions which are no longer supported
&quot;upstream&quot;.</p>
<p>So Xapian 1.1.0 doesn't support PHP4 because the PHP team no longer did
when it was released.  By the API deprecation rules we should have announced
this when Xapian 1.0.0 was released, but we don't have control over when and
to what timescales other software providers discontinue support for older
versions.</p>
<p>Sometimes we can support such versions without extra effort (e.g. Tcl's
stubs mechanism means Tcl 8.1 probably still works, even though the last
8.1.x release was over a decade ago), and in some cases Linux distros
continue to support software after upstream stops.</p>
<p>But in most cases keeping support around is a maintenance overhead and
we'd rather spend our time on more useful things.</p>
<p>Note that there's no guarantee that we will support and continue to
support versions just because upstream still does.  For example, we ceased
providing backported packages for Ubuntu dapper with Xapian 1.1.0 - in this
case, it's because we felt that if you're conservative enough to run dapper,
you'd probably prefer to stick with 1.0.x until you upgrade to hardy (the next
Ubuntu LTS release).  But we may decide not to support versions for other
reasons too.</p>
</div>
<div class="section" id="how-to-avoid-using-deprecated-features">
<h1><a class="toc-backref" href="#id29">How to avoid using deprecated features</a></h1>
<p>We recommend taking the following steps to avoid depending on deprecated
features when writing your applications:</p>
<blockquote>
<ul class="simple">
<li>If at all possible, test compile your project using a compiler which
supports warnings about deprecated features (such as GCC 3.1 or later), and
check for such warnings.  Use the -Werror flag to GCC to ensure that you
don't miss any of them.</li>
<li>Check the NEWS file for each new release for details of any new features
which are deprecated in the release.</li>
<li>Check the documentation comments, or the automatically extracted API
documentation, for each feature you use in your application.  This
documentation will indicate features which are deprecated, or planned for
deprecation.</li>
<li>For applications which are not written in C++, there is currently no
equivalent of the <tt class="docutils literal">XAPIAN_DEPRECATED</tt> macro for the bindings, and thus
there is no way for the bindings to give a warning if a deprecated feature
is used.  This would be a nice addition for those languages in which there
is a reasonable way to give such warnings.  Until such a feature is
implemented, all application writers using the bindings can do is to check
the list of deprecated features in each new release, or lookup the features
they are using in the list at the end of this file.</li>
</ul>
</blockquote>
</div>
<div class="section" id="features-currently-marked-for-deprecation">
<h1><a class="toc-backref" href="#id30">Features currently marked for deprecation</a></h1>
<div class="section" id="native-c-api">
<h2><a class="toc-backref" href="#id31">Native C++ API</a></h2>
<!-- Substitution definitions for feature names which are two wide for the column: -->
<!-- Keep table width to <= 126 columns. -->
<table border="1" class="docutils">
<colgroup>
<col width="8%" />
<col width="5%" />
<col width="28%" />
<col width="59%" />
</colgroup>
<thead valign="bottom">
<tr><th class="head">Deprecated</th>
<th class="head">Remove</th>
<th class="head">Feature name</th>
<th class="head">Upgrade suggestion and comments</th>
</tr>
</thead>
<tbody valign="top">
<tr><td>1.3.1</td>
<td>1.5.0</td>
<td><tt class="docutils literal"><span class="pre">Xapian::ErrorHandler</span></tt></td>
<td>We feel the current ErrorHandler API doesn't work at the right level (it
only works in Enquire, whereas you should be able to handle errors at
the Database level too) and we can't find any evidence that people are
actually using it.  So we've made the API a no-op and marked it as
deprecated.  The hope is to replace it with something better thought
out, probably during the 1.4.x release series.  There's some further
thoughts at <a class="reference external" href="https://trac.xapian.org/ticket/3#comment:8">https://trac.xapian.org/ticket/3#comment:8</a></td>
</tr>
<tr><td>1.3.2</td>
<td>1.5.0</td>
<td><tt class="docutils literal"><span class="pre">Xapian::Auto::open_stub()</span></tt></td>
<td>Use the constructor with <tt class="docutils literal"><span class="pre">Xapian::DB_BACKEND_STUB</span></tt> flag (new in 1.3.2)
instead.</td>
</tr>
<tr><td>1.3.2</td>
<td>1.5.0</td>
<td><tt class="docutils literal"><span class="pre">Xapian::Chert::open()</span></tt></td>
<td>Use the constructor with <tt class="docutils literal"><span class="pre">Xapian::DB_BACKEND_CHERT</span></tt> flag (new in
1.3.2) instead.</td>
</tr>
<tr><td>1.3.3</td>
<td>1.5.0</td>
<td><tt class="docutils literal"><span class="pre">Xapian::QueryParser::set_max_wildcard_expansion()</span></tt></td>
<td>Use <tt class="docutils literal"><span class="pre">Xapian::QueryParser::set_max_expansion()</span></tt> instead.</td>
</tr>
<tr><td>1.3.4</td>
<td>1.5.0</td>
<td><tt class="docutils literal"><span class="pre">Xapian::Compactor</span></tt> methods
<tt class="docutils literal">set_block_size()</tt>,
<tt class="docutils literal">set_renumber()</tt>,
<tt class="docutils literal">set_multipass()</tt>,
<tt class="docutils literal">set_compaction_level()</tt>,
<tt class="docutils literal">set_destdir()</tt>, <tt class="docutils literal"><span class="pre">add_source()`</span>
and ``compact()</tt>.</td>
<td>Use the <tt class="docutils literal"><span class="pre">Xapian::Database::compact()</span></tt> method instead.  The
<tt class="docutils literal"><span class="pre">Xapian::Compact</span></tt> is now just a subclassable functor class to allow
access to progress messages and control over merging of user metadata.</td>
</tr>
<tr><td>1.3.5</td>
<td>1.5.0</td>
<td><tt class="docutils literal"><span class="pre">Xapian::PostingSource</span></tt> public
variables</td>
<td>Use the respective getter and setter methods instead, added in 1.3.5 and
1.2.23.</td>
</tr>
<tr><td>1.3.5</td>
<td>1.5.0</td>
<td><tt class="docutils literal"><span class="pre">Xapian::InMemory::open()</span></tt></td>
<td>Use the constructor with <tt class="docutils literal"><span class="pre">Xapian::DB_BACKEND_INMEMORY</span></tt> flag (new in
1.3.5) instead.</td>
</tr>
<tr><td>1.3.6</td>
<td>1.5.0</td>
<td><tt class="docutils literal"><span class="pre">Xapian::WritableDatabase::flush()</span></tt></td>
<td>Use <tt class="docutils literal"><span class="pre">Xapian::WritableDatabase::commit()</span></tt> instead (available since
1.1.0).</td>
</tr>
<tr><td>1.3.6</td>
<td>1.5.0</td>
<td>Subclassing <tt class="docutils literal"><span class="pre">Xapian::ValueRangeProcessor</span></tt></td>
<td>Subclass <tt class="docutils literal"><span class="pre">Xapian::RangeProcessor</span></tt> instead, and return a
<tt class="docutils literal"><span class="pre">Xapian::Query</span></tt> from <tt class="docutils literal"><span class="pre">operator()()</span></tt>.</td>
</tr>
<tr><td>1.3.6</td>
<td>1.5.0</td>
<td>Subclassing <tt class="docutils literal"><span class="pre">Xapian::DateValueRangeProcessor</span></tt></td>
<td>Subclass <tt class="docutils literal"><span class="pre">Xapian::DateRangeProcessor</span></tt> instead, and return a
<tt class="docutils literal"><span class="pre">Xapian::Query</span></tt> from <tt class="docutils literal"><span class="pre">operator()()</span></tt>.</td>
</tr>
<tr><td>1.3.6</td>
<td>1.5.0</td>
<td>Subclassing <tt class="docutils literal"><span class="pre">Xapian::NumberValueRangeProcessor</span></tt></td>
<td>Subclass <tt class="docutils literal"><span class="pre">Xapian::NumberRangeProcessor</span></tt> instead, and return a
<tt class="docutils literal"><span class="pre">Xapian::Query</span></tt> from <tt class="docutils literal"><span class="pre">operator()()</span></tt>.</td>
</tr>
<tr><td>1.3.6</td>
<td>1.5.0</td>
<td>Subclassing <tt class="docutils literal"><span class="pre">Xapian::StringValueRangeProcessor</span></tt></td>
<td>Subclass <tt class="docutils literal"><span class="pre">Xapian::RangeProcessor</span></tt> instead (which includes equivalent
support for prefix/suffix checking), and return a <tt class="docutils literal"><span class="pre">Xapian::Query</span></tt> from
<tt class="docutils literal"><span class="pre">operator()()</span></tt>.</td>
</tr>
<tr><td>1.3.6</td>
<td>1.5.0</td>
<td><tt class="docutils literal"><span class="pre">Xapian::QueryParser::add_valuerangeprocessor()</span></tt></td>
<td>Use <tt class="docutils literal"><span class="pre">Xapian::QueryParser::add_rangeprocessor()</span></tt> instead, with a
<tt class="docutils literal"><span class="pre">Xapian::RangeProcessor</span></tt> object instead of a <tt class="docutils literal"><span class="pre">Xapian::ValueRangeProcessor</span></tt> object.</td>
</tr>
</tbody>
</table>
</div>
<div class="section" id="bindings">
<h2><a class="toc-backref" href="#id32">Bindings</a></h2>
<!-- Keep table width to <= 126 columns. -->
<table border="1" class="docutils">
<colgroup>
<col width="8%" />
<col width="5%" />
<col width="7%" />
<col width="23%" />
<col width="57%" />
</colgroup>
<thead valign="bottom">
<tr><th class="head">Deprecated</th>
<th class="head">Remove</th>
<th class="head">Language</th>
<th class="head">Feature name</th>
<th class="head">Upgrade suggestion and comments</th>
</tr>
</thead>
<tbody valign="top">
<tr><td>1.2.5</td>
<td>1.5.0</td>
<td>Python</td>
<td>MSet.items</td>
<td>Iterate the MSet object itself instead.</td>
</tr>
<tr><td>1.2.5</td>
<td>1.5.0</td>
<td>Python</td>
<td>ESet.items</td>
<td>Iterate the ESet object itself instead.</td>
</tr>
</tbody>
</table>
</div>
<div class="section" id="omega">
<h2><a class="toc-backref" href="#id33">Omega</a></h2>
<!-- Keep table width to <= 126 columns. -->
<table border="1" class="docutils">
<colgroup>
<col width="8%" />
<col width="5%" />
<col width="28%" />
<col width="59%" />
</colgroup>
<thead valign="bottom">
<tr><th class="head">Deprecated</th>
<th class="head">Remove</th>
<th class="head">Feature name</th>
<th class="head">Upgrade suggestion and comments</th>
</tr>
</thead>
<tbody valign="top">
<tr><td>1.2.4</td>
<td>1.5.0</td>
<td>omindex command line long option
<tt class="docutils literal"><span class="pre">--preserve-nonduplicates</span></tt>.</td>
<td>Renamed to <tt class="docutils literal"><span class="pre">--no-delete</span></tt>, which works in 1.2.4 and later.</td>
</tr>
<tr><td>1.2.5</td>
<td>1.5.0</td>
<td>$set{spelling,true}</td>
<td>Use $set{flag_spelling_suggestion,true} instead.</td>
</tr>
</tbody>
</table>
<!-- Features currently marked as experimental -->
<!-- ========================================= -->
<!-- Native C++ API -->
<!-- - - - - - - - - - - - - - - -->
<!-- ============== =============================================================================================================== -->
<!-- Name           Details -->
<!-- ============== =============================================================================================================== -->
<!-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -->
<!-- ============== =============================================================================================================== -->
</div>
</div>
<div class="section" id="features-removed-from-xapian">
<h1><a class="toc-backref" href="#id34">Features removed from Xapian</a></h1>
<div class="section" id="id1">
<h2><a class="toc-backref" href="#id35">Native C++ API</a></h2>
<!-- Keep table width to <= 126 columns. -->
<table border="1" class="docutils">
<colgroup>
<col width="6%" />
<col width="28%" />
<col width="66%" />
</colgroup>
<thead valign="bottom">
<tr><th class="head">Removed</th>
<th class="head">Feature name</th>
<th class="head">Upgrade suggestion and comments</th>
</tr>
</thead>
<tbody valign="top">
<tr><td>1.0.0</td>
<td>QueryParser::set_stemming_options()</td>
<td><p class="first">Use <tt class="docutils literal">set_stemmer()</tt>, <tt class="docutils literal">set_stemming_strategy()</tt> and/or <tt class="docutils literal">set_stopper()</tt>
instead:</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">set_stemming_options(&quot;&quot;)</span></tt> becomes
<tt class="docutils literal"><span class="pre">set_stemming_strategy(Xapian::QueryParser::STEM_NONE)</span></tt></li>
<li><tt class="docutils literal"><span class="pre">set_stemming_options(&quot;none&quot;)</span></tt> becomes
<tt class="docutils literal"><span class="pre">set_stemming_strategy(Xapian::QueryParser::STEM_NONE)</span></tt></li>
<li><tt class="docutils literal">set_stemming_options(LANG)</tt> becomes
<tt class="docutils literal"><span class="pre">set_stemmer(Xapian::Stem(LANG)</span></tt> and
<tt class="docutils literal"><span class="pre">set_stemming_strategy(Xapian::QueryParser::STEM_SOME)</span></tt></li>
<li><tt class="docutils literal">set_stemming_options(LANG, false)</tt> becomes
<tt class="docutils literal"><span class="pre">set_stemmer(Xapian::Stem(LANG)</span></tt> and
<tt class="docutils literal"><span class="pre">set_stemming_strategy(Xapian::QueryParser::STEM_SOME)</span></tt></li>
<li><tt class="docutils literal">set_stemming_options(LANG, true)</tt> becomes
<tt class="docutils literal"><span class="pre">set_stemmer(Xapian::Stem(LANG)</span></tt> and
<tt class="docutils literal"><span class="pre">set_stemming_strategy(Xapian::QueryParser::STEM_ALL)</span></tt></li>
</ul>
<p class="last">If a third parameter is passed, <tt class="docutils literal">set_stopper(PARAM3)</tt> and treat the first two
parameters as above.</p>
</td>
</tr>
<tr><td>1.0.0</td>
<td>Enquire::set_sort_forward()</td>
<td><p class="first">Use <tt class="docutils literal"><span class="pre">Enquire::set_docid_order()</span></tt> instead:</p>
<blockquote class="last">
<ul class="simple">
<li><tt class="docutils literal">set_sort_forward(true)</tt> becomes <tt class="docutils literal">set_docid_order(ASCENDING)</tt></li>
<li><tt class="docutils literal">set_sort_forward(false)</tt> becomes <tt class="docutils literal">set_docid_order(DESCENDING)</tt></li>
</ul>
</blockquote>
</td>
</tr>
<tr><td>1.0.0</td>
<td>Enquire::set_sorting()</td>
<td><p class="first">Use <tt class="docutils literal"><span class="pre">Enquire::set_sort_by_relevance()</span></tt>, <tt class="docutils literal"><span class="pre">Enquire::set_sort_by_value()</span></tt>, or
<tt class="docutils literal"><span class="pre">Enquire::set_sort_by_value_then_relevance()</span></tt> instead.</p>
<blockquote class="last">
<ul class="simple">
<li><tt class="docutils literal">set_sorting(KEY, 1)</tt> becomes <tt class="docutils literal">set_sort_by_value(KEY)</tt></li>
<li><tt class="docutils literal">set_sorting(KEY, 1, false)</tt> becomes <tt class="docutils literal">set_sort_by_value(KEY)</tt></li>
<li><tt class="docutils literal">set_sorting(KEY, 1, true)</tt> becomes <tt class="docutils literal">set_sort_by_value_then_relevance(KEY)</tt></li>
<li><tt class="docutils literal">set_sorting(ANYTHING, 0)</tt> becomes <tt class="docutils literal">set_sort_by_relevance()</tt></li>
<li><tt class="docutils literal"><span class="pre">set_sorting(Xapian::BAD_VALUENO,</span> ANYTHING)</tt> becomes
<tt class="docutils literal">set_sort_by_relevance()</tt></li>
</ul>
</blockquote>
</td>
</tr>
<tr><td>1.0.0</td>
<td>Stem::stem_word(word)</td>
<td>Use <tt class="docutils literal"><span class="pre">Stem::operator()(word)</span></tt> instead.</td>
</tr>
<tr><td>1.0.0</td>
<td>Auto::open(path)</td>
<td>Use the <tt class="docutils literal">Database(path)</tt> constructor instead.</td>
</tr>
<tr><td>1.0.0</td>
<td>Auto::open(path, action)</td>
<td>Use the <tt class="docutils literal">WritableDatabase(path, action)</tt> constructor instead.</td>
</tr>
<tr><td>1.0.0</td>
<td>Query::is_empty()</td>
<td>Use <tt class="docutils literal"><span class="pre">Query::empty()</span></tt> instead.</td>
</tr>
<tr><td>1.0.0</td>
<td>Document::add_term_nopos()</td>
<td>Use <tt class="docutils literal"><span class="pre">Document::add_term()</span></tt> instead.</td>
</tr>
<tr><td>1.0.0</td>
<td>Enquire::set_bias()</td>
<td>Use <tt class="docutils literal">PostingSource</tt> instead (new in 1.2).</td>
</tr>
<tr><td>1.0.0</td>
<td>ExpandDecider::operator()</td>
<td>Return type is now <tt class="docutils literal">bool</tt> not <tt class="docutils literal">int</tt>.</td>
</tr>
<tr><td>1.0.0</td>
<td>MatchDecider::operator()</td>
<td>Return type is now <tt class="docutils literal">bool</tt> not <tt class="docutils literal">int</tt>.</td>
</tr>
<tr><td>1.0.0</td>
<td>Error::get_type()</td>
<td>Return type is now <tt class="docutils literal">const char *</tt> not <tt class="docutils literal"><span class="pre">std::string</span></tt>.  Most existing code
won't need changes, but if it does the simplest fix is to write
<tt class="docutils literal"><span class="pre">std::string(e.get_type())</span></tt> instead of <tt class="docutils literal">e.get_type()</tt>.</td>
</tr>
<tr><td>1.0.0</td>
<td>&lt;xapian/output.h&gt;</td>
<td>Use <tt class="docutils literal">cout &lt;&lt; <span class="pre">obj.get_description();</span></tt> instead of <tt class="docutils literal">cout &lt;&lt; obj;</tt></td>
</tr>
<tr><td>1.0.0</td>
<td>Several constructors marked
as explicit.</td>
<td>Explicitly create the object type required, for example use
<tt class="docutils literal"><span class="pre">Xapian::Enquire</span> <span class="pre">enq(Xapian::Database(path));</span></tt> instead of
<tt class="docutils literal"><span class="pre">Xapian::Enquire</span> enq(path);</tt></td>
</tr>
<tr><td>1.0.0</td>
<td>QueryParser::parse_query() throwing
<tt class="docutils literal">const char *</tt> exception.</td>
<td>Catch <tt class="docutils literal"><span class="pre">Xapian::QueryParserError</span></tt> instead of <tt class="docutils literal">const char *</tt>, and call
<tt class="docutils literal">get_msg()</tt> on the caught object.  If you need to build with either version,
catch both (you'll need to compile the part which catches <tt class="docutils literal">QueryParserError</tt>
conditionally, since this exception isn't present in the 0.9 release series).</td>
</tr>
<tr><td>1.1.0</td>
<td>xapian_version_string()</td>
<td>Use <tt class="docutils literal">version_string()</tt> instead.</td>
</tr>
<tr><td>1.1.0</td>
<td>xapian_major_version()</td>
<td>Use <tt class="docutils literal">major_version()</tt> instead.</td>
</tr>
<tr><td>1.1.0</td>
<td>xapian_minor_version()</td>
<td>Use <tt class="docutils literal">minor_version()</tt> instead.</td>
</tr>
<tr><td>1.1.0</td>
<td>xapian_revision()</td>
<td>Use <tt class="docutils literal">revision()</tt> instead.</td>
</tr>
<tr><td>1.1.0</td>
<td>Enquire::include_query_terms</td>
<td>Use <tt class="docutils literal"><span class="pre">Enquire::INCLUDE_QUERY_TERMS</span></tt> instead.</td>
</tr>
<tr><td>1.1.0</td>
<td>Enquire::use_exact_termfreq</td>
<td>Use <tt class="docutils literal"><span class="pre">Enquire::USE_EXACT_TERMFREQ</span></tt> instead.</td>
</tr>
<tr><td>1.1.0</td>
<td>Error::get_errno()</td>
<td>Use <tt class="docutils literal"><span class="pre">Error::get_error_string()</span></tt> instead.</td>
</tr>
<tr><td>1.1.0</td>
<td>Enquire::register_match_decider()</td>
<td>This method didn't do anything, so just remove calls to it!</td>
</tr>
<tr><td>1.1.0</td>
<td>Query::Query(Query::op, Query)</td>
<td>This constructor isn't useful for any currently implemented
<tt class="docutils literal"><span class="pre">Query::op</span></tt>.</td>
</tr>
<tr><td>1.1.0</td>
<td>The Quartz backend</td>
<td>Use the Chert backend instead.</td>
</tr>
<tr><td>1.1.0</td>
<td>Quartz::open()</td>
<td>Use <tt class="docutils literal"><span class="pre">Chert::open()</span></tt> instead.</td>
</tr>
<tr><td>1.1.0</td>
<td>quartzcheck</td>
<td>Use <tt class="docutils literal"><span class="pre">xapian-check</span></tt> instead.</td>
</tr>
<tr><td>1.1.0</td>
<td>quartzcompact</td>
<td>Use <tt class="docutils literal"><span class="pre">xapian-compact</span></tt> instead.</td>
</tr>
<tr><td>1.1.0</td>
<td>quartzdump</td>
<td>Use <tt class="docutils literal"><span class="pre">xapian-inspect</span></tt> instead.</td>
</tr>
<tr><td>1.1.0</td>
<td>configure --enable-debug</td>
<td>configure --enable-assertions</td>
</tr>
<tr><td>1.1.0</td>
<td>configure --enable-debug=full</td>
<td>configure --enable-assertions --enable-log</td>
</tr>
<tr><td>1.1.0</td>
<td>configure --enable-debug=partial</td>
<td>configure --enable-assertions=partial</td>
</tr>
<tr><td>1.1.0</td>
<td>configure --enable-debug=profile</td>
<td>configure --enable-log=profile</td>
</tr>
<tr><td>1.1.0</td>
<td>configure --enable-debug-verbose</td>
<td>configure --enable-log</td>
</tr>
<tr><td>1.1.0</td>
<td><tt class="docutils literal"><span class="pre">Database::positionlist_begin()</span></tt>
throwing <tt class="docutils literal">RangeError</tt> if the
term specified doesn't index the
document specified.</td>
<td>This check is quite expensive, and often you don't care.  If you
do it's easy to check - just open a <tt class="docutils literal">TermListIterator</tt> for the
document and use <tt class="docutils literal">skip_to()</tt> to check if the term is there.</td>
</tr>
<tr><td>1.1.0</td>
<td><tt class="docutils literal"><span class="pre">Database::positionlist_begin()</span></tt>
throwing <tt class="docutils literal">DocNotFoundError</tt> if
the document specified doesn't
exist.</td>
<td>This check is quite expensive, and often you don't care.  If you
do, it's easy to check - just call <tt class="docutils literal"><span class="pre">Database::get_document()</span></tt> with the
specified document ID.</td>
</tr>
<tr><td>1.1.5</td>
<td>delve -k</td>
<td>Accepted as an undocumented alias for -V since 0.9.10 for compatibility with 0.9.9
and earlier.  Just use -V instead.</td>
</tr>
<tr><td>1.3.0</td>
<td>The Flint backend</td>
<td>Use the Chert backend instead.</td>
</tr>
<tr><td>1.3.0</td>
<td>Flint::open()</td>
<td>Use <tt class="docutils literal"><span class="pre">Chert::open()</span></tt> instead.</td>
</tr>
<tr><td>1.3.0</td>
<td>xapian-chert-update</td>
<td>Install Xapian 1.2.x (where x &gt;= 5) to update chert databases from 1.1.3 and
earlier.</td>
</tr>
<tr><td>1.3.0</td>
<td>Default second parameter to
<tt class="docutils literal">Enquire</tt> sorting functions.</td>
<td><p class="first">The parameter name was <tt class="docutils literal">ascending</tt> and defaulted to <tt class="docutils literal">true</tt>.  However
ascending=false gave what you'd expect the default sort order to be (and probably
think of as ascending) while ascending=true gave the reverse (descending) order.
For sanity, we renamed the parameter to <tt class="docutils literal">reverse</tt> and deprecated the default
value.  In the more distant future, we'll probably add a default again, but of
<tt class="docutils literal">false</tt> instead.</p>
<p>The methods affected are:
<tt class="docutils literal"><span class="pre">Enquire::set_sort_by_value(Xapian::valueno</span> sort_key)</tt>
<tt class="docutils literal"><span class="pre">Enquire::set_sort_by_key(Xapian::Sorter</span> * sorter)</tt>
<tt class="docutils literal"><span class="pre">Enquire::set_sort_by_value_then_relevance(Xapian::valueno</span> sort_key)</tt>
<tt class="docutils literal"><span class="pre">Enquire::set_sort_by_key_then_relevance(Xapian::Sorter</span> * sorter)</tt>
<tt class="docutils literal"><span class="pre">Enquire::set_sort_by_relevance_then_value(Xapian::valueno</span> sort_key)</tt>
<tt class="docutils literal"><span class="pre">Enquire::set_sort_by_relevance_then_key(Xapian::Sorter</span> * sorter)</tt></p>
<p class="last">To update them, just add a second parameter with value <tt class="docutils literal">true</tt> to each of the
above calls.  For the methods which take a <tt class="docutils literal"><span class="pre">Xapian::Sorter</span></tt> object, you'll also
need to migrate to <tt class="docutils literal"><span class="pre">Xapian::KeyMaker</span></tt> (see below).</p>
</td>
</tr>
<tr><td>1.3.0</td>
<td><tt class="docutils literal">Sorter</tt> abstract base class.</td>
<td>Use <tt class="docutils literal">KeyMaker</tt> class instead, which has the same semantics, but has been renamed
to indicate that the keys produced may be used for purposes other than sorting (we
plan to allow collapsing on generated keys in the future).</td>
</tr>
<tr><td>1.3.0</td>
<td><tt class="docutils literal">MultiValueSorter</tt> class.</td>
<td><p class="first">Use <tt class="docutils literal">MultiValueKeyMaker</tt> class instead.  Note that <tt class="docutils literal"><span class="pre">MultiValueSorter::add()</span></tt>
becomes <tt class="docutils literal"><span class="pre">MultiValueKeyMaker::add_value()</span></tt>, but the sense of the direction flag
is reversed (to be consistent with <tt class="docutils literal"><span class="pre">Enquire::set_sort_by_value()</span></tt>), so:</p>
<pre class="literal-block">
MultiValueSorter sorter;
// Primary ordering is forwards on value 4.
sorter.add(4);
// Secondary ordering is reverse on value 5.
sorter.add(5, false);
</pre>
<p>becomes:</p>
<pre class="last literal-block">
MultiValueKeyMaker sorter;
// Primary ordering is forwards on value 4.
sorter.add_value(4);
// Secondary ordering is reverse on value 5.
sorter.add_value(5, true);
</pre>
</td>
</tr>
<tr><td>1.3.0</td>
<td><tt class="docutils literal">matchspy</tt> parameter to
<tt class="docutils literal"><span class="pre">Enquire::get_mset()</span></tt></td>
<td>Use the newer <tt class="docutils literal">MatchSpy</tt> class and <tt class="docutils literal"><span class="pre">Enquire::add_matchspy()</span></tt> method instead.</td>
</tr>
<tr><td>1.3.0</td>
<td><tt class="docutils literal"><span class="pre">Xapian::timeout</span></tt> typedef</td>
<td>Use <tt class="docutils literal">unsigned</tt> instead, which should also work with older Xapian releases.</td>
</tr>
<tr><td>1.3.0</td>
<td><tt class="docutils literal"><span class="pre">Xapian::percent</span></tt> typedef</td>
<td>Use <tt class="docutils literal">int</tt> instead, which should also work with older Xapian releases.</td>
</tr>
<tr><td>1.3.0</td>
<td><tt class="docutils literal"><span class="pre">Xapian::weight</span></tt> typedef</td>
<td>Use <tt class="docutils literal">double</tt> instead, which should also work with older Xapian releases.</td>
</tr>
<tr><td>1.3.0</td>
<td><tt class="docutils literal"><span class="pre">Xapian::Query::unserialise()</span></tt>
throws
<tt class="docutils literal"><span class="pre">Xapian::SerialisationError</span></tt> not
<tt class="docutils literal"><span class="pre">Xapian::InvalidArgumentError</span></tt>
for errors in serialised data</td>
<td>To be compatible with older and newer Xapian, you can catch both exceptions.</td>
</tr>
<tr><td>1.3.2</td>
<td>The Brass backend</td>
<td>Use the Glass backend instead.</td>
</tr>
<tr><td>1.3.2</td>
<td><tt class="docutils literal"><span class="pre">Xapian::Brass::open()</span></tt></td>
<td>Use the constructor with <tt class="docutils literal"><span class="pre">Xapian::DB_BACKEND_GLASS</span></tt> flag (new in 1.3.2) instead.</td>
</tr>
<tr><td>1.3.4</td>
<td>Copy constructors and assignment
operators for classes:
<tt class="docutils literal"><span class="pre">Xapian::ExpandDecider</span></tt>,
<tt class="docutils literal"><span class="pre">Xapian::FieldProcessor</span></tt> (new in
1.3.1), <tt class="docutils literal"><span class="pre">Xapian::KeyMaker</span></tt>,
<tt class="docutils literal"><span class="pre">Xapian::MatchDecider</span></tt>,
<tt class="docutils literal"><span class="pre">Xapian::StemImplementation</span></tt>,
<tt class="docutils literal"><span class="pre">Xapian::Stopper</span></tt> and
<tt class="docutils literal"><span class="pre">Xapian::ValueRangeProcessor</span></tt>.</td>
<td>We think it was a mistake that implicit copy constructors and assignment operators
were being provided for these functor classes - it's hard to use them correctly,
but easy to use them in ways which compile but don't work correctly, and we doubt
anyone is intentionally using them, so we've simply removed them.  For more
information, see <a class="reference external" href="https://trac.xapian.org/ticket/681">https://trac.xapian.org/ticket/681</a></td>
</tr>
<tr><td>1.3.5</td>
<td><tt class="docutils literal"><span class="pre">Xapian::DBCHECK_SHOW_BITMAP</span></tt></td>
<td>Use <tt class="docutils literal"><span class="pre">Xapian::DBCHECK_SHOW_FREELIST</span></tt> (added in 1.3.2) instead.
<tt class="docutils literal"><span class="pre">Xapian::DBCHECK_SHOW_BITMAP</span></tt> was added in 1.3.0, so has never been in a stable
release.</td>
</tr>
</tbody>
</table>
</div>
<div class="section" id="id2">
<h2><a class="toc-backref" href="#id36">Bindings</a></h2>
<!-- Keep table width to <= 126 columns. -->
<table border="1" class="docutils">
<colgroup>
<col width="6%" />
<col width="7%" />
<col width="23%" />
<col width="65%" />
</colgroup>
<thead valign="bottom">
<tr><th class="head">Removed</th>
<th class="head">Language</th>
<th class="head">Feature name</th>
<th class="head">Upgrade suggestion and comments</th>
</tr>
</thead>
<tbody valign="top">
<tr><td>1.0.0</td>
<td>SWIG
<a class="footnote-reference" href="#rswg" id="id3">[1]</a></td>
<td>Enquire::set_sort_forward()</td>
<td><p class="first">Use <tt class="docutils literal"><span class="pre">Enquire::set_docid_order()</span></tt> instead.</p>
<blockquote class="last">
<ul class="simple">
<li><tt class="docutils literal">set_sort_forward(true)</tt> becomes <tt class="docutils literal">set_docid_order(ASCENDING)</tt></li>
<li><tt class="docutils literal">set_sort_forward(false)</tt> becomes <tt class="docutils literal">set_docid_order(DESCENDING)</tt></li>
</ul>
</blockquote>
</td>
</tr>
<tr><td>1.0.0</td>
<td>SWIG
<a class="footnote-reference" href="#rswg" id="id4">[1]</a></td>
<td>Enquire::set_sorting()</td>
<td><p class="first">Use <tt class="docutils literal"><span class="pre">Enquire::set_sort_by_relevance()</span></tt>, <tt class="docutils literal"><span class="pre">Enquire::set_sort_by_value()</span></tt>
or <tt class="docutils literal"><span class="pre">Enquire::set_sort_by_value_then_relevance()</span></tt> instead.</p>
<blockquote class="last">
<ul class="simple">
<li><tt class="docutils literal">set_sorting(KEY, 1)</tt> becomes <tt class="docutils literal">set_sort_by_value(KEY)</tt></li>
<li><tt class="docutils literal">set_sorting(KEY, 1, false) becomes ``set_sort_by_value(KEY)</tt></li>
<li><tt class="docutils literal">set_sorting(KEY, 1, true)</tt> becomes
<tt class="docutils literal">set_sort_by_value_then_relevance(KEY)</tt></li>
<li><tt class="docutils literal">set_sorting(ANYTHING, 0) becomes set_sort_by_relevance()</tt></li>
<li><tt class="docutils literal"><span class="pre">set_sorting(Xapian::BAD_VALUENO,</span> ANYTHING)</tt> becomes
<tt class="docutils literal">set_sort_by_relevance()</tt></li>
</ul>
</blockquote>
</td>
</tr>
<tr><td>1.0.0</td>
<td>SWIG
<a class="footnote-reference" href="#rswg" id="id5">[1]</a></td>
<td>Auto::open(path)</td>
<td>Use the <tt class="docutils literal">Database(path)</tt> constructor instead.</td>
</tr>
<tr><td>1.0.0</td>
<td>SWIG
<a class="footnote-reference" href="#rswg" id="id6">[1]</a></td>
<td>Auto::open(path, action)</td>
<td>Use the <tt class="docutils literal">WritableDatabase(path, action)</tt> constructor instead.</td>
</tr>
<tr><td>1.0.0</td>
<td>SWIG
<a class="footnote-reference" href="#rsw3" id="id7">[3]</a></td>
<td>MSet::is_empty()</td>
<td>Use <tt class="docutils literal"><span class="pre">MSet::empty()</span></tt> instead.</td>
</tr>
<tr><td>1.0.0</td>
<td>SWIG
<a class="footnote-reference" href="#rsw3" id="id8">[3]</a></td>
<td>ESet::is_empty()</td>
<td>Use <tt class="docutils literal"><span class="pre">ESet::empty()</span></tt> instead.</td>
</tr>
<tr><td>1.0.0</td>
<td>SWIG
<a class="footnote-reference" href="#rsw3" id="id9">[3]</a></td>
<td>RSet::is_empty()</td>
<td>Use <tt class="docutils literal"><span class="pre">RSet::empty()</span></tt> instead.</td>
</tr>
<tr><td>1.0.0</td>
<td>SWIG
<a class="footnote-reference" href="#rsw3" id="id10">[3]</a></td>
<td>Query::is_empty()</td>
<td>Use <tt class="docutils literal"><span class="pre">Query::empty()</span></tt> instead.</td>
</tr>
<tr><td>1.0.0</td>
<td>SWIG
<a class="footnote-reference" href="#rswg" id="id11">[1]</a></td>
<td>Document::add_term_nopos()</td>
<td>Use <tt class="docutils literal"><span class="pre">Document::add_term()</span></tt> instead.</td>
</tr>
<tr><td>1.0.0</td>
<td>CSharp</td>
<td>ExpandDecider::Apply()</td>
<td>Return type is now <tt class="docutils literal">bool</tt> instead of <tt class="docutils literal">int</tt>.</td>
</tr>
<tr><td>1.0.0</td>
<td>CSharp</td>
<td>MatchDecider::Apply()</td>
<td>Return type is now <tt class="docutils literal">bool</tt> instead of <tt class="docutils literal">int</tt>.</td>
</tr>
<tr><td>1.0.0</td>
<td>SWIG
<a class="footnote-reference" href="#rswg" id="id12">[1]</a></td>
<td>Stem::stem_word(word)</td>
<td>Use <tt class="docutils literal"><span class="pre">Stem::operator()(word)</span></tt> instead. <a class="footnote-reference" href="#callable" id="id13">[4]</a></td>
</tr>
<tr><td>1.1.0</td>
<td>SWIG
<a class="footnote-reference" href="#rswg" id="id14">[1]</a></td>
<td>xapian_version_string()</td>
<td>Use <tt class="docutils literal">version_string()</tt> instead.</td>
</tr>
<tr><td>1.1.0</td>
<td>SWIG
<a class="footnote-reference" href="#rswg" id="id15">[1]</a></td>
<td>xapian_major_version()</td>
<td>Use <tt class="docutils literal">major_version()</tt> instead.</td>
</tr>
<tr><td>1.1.0</td>
<td>SWIG
<a class="footnote-reference" href="#rswg" id="id16">[1]</a></td>
<td>xapian_minor_version()</td>
<td>Use <tt class="docutils literal">minor_version()</tt> instead.</td>
</tr>
<tr><td>1.1.0</td>
<td>SWIG
<a class="footnote-reference" href="#rswg" id="id17">[1]</a></td>
<td>xapian_revision()</td>
<td>Use <tt class="docutils literal">revision()</tt> instead.</td>
</tr>
<tr><td>1.1.0</td>
<td>SWIG
<a class="footnote-reference" href="#rswg" id="id18">[1]</a></td>
<td>ESetIterator::get_termname()</td>
<td>Use <tt class="docutils literal"><span class="pre">ESetIterator::get_term()</span></tt> instead.  This change is intended to
bring the ESet iterators in line with other term iterators, which all
support <tt class="docutils literal">get_term()</tt> instead of <tt class="docutils literal">get_termname()</tt>.</td>
</tr>
<tr><td>1.1.0</td>
<td>Python</td>
<td>get_description()</td>
<td>All <tt class="docutils literal">get_description()</tt> methods have been renamed to <tt class="docutils literal">__str__()</tt>,
so the normal python <tt class="docutils literal">str()</tt> function can be used.</td>
</tr>
<tr><td>1.1.0</td>
<td>Python</td>
<td>MSetItem.get_*()</td>
<td>All these methods are deprecated, in favour of properties.
To convert, just change <tt class="docutils literal">msetitem.get_FOO()</tt> to <tt class="docutils literal">msetitem.FOO</tt></td>
</tr>
<tr><td>1.1.0</td>
<td>Python</td>
<td>Enquire.get_matching_terms</td>
<td>Replaced by <tt class="docutils literal">Enquire.matching_terms</tt>, for consistency with
rest of Python API.  Note: an <tt class="docutils literal">Enquire.get_matching_terms</tt> method existed in
releases up-to and including 1.2.4, but this was actually an old implementation
which only accepted a MSetIterator as a parameter, and would have failed with
code written expecting the version in 1.0.0.  It was fully removed after
release 1.2.4.</td>
</tr>
<tr><td>1.1.0</td>
<td>SWIG
<a class="footnote-reference" href="#rswg" id="id19">[1]</a></td>
<td>Error::get_errno()</td>
<td>Use <tt class="docutils literal"><span class="pre">Error::get_error_string()</span></tt> instead.</td>
</tr>
<tr><td>1.1.0</td>
<td>SWIG
<a class="footnote-reference" href="#rsw2" id="id20">[2]</a></td>
<td>MSet::get_document_id()</td>
<td>Use <tt class="docutils literal"><span class="pre">MSet::get_docid()</span></tt> instead.</td>
</tr>
<tr><td>1.2.0</td>
<td>Python</td>
<td>mset[i][xapian.MSET_DID] etc</td>
<td>This was inadvertently removed in 1.2.0, but not noticed until 1.2.5, by which
point it no longer seemed worthwhile to reinstate it.  Please use the property
API instead, e.g. <tt class="docutils literal"><span class="pre">mset[i].docid</span></tt>, <tt class="docutils literal"><span class="pre">mset[i].weight</span></tt>, etc.</td>
</tr>
<tr><td>1.2.5</td>
<td>Python</td>
<td>if idx in mset</td>
<td>This was nominally implemented, but never actually worked.  Since nobody seems
to have noticed in 3.5 years, we just removed it.  If you have uses (which were
presumably never called), you can replace them with:
<tt class="docutils literal">if idx &gt;= 0 and idx &lt; len(mset)</tt></td>
</tr>
<tr><td>1.3.0</td>
<td>Python</td>
<td>Non-pythonic iterators</td>
<td>Use the pythonic iterators instead.</td>
</tr>
<tr><td>1.3.0</td>
<td>Python</td>
<td>Stem_get_available_languages</td>
<td>Use Stem.get_available_languages instead (static method instead of function)</td>
</tr>
</tbody>
</table>
<table class="docutils footnote" frame="void" id="rswg" rules="none">
<colgroup><col class="label" /><col /></colgroup>
<tbody valign="top">
<tr><td class="label">[1]</td><td><em>(<a class="fn-backref" href="#id3">1</a>, <a class="fn-backref" href="#id4">2</a>, <a class="fn-backref" href="#id5">3</a>, <a class="fn-backref" href="#id6">4</a>, <a class="fn-backref" href="#id11">5</a>, <a class="fn-backref" href="#id12">6</a>, <a class="fn-backref" href="#id14">7</a>, <a class="fn-backref" href="#id15">8</a>, <a class="fn-backref" href="#id16">9</a>, <a class="fn-backref" href="#id17">10</a>, <a class="fn-backref" href="#id18">11</a>, <a class="fn-backref" href="#id19">12</a>)</em> This affects all SWIG generated bindings (currently: Python, PHP, Ruby, Tcl8 and CSharp)</td></tr>
</tbody>
</table>
<table class="docutils footnote" frame="void" id="rsw2" rules="none">
<colgroup><col class="label" /><col /></colgroup>
<tbody valign="top">
<tr><td class="label"><a class="fn-backref" href="#id20">[2]</a></td><td>This affects all SWIG-generated bindings except those for Ruby, support for which was added after the function was deprecated in Xapian-core.</td></tr>
</tbody>
</table>
<table class="docutils footnote" frame="void" id="rsw3" rules="none">
<colgroup><col class="label" /><col /></colgroup>
<tbody valign="top">
<tr><td class="label">[3]</td><td><em>(<a class="fn-backref" href="#id7">1</a>, <a class="fn-backref" href="#id8">2</a>, <a class="fn-backref" href="#id9">3</a>, <a class="fn-backref" href="#id10">4</a>)</em> This affects all SWIG generated bindings except those for Ruby, which was added after the function was deprecated in Xapian-core, and PHP, where empty is a reserved word (and therefore, the method remains &quot;is_empty&quot;).</td></tr>
</tbody>
</table>
<table class="docutils footnote" frame="void" id="callable" rules="none">
<colgroup><col class="label" /><col /></colgroup>
<tbody valign="top">
<tr><td class="label"><a class="fn-backref" href="#id13">[4]</a></td><td>Python handles this like C++.  Ruby renames it to 'call' (idiomatic Ruby).  PHP renames it to 'apply'.  CSharp to 'Apply' (delegates could probably be used to provide C++-like functor syntax, but that's effort and it seems debatable if it would actually be more natural to a C# programmer).  Tcl8 renames it to 'apply' - need to ask a Tcl type if that's the best solution.</td></tr>
</tbody>
</table>
</div>
<div class="section" id="id21">
<h2><a class="toc-backref" href="#id37">Omega</a></h2>
<!-- Keep table width to <= 126 columns. -->
<table border="1" class="docutils">
<colgroup>
<col width="6%" />
<col width="28%" />
<col width="66%" />
</colgroup>
<thead valign="bottom">
<tr><th class="head">Removed</th>
<th class="head">Feature name</th>
<th class="head">Upgrade suggestion and comments</th>
</tr>
</thead>
<tbody valign="top">
<tr><td>1.0.0</td>
<td>$freqs</td>
<td>Use <tt class="docutils literal"><span class="pre">$map{$queryterms,$_:&amp;nbsp;$nice{$freq{$_}}}</span></tt> instead.</td>
</tr>
<tr><td>1.0.0</td>
<td>scriptindex -u</td>
<td><tt class="docutils literal"><span class="pre">-u</span></tt> was ignored for compatibility with 0.7.5 and earlier, so just remove it.</td>
</tr>
<tr><td>1.0.0</td>
<td>scriptindex -q</td>
<td><tt class="docutils literal"><span class="pre">-q</span></tt> was ignored for compatibility with 0.6.1 and earlier, so just remove it.</td>
</tr>
<tr><td>1.1.0</td>
<td>scriptindex index=nopos</td>
<td>Use <tt class="docutils literal">indexnopos</tt> instead.</td>
</tr>
<tr><td>1.3.0</td>
<td><tt class="docutils literal">OLDP</tt> CGI parameter</td>
<td>Use <tt class="docutils literal">xP</tt> CGI parameter instead (direct replacement), which has been supported
since at least 0.5.0.</td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
</body>
</html>