Revision: 1513 http://svn.sourceforge.net/spring-rich-c/?rev=1513&view=rev Author: ge0ffrey Date: 2006-10-16 13:06:19 -0700 (Mon, 16 Oct 2006)
Log Message: ----------- formated with code conventions prototype. checking what eclipse woudl change Modified Paths: -------------- trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/AbstractDialogExceptionHandler.java trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/AbstractLoggingExceptionHandler.java trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/DelegatingExceptionHandler.java trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/DelegatingExceptionHandlerDelegate.java trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/HibernateValidatorDialogExceptionHandler.java trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/LogLevel.java trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/MessagesDialogExceptionHandler.java trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/ShutdownPolicy.java trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/SimpleLoggingExceptionHandler.java Modified: trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/AbstractDialogExceptionHandler.java =================================================================== --- trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/AbstractDialogExceptionHandler.java 2006-10-15 15:55:08 UTC (rev 1512) +++ trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/AbstractDialogExceptionHandler.java 2006-10-16 20:06:19 UTC (rev 1513) @@ -1,14 +1,12 @@ package org.springframework.richclient.exceptionhandling; -import org.springframework.richclient.application.ApplicationWindow; +import org.springframework.beans.factory.InitializingBean; +import org.springframework.context.support.MessageSourceAccessor; import org.springframework.richclient.application.Application; import org.springframework.richclient.application.ApplicationServicesLocator; -import org.springframework.context.support.MessageSourceAccessor; -import org.springframework.beans.factory.InitializingBean; +import org.springframework.richclient.application.ApplicationWindow; -import javax.swing.JComponent; -import javax.swing.JFrame; -import javax.swing.JOptionPane; +import javax.swing.*; /** * Logs a throwable and shows a dialog about it to the user. Modified: trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/AbstractLoggingExceptionHandler.java =================================================================== --- trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/AbstractLoggingExceptionHandler.java 2006-10-15 15:55:08 UTC (rev 1512) +++ trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/AbstractLoggingExceptionHandler.java 2006-10-16 20:06:19 UTC (rev 1513) @@ -2,14 +2,11 @@ import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; -import org.springframework.beans.factory.InitializingBean; -import org.springframework.util.Assert; /** * Superclass of logging exception handlers. * It handles a throwable by logging it and notify it to the user. * Subclasses determine how it's notified to the user. - * * @author Geoffrey De Smet * @since 0.3 */ Modified: trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/DelegatingExceptionHandler.java =================================================================== --- trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/DelegatingExceptionHandler.java 2006-10-15 15:55:08 UTC (rev 1512) +++ trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/DelegatingExceptionHandler.java 2006-10-16 20:06:19 UTC (rev 1513) @@ -1,21 +1,21 @@ package org.springframework.richclient.exceptionhandling; -import java.util.List; +import org.apache.commons.logging.Log; +import org.apache.commons.logging.LogFactory; import org.springframework.beans.factory.InitializingBean; import org.springframework.util.Assert; -import org.apache.commons.logging.LogFactory; -import org.apache.commons.logging.Log; +import java.util.List; + /** * An exception handler that selects an appropriate exception handler from a list * based on the class of the thrown exception and delegates the handling of the exception to it. - * + * <p/> * This class works very similar to catch statements: * the first delegate which can handle the exception will handle it. * For example, consider 3 delegates for the following classes in this order: * NullPointerException (1), RuntimeException (2), IllegalArgumentException (3). * A thrown IllegalArgumentException will be handled by the (2) handler. The (3) handler is useless. - * * @author Geoffrey De Smet * @since 0.3 */ Modified: trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/DelegatingExceptionHandlerDelegate.java =================================================================== --- trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/DelegatingExceptionHandlerDelegate.java 2006-10-15 15:55:08 UTC (rev 1512) +++ trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/DelegatingExceptionHandlerDelegate.java 2006-10-16 20:06:19 UTC (rev 1513) @@ -1,7 +1,7 @@ package org.springframework.richclient.exceptionhandling; -import java.util.List; import java.util.Collections; +import java.util.List; /** * A couple of a throwable class list and the appropriate exception handler. @@ -18,7 +18,7 @@ } public DelegatingExceptionHandlerDelegate(Class throwableClass, - Thread.UncaughtExceptionHandler exceptionHandler) { + Thread.UncaughtExceptionHandler exceptionHandler) { this(Collections.singletonList(throwableClass), exceptionHandler); } @@ -47,7 +47,6 @@ /** * Returns true if thrownTrowable is an instance of one of the throwableClassList. - * * @param thrownTrowable the thrown exception or error. * @return true if thrownTrowable is an instance of one of the throwableClassList */ Modified: trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/HibernateValidatorDialogExceptionHandler.java =================================================================== --- trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/HibernateValidatorDialogExceptionHandler.java 2006-10-15 15:55:08 UTC (rev 1512) +++ trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/HibernateValidatorDialogExceptionHandler.java 2006-10-16 20:06:19 UTC (rev 1513) @@ -1,24 +1,15 @@ package org.springframework.richclient.exceptionhandling; -import org.springframework.context.support.DefaultMessageSourceResolvable; -import org.apache.commons.lang.StringUtils; -import org.apache.commons.lang.WordUtils; import org.hibernate.validator.InvalidStateException; import org.hibernate.validator.InvalidValue; -import javax.swing.JPanel; -import javax.swing.JLabel; -import javax.swing.JList; -import javax.swing.JScrollPane; -import javax.swing.ScrollPaneConstants; -import java.util.List; +import javax.swing.*; +import java.awt.*; import java.util.ArrayList; -import java.util.StringTokenizer; -import java.awt.BorderLayout; +import java.util.List; /** * Displays the validation errors to the user. - * * @author Geoffrey De Smet * @since 0.3 */ Modified: trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/LogLevel.java =================================================================== --- trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/LogLevel.java 2006-10-15 15:55:08 UTC (rev 1512) +++ trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/LogLevel.java 2006-10-16 20:06:19 UTC (rev 1513) @@ -6,10 +6,12 @@ * @since 0.3 */ public enum LogLevel { + TRACE, DEBUG, INFO, WARN, ERROR, FATAL + } Modified: trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/MessagesDialogExceptionHandler.java =================================================================== --- trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/MessagesDialogExceptionHandler.java 2006-10-15 15:55:08 UTC (rev 1512) +++ trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/MessagesDialogExceptionHandler.java 2006-10-16 20:06:19 UTC (rev 1513) @@ -1,25 +1,24 @@ package org.springframework.richclient.exceptionhandling; -import org.springframework.context.support.DefaultMessageSourceResolvable; import org.apache.commons.lang.StringUtils; import org.apache.commons.lang.WordUtils; +import org.springframework.context.support.DefaultMessageSourceResolvable; -import java.util.List; import java.util.ArrayList; +import java.util.List; import java.util.StringTokenizer; /** * Displays a message to the user which is fetched from the I18N files * based on the class and superclasses of the throwable. - * + * <p/> * For example if an IllegalArgumentException is thrown, it will search for * java.lang.IllegalArgumentException.caption and java.lang.IllegalArgumentException.description first, * and if it cant find that it will try in order: * java.lang.RuntimeException.caption/description, java.lang.Exception.caption/description and * java.lang.Throwable.caption/description. - * + * <p/> * The exception message is passed as a parameter, but is idented and wrapped first. - * * @author Geoffrey De Smet * @since 0.3 */ Modified: trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/ShutdownPolicy.java =================================================================== --- trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/ShutdownPolicy.java 2006-10-15 15:55:08 UTC (rev 1512) +++ trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/ShutdownPolicy.java 2006-10-16 20:06:19 UTC (rev 1513) @@ -3,12 +3,13 @@ /** * A paramater value to determines if the user should or should not be asked or forced * to shutdown the application when an exception occurs. - * * @author Geoffrey De Smet * @since 0.3 */ public enum ShutdownPolicy { + NONE, ASK, OBLIGATE + } Modified: trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/SimpleLoggingExceptionHandler.java =================================================================== --- trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/SimpleLoggingExceptionHandler.java 2006-10-15 15:55:08 UTC (rev 1512) +++ trunk/spring-richclient/tiger/src/main/java/org/springframework/richclient/exceptionhandling/SimpleLoggingExceptionHandler.java 2006-10-16 20:06:19 UTC (rev 1513) @@ -3,7 +3,6 @@ /** * Logs an exception but does not notify the user in any way. * Normally it is a bad practice not to notify the user if something goes wrong. - * * @author Geoffrey De Smet * @since 0.3 */ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. ------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ spring-rich-c-cvs mailing list spring-rich-c-cvs@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/spring-rich-c-cvs