Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

com.puppycrawl.tools.checkstyle.checks
Class CheckUtils  view CheckUtils download CheckUtils.java

java.lang.Object
  extended bycom.puppycrawl.tools.checkstyle.checks.CheckUtils

public final class CheckUtils
extends java.lang.Object

Contains utility methods for the checks.


Field Summary
private static int BASE_10
          decimal radix
private static int BASE_16
          hex radix
private static int BASE_8
          octal radix
 
Constructor Summary
private CheckUtils()
          prevent instances
 
Method Summary
static com.puppycrawl.tools.checkstyle.api.FullIdent createFullType(com.puppycrawl.tools.checkstyle.api.DetailAST aTypeAST)
          Creates FullIdent for given type node.
private static com.puppycrawl.tools.checkstyle.api.FullIdent createFullTypeNoArrays(com.puppycrawl.tools.checkstyle.api.DetailAST aTypeAST)
           
private static boolean isElse(com.puppycrawl.tools.checkstyle.api.DetailAST aAST)
          Returns whether a token represents an ELSE.
static boolean isElseIf(com.puppycrawl.tools.checkstyle.api.DetailAST aAST)
          Returns whether a token represents an ELSE as part of an ELSE / IF set.
private static boolean isElseWithCurlyBraces(com.puppycrawl.tools.checkstyle.api.DetailAST aAST)
          Returns whether a token represents an SLIST as part of an ELSE statement.
static float parseFloat(java.lang.String aText, int aType)
          Returns the value represented by the specified string of the specified type.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

BASE_8

private static final int BASE_8
octal radix

See Also:
Constant Field Values

BASE_10

private static final int BASE_10
decimal radix

See Also:
Constant Field Values

BASE_16

private static final int BASE_16
hex radix

See Also:
Constant Field Values
Constructor Detail

CheckUtils

private CheckUtils()
prevent instances

Method Detail

isElseIf

public static boolean isElseIf(com.puppycrawl.tools.checkstyle.api.DetailAST aAST)
Returns whether a token represents an ELSE as part of an ELSE / IF set.


isElse

private static boolean isElse(com.puppycrawl.tools.checkstyle.api.DetailAST aAST)
Returns whether a token represents an ELSE.


isElseWithCurlyBraces

private static boolean isElseWithCurlyBraces(com.puppycrawl.tools.checkstyle.api.DetailAST aAST)
Returns whether a token represents an SLIST as part of an ELSE statement.


createFullType

public static com.puppycrawl.tools.checkstyle.api.FullIdent createFullType(com.puppycrawl.tools.checkstyle.api.DetailAST aTypeAST)
Creates FullIdent for given type node.


createFullTypeNoArrays

private static com.puppycrawl.tools.checkstyle.api.FullIdent createFullTypeNoArrays(com.puppycrawl.tools.checkstyle.api.DetailAST aTypeAST)

parseFloat

public static float parseFloat(java.lang.String aText,
                               int aType)
Returns the value represented by the specified string of the specified type. Returns 0 for types other than float, double, int, and long.