Java   View all facts   Glossary   Help
syntactic unit > declaration > variable declaration > local variable declaration
Upvariable declaration

local variable declaration
(declaration statement, local variable declaration statement)
subjectfact 
local variable declarationis a synonym of declaration statement2001-10-19 11:36:35.0
is a subtopic of Variables and Data Types2001-10-19 11:37:17.0
is a kind of variable declaration of a local variableadded by: WH, 2001-10-19 11:37:17.0
is a synonym of local variable declaration statement2001-10-19 11:37:17.0
variable declarationcan be placed practically anywhere in Java source code although it is good practice to only declare variables at the beginning of blocks    2001-10-19 11:38:13.0
has example
int anInteger;    
2001-10-19 11:38:13.0
has example
Rectangle rect = new Rectangle(); 
2001-10-19 11:38:13.0
has purpose to declare a variable2001-10-19 11:38:13.0
has syntax
accessLevel static final transient volatile type variableName
2001-10-19 11:38:13.0
must contain the type name and the variable name2001-10-19 11:38:13.0
declarationis part of definition2001-10-19 11:36:35.0
syntactic unithas syntax rule
bold = mandatory
italic = non-terminal
normal font = optional
2001-10-19 11:38:04.0