com.puppycrawl.tools.checkstyle.checks.blocks

Class BlockOption

Implemented Interfaces:
Serializable

public final class BlockOption
extends AbstractOption

Represents the policy for checking block statements.
Author:
Rick Giles
See Also:
EmptyBlockCheck

Field Summary

static BlockOption
STMT
Represents the policy that there is a statement in the block.
static BlockOption
TEXT
Represents the policy that there is some text in the block.

Method Summary

protected Map
getStrToOpt()

Methods inherited from class com.puppycrawl.tools.checkstyle.checks.AbstractOption

decode, getStrToOpt, readResolve, toString

Field Details

STMT

public static final BlockOption STMT
Represents the policy that there is a statement in the block. For example:
 finally {
     lock.release();
 }
 

TEXT

public static final BlockOption TEXT
Represents the policy that there is some text in the block. For example:
 catch (Exception ex) {
     // This is a bad coding practice
 }
 

Method Details

getStrToOpt

protected Map getStrToOpt()
Overrides:
getStrToOpt in interface AbstractOption