You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucenenet.apache.org by "Digy (JIRA)" <ji...@apache.org> on 2008/06/29 13:51:45 UTC
[jira] Created: (LUCENENET-121) StopFilter tries to access the
i'th item of a hashtable as item[i] where i is not a key.
StopFilter tries to access the i'th item of a hashtable as item[i] where i is not a key.
-----------------------------------------------------------------------------------------
Key: LUCENENET-121
URL: https://issues.apache.org/jira/browse/LUCENENET-121
Project: Lucene.Net
Issue Type: Bug
Environment: Lucene.Net 2.3.1
Reporter: Digy
Attachments: StopFilter v1.patch
Constructor of StopFilter tries to access the i'th item of a hashtable as item[i] where i is not a key.
{code}
public StopFilter(TokenStream input, System.Collections.Hashtable stopWords, bool ignoreCase) : base(input)
{
if (stopWords is CharArraySet)
{
this.stopWords = (CharArraySet) stopWords;
}
else
{
this.stopWords = new CharArraySet(stopWords.Count, ignoreCase);
for (int i = 0; i < stopWords.Count; i++)
{
this.stopWords.Add(stopWords[i]); // <----- i is not a "key" it is index.
}
}
}
{code}
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Unsubscribe
Posted by Mohamed El-Zahaby <za...@hotmail.com>.
Unsubscribe
_________________________________________________________________
News, entertainment and everything you care about at Live.com. Get it now!
http://www.live.com/getstarted.aspx
[jira] Unsubscribe
Posted by Ed Jones <Ed...@warc.com>.
Unsubscribe
-----Original Message-----
From: Digy (JIRA) [mailto:jira@apache.org]
Sent: 16 July 2008 15:23
To: lucene-net-dev@incubator.apache.org
Subject: [jira] Commented: (LUCENENET-121) StopFilter tries to access the i'th item of a hashtable as item[i] where i is not a key.
[ https://issues.apache.org/jira/browse/LUCENENET-121?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12613967#action_12613967 ]
Digy commented on LUCENENET-121:
--------------------------------
With the patch Analysis.TestStopAnalyzer solved.
DIGY
> StopFilter tries to access the i'th item of a hashtable as item[i] where i is not a key.
> -----------------------------------------------------------------------------------------
>
> Key: LUCENENET-121
> URL: https://issues.apache.org/jira/browse/LUCENENET-121
> Project: Lucene.Net
> Issue Type: Bug
> Environment: Lucene.Net 2.3.1
> Reporter: Digy
> Attachments: Another patch.rar, StopFilter v1.patch, StopFilter v1.patch
>
>
> Constructor of StopFilter tries to access the i'th item of a hashtable as item[i] where i is not a key.
> {code}
> public StopFilter(TokenStream input, System.Collections.Hashtable stopWords, bool ignoreCase) : base(input)
> {
> if (stopWords is CharArraySet)
> {
> this.stopWords = (CharArraySet) stopWords;
> }
> else
> {
> this.stopWords = new CharArraySet(stopWords.Count, ignoreCase);
> for (int i = 0; i < stopWords.Count; i++)
> {
> this.stopWords.Add(stopWords[i]); // <----- i is not a "key" it is index.
> }
> }
> }
> {code}
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (LUCENENET-121) StopFilter tries to access the
i'th item of a hashtable as item[i] where i is not a key.
Posted by "Digy (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENENET-121?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12609103#action_12609103 ]
Digy commented on LUCENENET-121:
--------------------------------
Current stopword usage is like this:
System.Collections.HashTable stopWordsSet = new System.Collections.Hashtable();
stopWordsSet.Add("some","some");
StopAnalyzer newStop = new StopAnalyzer(stopWordsSet);
but the "key" of Hashtable is not used anywhere and causes a dublicate typing of stop words(also more memory).
A more natural usage would be:
System.Collections.ArrayList stopWordsSet = new System.Collections.ArrayList();
stopWordsSet.Add("some");
StopAnalyzer newStop = new StopAnalyzer(stopWordsSet);
I will attach another patch for this.
DIGY
> StopFilter tries to access the i'th item of a hashtable as item[i] where i is not a key.
> -----------------------------------------------------------------------------------------
>
> Key: LUCENENET-121
> URL: https://issues.apache.org/jira/browse/LUCENENET-121
> Project: Lucene.Net
> Issue Type: Bug
> Environment: Lucene.Net 2.3.1
> Reporter: Digy
> Attachments: StopFilter v1.patch
>
>
> Constructor of StopFilter tries to access the i'th item of a hashtable as item[i] where i is not a key.
> {code}
> public StopFilter(TokenStream input, System.Collections.Hashtable stopWords, bool ignoreCase) : base(input)
> {
> if (stopWords is CharArraySet)
> {
> this.stopWords = (CharArraySet) stopWords;
> }
> else
> {
> this.stopWords = new CharArraySet(stopWords.Count, ignoreCase);
> for (int i = 0; i < stopWords.Count; i++)
> {
> this.stopWords.Add(stopWords[i]); // <----- i is not a "key" it is index.
> }
> }
> }
> {code}
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (LUCENENET-121) StopFilter tries to access the
i'th item of a hashtable as item[i] where i is not a key.
Posted by "Digy (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENENET-121?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Digy updated LUCENENET-121:
---------------------------
Attachment: Another patch.rar
> StopFilter tries to access the i'th item of a hashtable as item[i] where i is not a key.
> -----------------------------------------------------------------------------------------
>
> Key: LUCENENET-121
> URL: https://issues.apache.org/jira/browse/LUCENENET-121
> Project: Lucene.Net
> Issue Type: Bug
> Environment: Lucene.Net 2.3.1
> Reporter: Digy
> Attachments: Another patch.rar, StopFilter v1.patch
>
>
> Constructor of StopFilter tries to access the i'th item of a hashtable as item[i] where i is not a key.
> {code}
> public StopFilter(TokenStream input, System.Collections.Hashtable stopWords, bool ignoreCase) : base(input)
> {
> if (stopWords is CharArraySet)
> {
> this.stopWords = (CharArraySet) stopWords;
> }
> else
> {
> this.stopWords = new CharArraySet(stopWords.Count, ignoreCase);
> for (int i = 0; i < stopWords.Count; i++)
> {
> this.stopWords.Add(stopWords[i]); // <----- i is not a "key" it is index.
> }
> }
> }
> {code}
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (LUCENENET-121) StopFilter tries to access the
i'th item of a hashtable as item[i] where i is not a key.
Posted by "Digy (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENENET-121?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Digy updated LUCENENET-121:
---------------------------
Attachment: StopFilter v1.patch
> StopFilter tries to access the i'th item of a hashtable as item[i] where i is not a key.
> -----------------------------------------------------------------------------------------
>
> Key: LUCENENET-121
> URL: https://issues.apache.org/jira/browse/LUCENENET-121
> Project: Lucene.Net
> Issue Type: Bug
> Environment: Lucene.Net 2.3.1
> Reporter: Digy
> Attachments: Another patch.rar, StopFilter v1.patch, StopFilter v1.patch
>
>
> Constructor of StopFilter tries to access the i'th item of a hashtable as item[i] where i is not a key.
> {code}
> public StopFilter(TokenStream input, System.Collections.Hashtable stopWords, bool ignoreCase) : base(input)
> {
> if (stopWords is CharArraySet)
> {
> this.stopWords = (CharArraySet) stopWords;
> }
> else
> {
> this.stopWords = new CharArraySet(stopWords.Count, ignoreCase);
> for (int i = 0; i < stopWords.Count; i++)
> {
> this.stopWords.Add(stopWords[i]); // <----- i is not a "key" it is index.
> }
> }
> }
> {code}
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (LUCENENET-121) StopFilter tries to access the
i'th item of a hashtable as item[i] where i is not a key.
Posted by "Digy (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENENET-121?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12613961#action_12613961 ]
Digy commented on LUCENENET-121:
--------------------------------
Bug still exists in Lucene.Net 2.3.1 build 001 "beta" .
I will send another patch.
DIGY
> StopFilter tries to access the i'th item of a hashtable as item[i] where i is not a key.
> -----------------------------------------------------------------------------------------
>
> Key: LUCENENET-121
> URL: https://issues.apache.org/jira/browse/LUCENENET-121
> Project: Lucene.Net
> Issue Type: Bug
> Environment: Lucene.Net 2.3.1
> Reporter: Digy
> Attachments: Another patch.rar, StopFilter v1.patch, StopFilter v1.patch
>
>
> Constructor of StopFilter tries to access the i'th item of a hashtable as item[i] where i is not a key.
> {code}
> public StopFilter(TokenStream input, System.Collections.Hashtable stopWords, bool ignoreCase) : base(input)
> {
> if (stopWords is CharArraySet)
> {
> this.stopWords = (CharArraySet) stopWords;
> }
> else
> {
> this.stopWords = new CharArraySet(stopWords.Count, ignoreCase);
> for (int i = 0; i < stopWords.Count; i++)
> {
> this.stopWords.Add(stopWords[i]); // <----- i is not a "key" it is index.
> }
> }
> }
> {code}
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (LUCENENET-121) StopFilter tries to access the
i'th item of a hashtable as item[i] where i is not a key.
Posted by "Digy (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENENET-121?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12613967#action_12613967 ]
Digy commented on LUCENENET-121:
--------------------------------
With the patch Analysis.TestStopAnalyzer solved.
DIGY
> StopFilter tries to access the i'th item of a hashtable as item[i] where i is not a key.
> -----------------------------------------------------------------------------------------
>
> Key: LUCENENET-121
> URL: https://issues.apache.org/jira/browse/LUCENENET-121
> Project: Lucene.Net
> Issue Type: Bug
> Environment: Lucene.Net 2.3.1
> Reporter: Digy
> Attachments: Another patch.rar, StopFilter v1.patch, StopFilter v1.patch
>
>
> Constructor of StopFilter tries to access the i'th item of a hashtable as item[i] where i is not a key.
> {code}
> public StopFilter(TokenStream input, System.Collections.Hashtable stopWords, bool ignoreCase) : base(input)
> {
> if (stopWords is CharArraySet)
> {
> this.stopWords = (CharArraySet) stopWords;
> }
> else
> {
> this.stopWords = new CharArraySet(stopWords.Count, ignoreCase);
> for (int i = 0; i < stopWords.Count; i++)
> {
> this.stopWords.Add(stopWords[i]); // <----- i is not a "key" it is index.
> }
> }
> }
> {code}
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Resolved: (LUCENENET-121) StopFilter tries to access the
i'th item of a hashtable as item[i] where i is not a key.
Posted by "George Aroush (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENENET-121?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
George Aroush resolved LUCENENET-121.
-------------------------------------
Resolution: Fixed
Assignee: George Aroush
Applied patch "StopFilter v1.patch" of 16Jul08.
> StopFilter tries to access the i'th item of a hashtable as item[i] where i is not a key.
> -----------------------------------------------------------------------------------------
>
> Key: LUCENENET-121
> URL: https://issues.apache.org/jira/browse/LUCENENET-121
> Project: Lucene.Net
> Issue Type: Bug
> Environment: Lucene.Net 2.3.1
> Reporter: Digy
> Assignee: George Aroush
> Attachments: Another patch.rar, StopFilter v1.patch, StopFilter v1.patch
>
>
> Constructor of StopFilter tries to access the i'th item of a hashtable as item[i] where i is not a key.
> {code}
> public StopFilter(TokenStream input, System.Collections.Hashtable stopWords, bool ignoreCase) : base(input)
> {
> if (stopWords is CharArraySet)
> {
> this.stopWords = (CharArraySet) stopWords;
> }
> else
> {
> this.stopWords = new CharArraySet(stopWords.Count, ignoreCase);
> for (int i = 0; i < stopWords.Count; i++)
> {
> this.stopWords.Add(stopWords[i]); // <----- i is not a "key" it is index.
> }
> }
> }
> {code}
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Closed: (LUCENENET-121) StopFilter tries to access the i'th
item of a hashtable as item[i] where i is not a key.
Posted by "George Aroush (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENENET-121?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
George Aroush closed LUCENENET-121.
-----------------------------------
> StopFilter tries to access the i'th item of a hashtable as item[i] where i is not a key.
> -----------------------------------------------------------------------------------------
>
> Key: LUCENENET-121
> URL: https://issues.apache.org/jira/browse/LUCENENET-121
> Project: Lucene.Net
> Issue Type: Bug
> Environment: Lucene.Net 2.3.1
> Reporter: Digy
> Assignee: George Aroush
> Attachments: Another patch.rar, StopFilter v1.patch, StopFilter v1.patch
>
>
> Constructor of StopFilter tries to access the i'th item of a hashtable as item[i] where i is not a key.
> {code}
> public StopFilter(TokenStream input, System.Collections.Hashtable stopWords, bool ignoreCase) : base(input)
> {
> if (stopWords is CharArraySet)
> {
> this.stopWords = (CharArraySet) stopWords;
> }
> else
> {
> this.stopWords = new CharArraySet(stopWords.Count, ignoreCase);
> for (int i = 0; i < stopWords.Count; i++)
> {
> this.stopWords.Add(stopWords[i]); // <----- i is not a "key" it is index.
> }
> }
> }
> {code}
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (LUCENENET-121) StopFilter tries to access the
i'th item of a hashtable as item[i] where i is not a key.
Posted by "Digy (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENENET-121?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Digy updated LUCENENET-121:
---------------------------
Attachment: StopFilter v1.patch
> StopFilter tries to access the i'th item of a hashtable as item[i] where i is not a key.
> -----------------------------------------------------------------------------------------
>
> Key: LUCENENET-121
> URL: https://issues.apache.org/jira/browse/LUCENENET-121
> Project: Lucene.Net
> Issue Type: Bug
> Environment: Lucene.Net 2.3.1
> Reporter: Digy
> Attachments: StopFilter v1.patch
>
>
> Constructor of StopFilter tries to access the i'th item of a hashtable as item[i] where i is not a key.
> {code}
> public StopFilter(TokenStream input, System.Collections.Hashtable stopWords, bool ignoreCase) : base(input)
> {
> if (stopWords is CharArraySet)
> {
> this.stopWords = (CharArraySet) stopWords;
> }
> else
> {
> this.stopWords = new CharArraySet(stopWords.Count, ignoreCase);
> for (int i = 0; i < stopWords.Count; i++)
> {
> this.stopWords.Add(stopWords[i]); // <----- i is not a "key" it is index.
> }
> }
> }
> {code}
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.