You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by "Karl Wettin (JIRA)" <ji...@apache.org> on 2007/11/01 20:59:50 UTC
[jira] Created: (LUCENE-1042) discrepancy in
getTermFreqVector-methods
discrepancy in getTermFreqVector-methods
-----------------------------------------
Key: LUCENE-1042
URL: https://issues.apache.org/jira/browse/LUCENE-1042
Project: Lucene - Java
Issue Type: Bug
Components: Term Vectors
Affects Versions: 2.3
Reporter: Karl Wettin
getTermFreqVector(int, TermVectorMapper) never calls the mapper if there is no term vector, consitent with all the other getTermFreqVector methods that returns null.
getTermFreqVector(int, String, TermVectorMapper) throws an IOException when a field does not contain the term vector.
My suggestion:
{code}
Index: src/java/org/apache/lucene/index/SegmentReader.java
===================================================================
--- src/java/org/apache/lucene/index/SegmentReader.java (revision 590149)
+++ src/java/org/apache/lucene/index/SegmentReader.java (working copy)
@@ -648,7 +648,7 @@
ensureOpen();
FieldInfo fi = fieldInfos.fieldInfo(field);
if (fi == null || !fi.storeTermVector || termVectorsReaderOrig == null)
- throw new IOException("field does not contain term vectors");
+ return;
{code}
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: java-dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-dev-help@lucene.apache.org
[jira] Resolved: (LUCENE-1042) discrepancy in
getTermFreqVector-methods
Posted by "Grant Ingersoll (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENE-1042?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Grant Ingersoll resolved LUCENE-1042.
-------------------------------------
Resolution: Fixed
Lucene Fields: [New, Patch Available] (was: [Patch Available, New])
committed, thanks Karl!
> discrepancy in getTermFreqVector-methods
> -----------------------------------------
>
> Key: LUCENE-1042
> URL: https://issues.apache.org/jira/browse/LUCENE-1042
> Project: Lucene - Java
> Issue Type: Bug
> Components: Term Vectors
> Affects Versions: 2.3
> Reporter: Karl Wettin
> Assignee: Grant Ingersoll
> Priority: Minor
>
> getTermFreqVector(int, TermVectorMapper) never calls the mapper if there is no term vector, consitent with all the other getTermFreqVector methods that returns null.
> getTermFreqVector(int, String, TermVectorMapper) throws an IOException when a field does not contain the term vector.
> My suggestion:
> {code}
> Index: src/java/org/apache/lucene/index/SegmentReader.java
> ===================================================================
> --- src/java/org/apache/lucene/index/SegmentReader.java (revision 590149)
> +++ src/java/org/apache/lucene/index/SegmentReader.java (working copy)
> @@ -648,7 +648,7 @@
> ensureOpen();
> FieldInfo fi = fieldInfos.fieldInfo(field);
> if (fi == null || !fi.storeTermVector || termVectorsReaderOrig == null)
> - throw new IOException("field does not contain term vectors");
> + return;
> {code}
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: java-dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-dev-help@lucene.apache.org