|
Authored by: Dave on Saturday, April 21 2012 @ 07:03 PM EDT |
Nope, you don't. [ Reply to This | Parent | # ]
|
|
Authored by: Anonymous on Saturday, April 21 2012 @ 07:19 PM EDT |
Java does not require declaration before use; I'm no
longer very clear how
the compiler figures it
out, but it's common to put the shortest of a set of
overloaded method signatures first, following with
the more complicated
signatures that the first ones call.
For example:
Object
getUserData(String username) {
return
getUserData(username, null,
null);
}
Object getUserData(String
username, Object realm, Object
token)
{
...
}
[ Reply to This | Parent | # ]
|
|
Authored by: IANALitj on Saturday, April 21 2012 @ 07:20 PM EDT |
I don't know about the requirements of Java.
As a matter of simple courtesy, however, referring to things after they are
defined is much easier on human readers than forcing the readers to hunt farther
down.[ Reply to This | Parent | # ]
|
|
|
|
|