net.sourceforge.pmd
Class RuleViolation

java.lang.Object
  extended bynet.sourceforge.pmd.RuleViolation

public class RuleViolation
extends java.lang.Object


Nested Class Summary
static class RuleViolation.RuleViolationComparator
           
 
Constructor Summary
RuleViolation(AbstractRule rule, RuleContext ctx, java.lang.String packageName, java.lang.String className, java.lang.String methodName)
           
RuleViolation(Rule rule, int line, int line2, java.lang.String variableName, java.lang.String specificDescription, RuleContext ctx, java.lang.String packageName, java.lang.String className, java.lang.String methodName)
           
RuleViolation(Rule rule, int line, RuleContext ctx, java.lang.String packageName, java.lang.String className, java.lang.String methodName)
           
RuleViolation(Rule rule, int line, java.lang.String specificDescription, RuleContext ctx)
           
RuleViolation(Rule rule, int line, java.lang.String specificDescription, RuleContext ctx, java.lang.String packageName, java.lang.String className, java.lang.String methodName)
           
 
Method Summary
 int getBeginColumn()
          gets the character in the line where the violation starts
 java.lang.String getClassName()
           
 java.lang.String getDescription()
           
 int getEndColumn()
          gets the character in the line where the violation ends
 java.lang.String getFilename()
           
 int getLine()
           
 int getLine2()
           
 java.lang.String getMethodName()
           
 java.lang.String getPackageName()
           
 Rule getRule()
           
 java.lang.String getVariableName()
           
 void setColumnInfo(int begin, int end)
          sets both beginColumn and endColumn
 void setLine(int line)
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

RuleViolation

public RuleViolation(Rule rule,
                     int line,
                     RuleContext ctx,
                     java.lang.String packageName,
                     java.lang.String className,
                     java.lang.String methodName)

RuleViolation

public RuleViolation(Rule rule,
                     int line,
                     java.lang.String specificDescription,
                     RuleContext ctx,
                     java.lang.String packageName,
                     java.lang.String className,
                     java.lang.String methodName)

RuleViolation

public RuleViolation(Rule rule,
                     int line,
                     int line2,
                     java.lang.String variableName,
                     java.lang.String specificDescription,
                     RuleContext ctx,
                     java.lang.String packageName,
                     java.lang.String className,
                     java.lang.String methodName)

RuleViolation

public RuleViolation(Rule rule,
                     int line,
                     java.lang.String specificDescription,
                     RuleContext ctx)

RuleViolation

public RuleViolation(AbstractRule rule,
                     RuleContext ctx,
                     java.lang.String packageName,
                     java.lang.String className,
                     java.lang.String methodName)
Method Detail

getBeginColumn

public final int getBeginColumn()
gets the character in the line where the violation starts

Returns:
a greater than or zero if set and a negative value if not available

getEndColumn

public final int getEndColumn()
gets the character in the line where the violation ends

Returns:
a greater than or zero if set and a negative value if not available

setColumnInfo

public void setColumnInfo(int begin,
                          int end)
sets both beginColumn and endColumn

Parameters:
begin -
end -

getRule

public Rule getRule()

getLine

public int getLine()

getDescription

public java.lang.String getDescription()

getFilename

public java.lang.String getFilename()

getClassName

public java.lang.String getClassName()

getMethodName

public java.lang.String getMethodName()

getLine2

public int getLine2()

getPackageName

public java.lang.String getPackageName()

getVariableName

public java.lang.String getVariableName()

toString

public java.lang.String toString()

setLine

public final void setLine(int line)


Copyright © 2002-2005 InfoEther. All Rights Reserved.