001 /*
002 * Copyright 2002-2004 the original author or authors.
003 *
004 * Licensed under the Apache License, Version 2.0 (the "License"); you may not
005 * use this file except in compliance with the License. You may obtain a copy of
006 * the License at
007 *
008 * http://www.apache.org/licenses/LICENSE-2.0
009 *
010 * Unless required by applicable law or agreed to in writing, software
011 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
012 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
013 * License for the specific language governing permissions and limitations under
014 * the License.
015 */
016 package org.springframework.richclient.command;
017
018 import org.springframework.richclient.application.ApplicationException;
019
020
021 /**
022 * Indicates that a runtime or configuration error has occurred within the Command
023 * framework. This is a fairly generic exception. Before creating and throwing an instance
024 * of this type, consider if a more specific subclass would be more appropriate.
025 *
026 * @author Kevin Stembridge
027 * @since 0.3
028 *
029 */
030 public class CommandException extends ApplicationException {
031
032 private static final long serialVersionUID = 7845755447557671461L;
033
034 /**
035 * Creates a new {@code CommandException}.
036 */
037 public CommandException() {
038 super();
039 }
040
041 /**
042 * Creates a new {@code CommandException} with the specified message.
043 *
044 * @param message The detail message.
045 */
046 public CommandException(String message) {
047 super(message);
048 }
049
050 /**
051 * Creates a new {@code CommandException} with the specified message
052 * and nested exception.
053 *
054 * @param message The detail mesage.
055 * @param cause The nested exception.
056 */
057 public CommandException(String message, Throwable cause) {
058 super(message, cause);
059 }
060
061 /**
062 * Creates a new {@code CommandException} with the specified nested exception.
063 *
064 * @param cause The nested exception.
065 */
066 public CommandException(Throwable cause) {
067 super(cause);
068 }
069
070 }