lucenenet-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Digy (JIRA)" <j...@apache.org>
Subject [jira] Closed: (LUCENENET-150) DocumentsWriter.ReusableStringReader does not implement some methods of StringReader
Date Tue, 18 Nov 2008 20:31:44 GMT

     [ https://issues.apache.org/jira/browse/LUCENENET-150?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Digy closed LUCENENET-150.
--------------------------

    Resolution: Fixed
      Assignee: Digy

Overriding not implemented methods of StringReader  and throwing exceptions in them (as in
DocumentsWriter.patch) resulted in failing of some Nunit tests.
Therefore, I added only one method to DocumentsWriter.ReusableStringReader
{code}
public override string ReadToEnd()
{
       if (left == 0) return null;
       left = 0;
       return s;
}
{code}

DIGY


> DocumentsWriter.ReusableStringReader   does not implement some methods of StringReader
> --------------------------------------------------------------------------------------
>
>                 Key: LUCENENET-150
>                 URL: https://issues.apache.org/jira/browse/LUCENENET-150
>             Project: Lucene.Net
>          Issue Type: Improvement
>         Environment: Lucene.Net 2.3.1
>            Reporter: Digy
>            Assignee: Digy
>            Priority: Minor
>         Attachments: DocumentsWriter.patch, TestReusableStringReader.cs
>
>
> Lucene.Net users writing custom analyzers may get unexpected results  since some methods
of StringReader
> (ReadBlock, ReadLine, Peek, ReadToEnd etc.)are not implemented in DocumentsWriter.ReusableStringReader.
> For ex, Calling ReadToEnd in a custom tokenizer class -although it contains some text-
returns an 
> empty string without informing user. 
> I will attach a test case and a patch for DocumentsWriter including previous patches.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message