[ 
https://issues.apache.org/jira/browse/LUCENE-3574?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13149697#comment-13149697
 ] 

Uwe Schindler commented on LUCENE-3574:
---------------------------------------

One example where it might be bad: If it's an enum, you can also do if 
(JAVA_VERSION==JAVA_7, so the enum constants are not named like the fact they 
represent.

I think thats all too much logic for something simple. For one major version we 
will have mostly 2 or 3 constants. In trunk we currently only have Java7 and a 
deprecated one which is always true. New constants are only added on request, 
when we want to test for features/bugs.
                
> Add some more constants for newer Java versions to Constants.class, remove 
> outdated ones.
> -----------------------------------------------------------------------------------------
>
>                 Key: LUCENE-3574
>                 URL: https://issues.apache.org/jira/browse/LUCENE-3574
>             Project: Lucene - Java
>          Issue Type: New Feature
>          Components: core/other
>            Reporter: Uwe Schindler
>            Assignee: Uwe Schindler
>             Fix For: 3.5, 4.0
>
>         Attachments: LUCENE-3574-3x.patch
>
>
> Preparation for LUCENE-3235:
> This adds constants to quickly detect Java6 and Java7 to Constants.java. It 
> also deprecated and removes the outdated historical Java versions.

--
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

        

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to