You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucenenet.apache.org by "Scott Lombard (JIRA)" <ji...@apache.org> on 2011/07/09 08:00:19 UTC

[Lucene.Net] [jira] [Created] (LUCENENET-434) Remove AnonymousXXXX classes to increase readablity

Remove AnonymousXXXX classes to increase readablity
---------------------------------------------------

                 Key: LUCENENET-434
                 URL: https://issues.apache.org/jira/browse/LUCENENET-434
             Project: Lucene.Net
          Issue Type: Improvement
          Components: Lucene.Net Core
    Affects Versions: Lucene.Net 2.9.4g
            Reporter: Scott Lombard
            Assignee: Scott Lombard
             Fix For: Lucene.Net 2.9.4g


Replace AnonymousXXXX classes inhereted from JLCA which make the code impossible to read.
Follow Digy's template to replace the single abstract method with Func<> or Action<>
 
like in FilterCache<T> from:
protected abstract object MergeDeletes(IndexReader reader, object value);
to:
Func<IndexReader, object, object> MergeDeletes;
 
Determine a solution to the classes with more than 1 abstract method without diverging much from Java.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[Lucene.Net] [jira] [Commented] (LUCENENET-434) Remove AnonymousXXXX classes to increase readablity

Posted by "Digy (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/LUCENENET-434?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13062351#comment-13062351 ] 

Digy commented on LUCENENET-434:
--------------------------------

very nice.

> Remove AnonymousXXXX classes to increase readablity
> ---------------------------------------------------
>
>                 Key: LUCENENET-434
>                 URL: https://issues.apache.org/jira/browse/LUCENENET-434
>             Project: Lucene.Net
>          Issue Type: Improvement
>          Components: Lucene.Net Core
>    Affects Versions: Lucene.Net 2.9.4g
>            Reporter: Scott Lombard
>            Assignee: Scott Lombard
>             Fix For: Lucene.Net 2.9.4g
>
>         Attachments: TeeSinkTokenFilter.patch
>
>   Original Estimate: 168h
>          Time Spent: 5h
>  Remaining Estimate: 163h
>
> Replace AnonymousXXXX classes inhereted from JLCA which make the code impossible to read.
> Follow Digy's template to replace the single abstract method with Func<> or Action<>
>  
> like in FilterCache<T> from:
> protected abstract object MergeDeletes(IndexReader reader, object value);
> to:
> Func<IndexReader, object, object> MergeDeletes;
>  
> Determine a solution to the classes with more than 1 abstract method without diverging much from Java.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[Lucene.Net] [jira] [Work started] (LUCENENET-434) Remove AnonymousXXXX classes to increase readablity

Posted by "Scott Lombard (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/LUCENENET-434?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Work on LUCENENET-434 started by Scott Lombard.

> Remove AnonymousXXXX classes to increase readablity
> ---------------------------------------------------
>
>                 Key: LUCENENET-434
>                 URL: https://issues.apache.org/jira/browse/LUCENENET-434
>             Project: Lucene.Net
>          Issue Type: Improvement
>          Components: Lucene.Net Core
>    Affects Versions: Lucene.Net 2.9.4g
>            Reporter: Scott Lombard
>            Assignee: Scott Lombard
>             Fix For: Lucene.Net 2.9.4g
>
>   Original Estimate: 168h
>  Remaining Estimate: 168h
>
> Replace AnonymousXXXX classes inhereted from JLCA which make the code impossible to read.
> Follow Digy's template to replace the single abstract method with Func<> or Action<>
>  
> like in FilterCache<T> from:
> protected abstract object MergeDeletes(IndexReader reader, object value);
> to:
> Func<IndexReader, object, object> MergeDeletes;
>  
> Determine a solution to the classes with more than 1 abstract method without diverging much from Java.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[Lucene.Net] [jira] [Updated] (LUCENENET-434) Remove AnonymousXXXX classes to increase readablity

Posted by "Scott Lombard (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/LUCENENET-434?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Scott Lombard updated LUCENENET-434:
------------------------------------

    Attachment: TeeSinkTokenFilter.patch

I replaced the abstract method with a Func<>.  Then used a anonymous constructor when creating a new instance.

> Remove AnonymousXXXX classes to increase readablity
> ---------------------------------------------------
>
>                 Key: LUCENENET-434
>                 URL: https://issues.apache.org/jira/browse/LUCENENET-434
>             Project: Lucene.Net
>          Issue Type: Improvement
>          Components: Lucene.Net Core
>    Affects Versions: Lucene.Net 2.9.4g
>            Reporter: Scott Lombard
>            Assignee: Scott Lombard
>             Fix For: Lucene.Net 2.9.4g
>
>         Attachments: TeeSinkTokenFilter.patch
>
>   Original Estimate: 168h
>  Remaining Estimate: 168h
>
> Replace AnonymousXXXX classes inhereted from JLCA which make the code impossible to read.
> Follow Digy's template to replace the single abstract method with Func<> or Action<>
>  
> like in FilterCache<T> from:
> protected abstract object MergeDeletes(IndexReader reader, object value);
> to:
> Func<IndexReader, object, object> MergeDeletes;
>  
> Determine a solution to the classes with more than 1 abstract method without diverging much from Java.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[Lucene.Net] [jira] [Updated] (LUCENENET-434) Remove AnonymousXXXX classes to increase readablity

Posted by "Scott Lombard (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/LUCENENET-434?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Scott Lombard updated LUCENENET-434:
------------------------------------

             Priority: Minor  (was: Major)
    Affects Version/s: Lucene.Net 3.x
        Fix Version/s:     (was: Lucene.Net 2.9.4g)
                       Lucene.Net 3.x

This does not affect the function of the core it provides better readablity.  The classes were created as part of the automated porting tool used in the orginal conversion.  Removing them is a process that can happen over time.
                
> Remove AnonymousXXXX classes to increase readablity
> ---------------------------------------------------
>
>                 Key: LUCENENET-434
>                 URL: https://issues.apache.org/jira/browse/LUCENENET-434
>             Project: Lucene.Net
>          Issue Type: Improvement
>          Components: Lucene.Net Core
>    Affects Versions: Lucene.Net 3.x, Lucene.Net 2.9.4g
>            Reporter: Scott Lombard
>            Assignee: Scott Lombard
>            Priority: Minor
>             Fix For: Lucene.Net 3.x
>
>         Attachments: TeeSinkTokenFilter.patch
>
>   Original Estimate: 168h
>          Time Spent: 13h
>  Remaining Estimate: 155h
>
> Replace AnonymousXXXX classes inhereted from JLCA which make the code impossible to read.
> Follow Digy's template to replace the single abstract method with Func<> or Action<>
>  
> like in FilterCache<T> from:
> protected abstract object MergeDeletes(IndexReader reader, object value);
> to:
> Func<IndexReader, object, object> MergeDeletes;
>  
> Determine a solution to the classes with more than 1 abstract method without diverging much from Java.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (LUCENENET-434) Remove AnonymousXXXX classes to increase readablity

Posted by "Christopher Currens (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/LUCENENET-434?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Christopher Currens updated LUCENENET-434:
------------------------------------------

    Fix Version/s:     (was: Lucene.Net 3.0.3)
                   Lucene.Net 3.5

Moving to 3.5.  As ugly as they are, they don't hurt anything except our eyes leaving them in there.  As we port to 3.5, we can remove these as much as we can.
                
> Remove AnonymousXXXX classes to increase readablity
> ---------------------------------------------------
>
>                 Key: LUCENENET-434
>                 URL: https://issues.apache.org/jira/browse/LUCENENET-434
>             Project: Lucene.Net
>          Issue Type: Improvement
>          Components: Lucene.Net Core
>    Affects Versions: Lucene.Net 2.9.4g, Lucene.Net 3.0.3
>            Reporter: Scott Lombard
>            Assignee: Scott Lombard
>            Priority: Minor
>             Fix For: Lucene.Net 3.5
>
>         Attachments: TeeSinkTokenFilter.patch
>
>   Original Estimate: 168h
>          Time Spent: 13h
>  Remaining Estimate: 155h
>
> Replace AnonymousXXXX classes inhereted from JLCA which make the code impossible to read.
> Follow Digy's template to replace the single abstract method with Func<> or Action<>
>  
> like in FilterCache<T> from:
> protected abstract object MergeDeletes(IndexReader reader, object value);
> to:
> Func<IndexReader, object, object> MergeDeletes;
>  
> Determine a solution to the classes with more than 1 abstract method without diverging much from Java.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira