[ checkstyle-Feature Requests-3413157 ] new checks: Exception Design Best Practices

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[ checkstyle-Feature Requests-3413157 ] new checks: Exception Design Best Practices

SourceForge.net
Feature Requests item #3413157, was opened at 2011-09-22 20:34
Message generated for change (Comment added) made by romanivanov
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=397081&aid=3413157&group_id=29721

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: Check
Group: None
Status: Open
Priority: 5
Private: No
Submitted By: Roman Ivanov (romanivanov)
Assigned to: Nobody/Anonymous (nobody)
Summary: new checks: Exception Design Best Practices

Initial Comment:
Rules: If you extend Exception
- always provide constructor with cause as parameter.
- Exception class has to be immutable.

ImmutableExceptionsCheck - check that class is immutable (all class fields are assigned in c-tors only)
Parameters:
- pattern to detect Exception class. (type=Regexp) default value= "*Exception"
- ignore list of classes. (type=Regexp)


CauseParameterInExceptionCheck -  check cause as a parameter in one of constructors
Parameters:
- pattern to detect Exception class. (type=Regexp) default value= "*Exception"
- ignore list of classes. (type=Regexp)



----------------------------------------------------------------------

>Comment By: Roman Ivanov (romanivanov)
Date: 2012-04-19 21:54

Message:
Released at 1.0.5, http://sevntu-checkstyle.github.com/sevntu.checkstyle/

----------------------------------------------------------------------

Comment By: Daniil Yaroslavtsev (daniilyar)
Date: 2012-04-08 10:57

Message:
Done. Patch is here:
https://sourceforge.net/tracker/?func=detail&aid=3515911&group_id=29721&atid=397081

----------------------------------------------------------------------

Comment By: Daniil Yaroslavtsev (daniilyar)
Date: 2012-03-17 05:09

Message:
ImmutableExceptionsCheck is already present in chekstayle:
http://api.dpml.net/checkstyle/3.5/com/puppycrawl/tools/checkstyle/checks/design/MutableExceptionCheck.html

----------------------------------------------------------------------

You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=397081&aid=3413157&group_id=29721

------------------------------------------------------------------------------
For Developers, A Lot Can Happen In A Second.
Boundary is the first to Know...and Tell You.
Monitor Your Applications in Ultra-Fine Resolution. Try it FREE!
http://p.sf.net/sfu/Boundary-d2dvs2
_______________________________________________
Checkstyle-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/checkstyle-devel