Java   View all facts   Glossary   Help
syntactic unit > scoping unit > block
Next scoping unitpackage    Upscoping unit

block
subjectfact 
blockcontains several statements surrounded by braces    source: Object Oriented Software Engineering by Lethbridge and Laganière, 2001-10-19 11:36:10.0
has definition Any code between matching bracesadded by: JK, source: Sun Java Tutorial, reference: Glossary, 2001-10-19 11:36:10.0
has definition A syntactic unit that groups statements or makes new declarationsadded by: DS, reference: Source 2, 2001-10-19 11:36:10.0
has example
{
a =5;
b = computeSomething;
}   
source: Object Oriented Software Engineering by Lethbridge and Laganière, 2001-10-19 11:36:10.0
has layout example style preferred by Sun:
if(condition) {
// statements
}
source: Object Oriented Software Engineering by Lethbridge and Laganière, 2001-10-19 11:36:10.0
has layout example style preferred by the authors:
if(condition)
{
// statements
}
source: Object Oriented Software Engineering by Lethbridge and Laganière, 2001-10-19 11:36:10.0
has purpose to create a new scope and/or to create a compound statementadded by: JK, source: Sun Java Tutorial, 2001-10-19 11:36:10.0
is a subtopic of Statements and Expressions2001-10-19 11:36:10.0
is partitioned into body, nested block2001-10-19 11:36:10.0
is used as the body of classes, loops, conditional statements and for exception handling    source: Object Oriented Software Engineering by Lethbridge and Laganière, 2001-10-19 11:36:10.0
is a kind of scoping unitadded by: DS, 2001-10-19 11:36:10.0
syntactic unithas syntax rule
bold = mandatory
italic = non-terminal
normal font = optional
2001-10-19 11:38:04.0

Kinds of block :