You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by "Adrien Grand (JIRA)" <ji...@apache.org> on 2012/10/31 14:39:11 UTC
[jira] [Created] (LUCENE-4519) IndexDocument methods should not use
wildcards in their return types
Adrien Grand created LUCENE-4519:
------------------------------------
Summary: IndexDocument methods should not use wildcards in their return types
Key: LUCENE-4519
URL: https://issues.apache.org/jira/browse/LUCENE-4519
Project: Lucene - Core
Issue Type: Task
Reporter: Adrien Grand
Assignee: Adrien Grand
Priority: Trivial
{{public Iterable<? extends IndexableField> indexableFields()}} should be replaced with {{public Iterable<IndexableField> indexableFields()}}.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org
[jira] [Updated] (LUCENE-4519) IndexDocument methods should not use
wildcards in their return types
Posted by "Adrien Grand (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENE-4519?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Adrien Grand updated LUCENE-4519:
---------------------------------
Attachment: LUCENE-4519.patch
Patch. I probably need a review from the generics policeman. :-)
> IndexDocument methods should not use wildcards in their return types
> --------------------------------------------------------------------
>
> Key: LUCENE-4519
> URL: https://issues.apache.org/jira/browse/LUCENE-4519
> Project: Lucene - Core
> Issue Type: Task
> Reporter: Adrien Grand
> Assignee: Adrien Grand
> Priority: Trivial
> Attachments: LUCENE-4519.patch
>
>
> {{public Iterable<? extends IndexableField> indexableFields()}} should be replaced with {{public Iterable<IndexableField> indexableFields()}}.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org
[jira] [Updated] (LUCENE-4519) IndexDocument methods should not use
wildcards in their return types
Posted by "Adrien Grand (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENE-4519?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Adrien Grand updated LUCENE-4519:
---------------------------------
Attachment: LUCENE-4519.patch
New patch with improved javadocs. Does it look better?
> IndexDocument methods should not use wildcards in their return types
> --------------------------------------------------------------------
>
> Key: LUCENE-4519
> URL: https://issues.apache.org/jira/browse/LUCENE-4519
> Project: Lucene - Core
> Issue Type: Task
> Reporter: Adrien Grand
> Assignee: Adrien Grand
> Priority: Trivial
> Attachments: LUCENE-4519.patch, LUCENE-4519.patch
>
>
> {{public Iterable<? extends IndexableField> indexableFields()}} should be replaced with {{public Iterable<IndexableField> indexableFields()}}.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org
[jira] [Commented] (LUCENE-4519) IndexDocument methods should not
use wildcards in their return types
Posted by "Uwe Schindler (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENE-4519?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13490195#comment-13490195 ]
Uwe Schindler commented on LUCENE-4519:
---------------------------------------
+1
> IndexDocument methods should not use wildcards in their return types
> --------------------------------------------------------------------
>
> Key: LUCENE-4519
> URL: https://issues.apache.org/jira/browse/LUCENE-4519
> Project: Lucene - Core
> Issue Type: Task
> Reporter: Adrien Grand
> Assignee: Adrien Grand
> Priority: Trivial
> Attachments: LUCENE-4519.patch, LUCENE-4519.patch
>
>
> {{public Iterable<? extends IndexableField> indexableFields()}} should be replaced with {{public Iterable<IndexableField> indexableFields()}}.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org
[jira] [Commented] (LUCENE-4519) IndexDocument methods should not
use wildcards in their return types
Posted by "Uwe Schindler (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENE-4519?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13490176#comment-13490176 ]
Uwe Schindler commented on LUCENE-4519:
---------------------------------------
I agree with this, the wildcard is useless here and not really user-friendly. I think it was added to prevent some unchecked casts from different Field types, which can still be done, if the called methods have correct generics.
I am not so happy with the FilterIterator change, but I agree that it is needed here, otherwise it gets unchecked casts in the predicate.
> IndexDocument methods should not use wildcards in their return types
> --------------------------------------------------------------------
>
> Key: LUCENE-4519
> URL: https://issues.apache.org/jira/browse/LUCENE-4519
> Project: Lucene - Core
> Issue Type: Task
> Reporter: Adrien Grand
> Assignee: Adrien Grand
> Priority: Trivial
> Attachments: LUCENE-4519.patch
>
>
> {{public Iterable<? extends IndexableField> indexableFields()}} should be replaced with {{public Iterable<IndexableField> indexableFields()}}.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org
[jira] [Resolved] (LUCENE-4519) IndexDocument methods should not
use wildcards in their return types
Posted by "Adrien Grand (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENE-4519?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Adrien Grand resolved LUCENE-4519.
----------------------------------
Resolution: Fixed
Fix Version/s: 5.0
Committed to trunk (r1405639).
> IndexDocument methods should not use wildcards in their return types
> --------------------------------------------------------------------
>
> Key: LUCENE-4519
> URL: https://issues.apache.org/jira/browse/LUCENE-4519
> Project: Lucene - Core
> Issue Type: Task
> Reporter: Adrien Grand
> Assignee: Adrien Grand
> Priority: Trivial
> Fix For: 5.0
>
> Attachments: LUCENE-4519.patch, LUCENE-4519.patch
>
>
> {{public Iterable<? extends IndexableField> indexableFields()}} should be replaced with {{public Iterable<IndexableField> indexableFields()}}.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org
[jira] [Commented] (LUCENE-4519) IndexDocument methods should not
use wildcards in their return types
Posted by "Uwe Schindler (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENE-4519?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13490177#comment-13490177 ]
Uwe Schindler commented on LUCENE-4519:
---------------------------------------
Can you add javadocs to FilterIterator, so the generics are more clear. It is confusing which one is the inner iterator's type and which one the outer's. I would propose to rename the params to be more clear, too. Like FilterIterator<T, InnerT>.
> IndexDocument methods should not use wildcards in their return types
> --------------------------------------------------------------------
>
> Key: LUCENE-4519
> URL: https://issues.apache.org/jira/browse/LUCENE-4519
> Project: Lucene - Core
> Issue Type: Task
> Reporter: Adrien Grand
> Assignee: Adrien Grand
> Priority: Trivial
> Attachments: LUCENE-4519.patch
>
>
> {{public Iterable<? extends IndexableField> indexableFields()}} should be replaced with {{public Iterable<IndexableField> indexableFields()}}.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org