cvsimport
[beagle.git] / beagled / Lucene.Net / upstream-changes / 22_null_clone_overrides.patch
blob92ddd254ea4f57d46795ad58b21521345a15bb6e
1 From: Joe Shaw <joeshaw@novell.com>
3 Lucene.Net 1.9.1 contains overrides for most of the Query classes
4 which overrides the underlying Clone() method (which does a
5 MemberwiseClone()) with implementations that just return null.
6 LuceneCommon depends pretty heavily on the Clone() method, so null
7 return values break things badly. This patch has been sent upstream
8 (2 Oct 2006), hopefully it will go away when we pull a new Lucene.Net
9 version.
11 Index: Search/MatchAllDocsQuery.cs
12 ===================================================================
13 RCS file: /cvs/gnome/beagle/beagled/Lucene.Net/Search/MatchAllDocsQuery.cs,v
14 retrieving revision 1.2
15 diff -u -p -u -r1.2 MatchAllDocsQuery.cs
16 --- Search/MatchAllDocsQuery.cs 2 Oct 2006 17:09:05 -0000 1.2
17 +++ Search/MatchAllDocsQuery.cs 2 Oct 2006 18:14:32 -0000
18 @@ -193,11 +193,5 @@ namespace Lucene.Net.Search
20 return BitConverter.ToInt32(BitConverter.GetBytes(GetBoost()), 0);
23 - // {{Aroush-1.9}} Do we need this?!
24 - override public System.Object Clone()
25 - {
26 - return null;
27 - }
30 Index: Search/MultiPhraseQuery.cs
31 ===================================================================
32 RCS file: /cvs/gnome/beagle/beagled/Lucene.Net/Search/MultiPhraseQuery.cs,v
33 retrieving revision 1.2
34 diff -u -p -u -r1.2 MultiPhraseQuery.cs
35 --- Search/MultiPhraseQuery.cs 2 Oct 2006 17:09:05 -0000 1.2
36 +++ Search/MultiPhraseQuery.cs 2 Oct 2006 18:14:32 -0000
37 @@ -337,11 +337,5 @@ namespace Lucene.Net.Search
39 return buffer.ToString();
42 - // {{Aroush-1.9}} Do we need this?!
43 - override public System.Object Clone()
44 - {
45 - return null;
46 - }
49 Index: Search/PhrasePrefixQuery.cs
50 ===================================================================
51 RCS file: /cvs/gnome/beagle/beagled/Lucene.Net/Search/PhrasePrefixQuery.cs,v
52 retrieving revision 1.4
53 diff -u -p -u -r1.4 PhrasePrefixQuery.cs
54 --- Search/PhrasePrefixQuery.cs 2 Oct 2006 17:09:06 -0000 1.4
55 +++ Search/PhrasePrefixQuery.cs 2 Oct 2006 18:14:32 -0000
56 @@ -312,10 +312,5 @@ namespace Lucene.Net.Search
58 return buffer.ToString();
60 - // {{Aroush-1.9}} Do we need this?!
61 - override public System.Object Clone()
62 - {
63 - return null;
64 - }
67 Index: Search/PhraseQuery.cs
68 ===================================================================
69 RCS file: /cvs/gnome/beagle/beagled/Lucene.Net/Search/PhraseQuery.cs,v
70 retrieving revision 1.5
71 diff -u -p -u -r1.5 PhraseQuery.cs
72 --- Search/PhraseQuery.cs 2 Oct 2006 17:09:06 -0000 1.5
73 +++ Search/PhraseQuery.cs 2 Oct 2006 18:14:32 -0000
74 @@ -336,10 +336,5 @@ namespace Lucene.Net.Search
76 return BitConverter.ToInt32(BitConverter.GetBytes(GetBoost()), 0) ^ slop ^ terms.GetHashCode() ^ positions.GetHashCode();
78 - // {{Aroush-1.9}} Do we need this?!
79 - override public System.Object Clone()
80 - {
81 - return null;
82 - }
85 Index: Search/PrefixQuery.cs
86 ===================================================================
87 RCS file: /cvs/gnome/beagle/beagled/Lucene.Net/Search/PrefixQuery.cs,v
88 retrieving revision 1.4
89 diff -u -p -u -r1.4 PrefixQuery.cs
90 --- Search/PrefixQuery.cs 2 Oct 2006 17:09:06 -0000 1.4
91 +++ Search/PrefixQuery.cs 2 Oct 2006 18:14:32 -0000
92 @@ -104,10 +104,5 @@ namespace Lucene.Net.Search
94 return BitConverter.ToInt32(BitConverter.GetBytes(GetBoost()), 0) ^ prefix.GetHashCode();
96 - // {{Aroush-1.9}} Do we need this?!
97 - override public System.Object Clone()
98 - {
99 - return null;
103 Index: Search/RangeQuery.cs
104 ===================================================================
105 RCS file: /cvs/gnome/beagle/beagled/Lucene.Net/Search/RangeQuery.cs,v
106 retrieving revision 1.4
107 diff -u -p -u -r1.4 RangeQuery.cs
108 --- Search/RangeQuery.cs 2 Oct 2006 17:09:06 -0000 1.4
109 +++ Search/RangeQuery.cs 2 Oct 2006 18:14:32 -0000
110 @@ -187,10 +187,5 @@ namespace Lucene.Net.Search
112 return BitConverter.ToInt32(BitConverter.GetBytes(GetBoost()), 0) ^ (lowerTerm != null ? lowerTerm.GetHashCode():0) ^ (upperTerm != null?upperTerm.GetHashCode() : 0) ^ (this.inclusive ? 1 : 0);
114 - // {{Aroush-1.9}} Do we need this?!
115 - override public System.Object Clone()
117 - return null;
121 Index: Search/TermQuery.cs
122 ===================================================================
123 RCS file: /cvs/gnome/beagle/beagled/Lucene.Net/Search/TermQuery.cs,v
124 retrieving revision 1.4
125 diff -u -p -u -r1.4 TermQuery.cs
126 --- Search/TermQuery.cs 2 Oct 2006 17:09:07 -0000 1.4
127 +++ Search/TermQuery.cs 2 Oct 2006 18:14:32 -0000
128 @@ -202,10 +202,5 @@ namespace Lucene.Net.Search
130 return BitConverter.ToInt32(BitConverter.GetBytes(GetBoost()), 0) ^ term.GetHashCode();
132 - // {{Aroush-1.9}} Do we need this?!
133 - public override System.Object Clone()
135 - return null;