Re: [jetty-dev] [jira] (JETTY-1559) duplicate http status code constants in org.eclipse.jetty.http.HttpStatus to provide a more convenient auto-completion lookup

Paulo Gonçalves <[email protected]> Tue, 19 Mar 2013 23:42:21 +0000
Newsgroups gmane.comp.java.jetty.general
Message-ID <CACJJU-31-L1Eh=4pwbtTCPGNGKO-Ui24OKFY0dz6Y098-LHoXw@mail.gmail.com>
--14dae9340cfb22a7c104d84fa8de
Content-Type: text/plain; charset=ISO-8859-1

Java variables can't start with numbers.
See http://docs.oracle.com/javase/tutorial/java/nutsandbolts/variables.html

Paulo


On Tue, Mar 19, 2013 at 10:17 PM, Mark (JIRA) <[email protected]> wrote:

>        Mark<https://jira.codehaus.org/secure/ViewProfile.jspa?name=cinquero>created [image:
> Improvement] JETTY-1559 <https://jira.codehaus.org/browse/JETTY-1559>
>  *duplicate http status code constants in
> org.eclipse.jetty.http.HttpStatus to provide a more convenient
> auto-completion lookup* <https://jira.codehaus.org/browse/JETTY-1559>
>        *Issue Type:*  [image: Improvement] Improvement   *Assignee:* Unassigned
> *Components:*  HTTP   *Created:*  19/Mar/13 5:17 PM   *Description:*
>
> I use the jetty-http package's http status code constants because there is
> javadoc in maven and they contain the actual numbers. For a more convenient
> auto-completion lookup when starting out with the number, it would be great
> to have the constants named the other way round, maybe in addition to the
> existing name+number method. Example:
> HttpStatus.INTERNAL_SERVER_ERROR_500 ->
> HttpStatus.500_INTERNAL_SERVER_ERROR
> That way the autocompletion provided by the average IDE can also give an
> overview over all 4XX status code just by entering "4".
>   *Project:*  Jetty <https://jira.codehaus.org/browse/JETTY>   *Priority:*  [image:
> Trivial] Trivial   *Reporter:*  Mark<https://jira.codehaus.org/secure/ViewProfile.jspa?name=cinquero>       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 from this list, please visit:
> http://xircles.codehaus.org/manage_email

--14dae9340cfb22a7c104d84fa8de
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr">Java variables can&#39;t start with numbers.<div style>See=
=A0<a href=3D"http://docs.oracle.com/javase/tutorial/java/nutsandbolts/vari=
ables.html">http://docs.oracle.com/javase/tutorial/java/nutsandbolts/variab=
les.html</a></div>
<div style><br></div><div style>Paulo</div></div><div class=3D"gmail_extra"=
><br><br><div class=3D"gmail_quote">On Tue, Mar 19, 2013 at 10:17 PM, Mark =
(JIRA) <span dir=3D"ltr">&lt;<a href=3D"mailto:[email protected]" target=3D=
"_blank">[email protected]</a>&gt;</span> wrote:<br>
<blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1p=
x #ccc solid;padding-left:1ex">



























<div>
<table align=3D"center" border=3D"0" cellpadding=3D"0" cellspacing=3D"0" st=
yle=3D"width:100%;background-color:#f0f0f0">
    <tbody><tr valign=3D"top">
        <td style=3D"padding:16px!important">
            <table align=3D"center" border=3D"0" cellpadding=3D"0" cellspac=
ing=3D"0" style=3D"width:100%;background-color:#ffffff;border:1px solid #bb=
bbbb">
                <tbody><tr valign=3D"top">
                    <td bgcolor=3D"#ffffff" style=3D"background-color:#ffff=
ff;color:#00aa00;font-family:Arial,FreeSans,Helvetica,sans-serif;font-size:=
12px;line-height:1"><img src=3D"http://www.codehaus.org/codehaus-small.gif"=
 alt=3D"" style=3D"vertical-align:top"></td>

                </tr><tr valign=3D"top">
    <td style=3D"padding:32px 32px 0 32px">
       =20
               =20
       =20
       =20
            <table align=3D"left" border=3D"0" cellpadding=3D"0" cellspacin=
g=3D"0" width=3D"100%" style=3D"width:100%">
    <tbody><tr valign=3D"top">
        <td style=3D"color:#505050;font-family:Arial,FreeSans,Helvetica,san=
s-serif;padding:0">
                                        <img src=3D"https://jira.codehaus.o=
rg/secure/useravatar?avatarId=3D10232" alt=3D"" height=3D"48" width=3D"48" =
border=3D"0" align=3D"left" style=3D"padding:0;margin:0 16px 16px 0">
                        <div style=3D"padding:0 0 8px 0;font-size:12px;line=
-height:18px">
                                    <a rel=3D"cinquero" href=3D"https://jir=
a.codehaus.org/secure/ViewProfile.jspa?name=3Dcinquero" style=3D"color:#005=
500" target=3D"_blank">Mark</a>
     created <img src=3D"https://jira.codehaus.org/images/icons/issuetypes/=
improvement.png" height=3D"16" width=3D"16" border=3D"0" align=3D"absmiddle=
" alt=3D"Improvement"> <a style=3D"color:#005500;text-decoration:none" href=
=3D"https://jira.codehaus.org/browse/JETTY-1559" target=3D"_blank">JETTY-15=
59</a>
            </div>
                        <div style=3D"font-size:16px;line-height:20px;paddi=
ng:2px 0 16px 0">
                <a style=3D"color:#005500;text-decoration:none" href=3D"htt=
ps://jira.codehaus.org/browse/JETTY-1559" target=3D"_blank"><strong>duplica=
te http status code constants in org.eclipse.jetty.http.HttpStatus to provi=
de a more convenient auto-completion lookup</strong></a>
            </div>
                    </td>
    </tr>
</tbody></table>
    </td>
</tr>
<tr valign=3D"top">
    <td style=3D"padding:0 32px 32px 32px">
        <table border=3D"0" cellpadding=3D"0" cellspacing=3D"0" style=3D"pa=
dding:0;text-align:left;width:100%" width=3D"100%">
            <tbody><tr valign=3D"top">
                <td style=3D"width:64px;white-space:nowrap"></td>
                <td>
                    <table border=3D"0" cellpadding=3D"0" cellspacing=3D"0"=
 width=3D"100%">
                        <tbody><tr valign=3D"top">
    <td style=3D"font-size:12px;white-space:nowrap;font-family:Arial,FreeSa=
ns,Helvetica,sans-serif;padding:0 10px 10px 0">
        <strong style=3D"font-weight:normal;color:#505050">Issue Type:</str=
ong>
    </td>
    <td style=3D"width:100%;font-size:12px;font-family:Arial,FreeSans,Helve=
tica,sans-serif;padding:0 0 10px 0">
                <img src=3D"https://jira.codehaus.org/images/icons/issuetyp=
es/improvement.png" height=3D"16" width=3D"16" border=3D"0" align=3D"absmid=
dle" alt=3D"Improvement">        Improvement
    </td>
</tr>                                                <tr valign=3D"top">
    <td style=3D"font-size:12px;white-space:nowrap;font-family:Arial,FreeSa=
ns,Helvetica,sans-serif;padding:0 10px 10px 0">
        <strong style=3D"font-weight:normal;color:#505050">Assignee:</stron=
g>
    </td>
    <td style=3D"width:100%;font-size:12px;font-family:Arial,FreeSans,Helve=
tica,sans-serif;padding:0 0 10px 0">
                    Unassigned            </td>
</tr>                                                <tr valign=3D"top">
    <td style=3D"font-size:12px;white-space:nowrap;font-family:Arial,FreeSa=
ns,Helvetica,sans-serif;padding:0 10px 10px 0">
        <strong style=3D"font-weight:normal;color:#505050">Components:</str=
ong>
    </td>
    <td style=3D"width:100%;font-size:12px;font-family:Arial,FreeSans,Helve=
tica,sans-serif;padding:0 0 10px 0">
                    HTTP            </td>
</tr>
                        <tr valign=3D"top">
    <td style=3D"font-size:12px;white-space:nowrap;font-family:Arial,FreeSa=
ns,Helvetica,sans-serif;padding:0 10px 10px 0">
        <strong style=3D"font-weight:normal;color:#505050">Created:</strong=
>
    </td>
    <td style=3D"width:100%;font-size:12px;font-family:Arial,FreeSans,Helve=
tica,sans-serif;padding:0 0 10px 0">
        19/Mar/13 5:17 PM
    </td>
</tr>                        <tr valign=3D"top">
    <td style=3D"font-size:12px;white-space:nowrap;font-family:Arial,FreeSa=
ns,Helvetica,sans-serif;padding:0 10px 10px 0">
        <strong style=3D"font-weight:normal;color:#505050">Description:</st=
rong>
    </td>
    <td style=3D"width:100%;font-size:12px;font-family:Arial,FreeSans,Helve=
tica,sans-serif;padding:0 0 10px 0">
        <p style=3D"margin-top:0;margin-bottom:10px">I use the jetty-http p=
ackage&#39;s http status code constants because there is javadoc in maven a=
nd they contain the actual numbers. For a more convenient auto-completion l=
ookup when starting out with the number, it would be great to have the cons=
tants named the other way round, maybe in addition to the existing name+num=
ber method. Example:<br>

HttpStatus.INTERNAL_SERVER_ERROR_500 -&gt; HttpStatus.500_INTERNAL_SERVER_E=
RROR<br>
That way the autocompletion provided by the average IDE can also give an ov=
erview over all 4XX status code just by entering &quot;4&quot;.</p>
    </td>
</tr>
                                                                           =
                     <tr valign=3D"top">
    <td style=3D"font-size:12px;white-space:nowrap;font-family:Arial,FreeSa=
ns,Helvetica,sans-serif;padding:0 10px 10px 0">
        <strong style=3D"font-weight:normal;color:#505050">Project:</strong=
>
    </td>
    <td style=3D"width:100%;font-size:12px;font-family:Arial,FreeSans,Helve=
tica,sans-serif;padding:0 0 10px 0">
        <a style=3D"color:#005500" href=3D"https://jira.codehaus.org/browse=
/JETTY" target=3D"_blank">Jetty</a>
    </td>
</tr>                                                <tr valign=3D"top">
    <td style=3D"font-size:12px;white-space:nowrap;font-family:Arial,FreeSa=
ns,Helvetica,sans-serif;padding:0 10px 10px 0">
        <strong style=3D"font-weight:normal;color:#505050">Priority:</stron=
g>
    </td>
    <td style=3D"width:100%;font-size:12px;font-family:Arial,FreeSans,Helve=
tica,sans-serif;padding:0 0 10px 0">
                        <img src=3D"https://jira.codehaus.org/images/icons/=
priorities/trivial.png" height=3D"16" width=3D"16" border=3D"0" align=3D"ab=
smiddle" alt=3D"Trivial">                Trivial
    </td>
</tr>
                        <tr valign=3D"top">
    <td style=3D"font-size:12px;white-space:nowrap;font-family:Arial,FreeSa=
ns,Helvetica,sans-serif;padding:0 10px 10px 0">
        <strong style=3D"font-weight:normal;color:#505050">Reporter:</stron=
g>
    </td>
    <td style=3D"width:100%;font-size:12px;font-family:Arial,FreeSans,Helve=
tica,sans-serif;padding:0 0 10px 0">
                                        <a rel=3D"cinquero" href=3D"https:/=
/jira.codehaus.org/secure/ViewProfile.jspa?name=3Dcinquero" style=3D"color:=
#005500" target=3D"_blank">Mark</a>
                </td>
</tr>                                                   =20
   =20
   =20
                        </tbody></table>
                </td>
            </tr>
        </tbody></table>
    </td>
</tr>













            </tbody></table>
        </td>
    </tr>
    <tr valign=3D"top">
        <td style=3D"color:#505050;font-family:Arial,FreeSans,Helvetica,san=
s-serif;font-size:10px;line-height:14px;padding:0 16px 16px 16px;text-align=
:center">
            This message is automatically generated by JIRA.<br>
            If you think it was sent incorrectly, please contact your JIRA =
administrators<br>
            For more information on JIRA, see: <a style=3D"color:#005500" h=
ref=3D"http://www.atlassian.com/software/jira" target=3D"_blank">http://www=
.atlassian.com/software/jira</a>
        </td>
    </tr>
</tbody></table>
</div>

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    <a href=3D"http://xircles.codehaus.org/manage_email" target=3D"_blank">=
http://xircles.codehaus.org/manage_email</a>


</blockquote></div><br></div>

--14dae9340cfb22a7c104d84fa8de--