[Fb-contrib-commit] fb-contrib/etc findbugs.xml,1.12,1.13 messages.xml,1.11,1.12
Brought to you by:
dbrosius
From: Dave B. <dbr...@us...> - 2005-09-19 02:25:57
|
Update of /cvsroot/fb-contrib/fb-contrib/etc In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28921/etc Modified Files: findbugs.xml messages.xml Log Message: Initial Checkin: FinalParameters Index: messages.xml =================================================================== RCS file: /cvsroot/fb-contrib/fb-contrib/etc/messages.xml,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- messages.xml 17 Sep 2005 20:48:31 -0000 1.11 +++ messages.xml 19 Sep 2005 02:25:44 -0000 1.12 @@ -112,7 +112,18 @@ </Details> </Detector> - <!-- BugPattern --> + <Detector class="com.mebigfatguy.fbcontrib.detect.FinalParameters"> + <Details> + <![CDATA[ + <p> Looks for methods that do not write to parameters, but do not declare these parameters final. + Doing so helps document the behaviour of the method, and may help the jvm to optimize the method + call.</p> + <p>It is a fast detector</p> + ]]> + </Details> + </Detector> + + <!-- BugPattern --> <BugPattern type="ISB_INEFFICIENT_STRING_BUFFERING"> <ShortDescription>method passes simple concatenating string in StringBuffer or StringBuilder append</ShortDescription> @@ -213,6 +224,18 @@ </Details> </BugPattern> + <BugPattern type="FP_FINAL_PARAMETERS"> + <ShortDescription>method does not define a parameter as final, but could</ShortDescription> + <LongDescription>method {1} does not define a parameter as final, but could</LongDescription> + <Details> + <![CDATA[ + <p>This method correctly does not write to a parameter. To help document this, and to perhaps + help the jvm optimize the invocation of this method, you should consider defining these parameters + as final.</p> + ]]> + </Details> + </BugPattern> + <!-- BugCode --> <BugCode abbrev="ISB">Inefficient String Buffering</BugCode> @@ -223,5 +246,6 @@ <BugCode abbrev="UCC">Unrelated Collection Contents</BugCode> <BugCode abbrev="DRE">Declared Runtime Exception</BugCode> <BugCode abbrev="CE">Class Envy</BugCode> + <BugCode abbrev="FP">Final Parameters</BugCode> </MessageCollection> \ No newline at end of file Index: findbugs.xml =================================================================== RCS file: /cvsroot/fb-contrib/fb-contrib/etc/findbugs.xml,v retrieving revision 1.12 retrieving revision 1.13 diff -u -d -r1.12 -r1.13 --- findbugs.xml 17 Sep 2005 04:48:04 -0000 1.12 +++ findbugs.xml 19 Sep 2005 02:25:44 -0000 1.13 @@ -46,6 +46,10 @@ reports="CE_CLASS_ENVY" hidden="true"/> + <Detector class="com.mebigfatguy.fbcontrib.detect.FinalParameters" + speed="fast" + reports="FP_FINAL_PARAMETERS" /> + <!-- BugPattern --> <BugPattern abbrev="ISB" type="ISB_INEFFICIENT_STRING_BUFFERING" category="PERFORMANCE" /> @@ -56,5 +60,6 @@ <BugPattern abbrev="UCC" type="UCC_UNRELATED_COLLECTION_CONTENTS" category="STYLE" /> <BugPattern abbrev="DRE" type="DRE_DECLARED_RUNTIME_EXCEPTION" category="STYLE" /> <BugPattern abbrev="CE" type="CE_CLASS_ENVY" category="STYLE" experimental="true" /> + <BugPattern abbrev="FP" type="FP_FINAL_PARAMETERS" category="STYLE" experimental="true" /> </FindbugsPlugin> \ No newline at end of file |