X-Git-Url: http://git.argeo.org/?a=blobdiff_plain;f=org.argeo.slc.api%2Fsrc%2Forg%2Fargeo%2Fslc%2FUnsupportedException.java;h=aa050e30d0ccf29c45467c4227714cd91b5a175a;hb=8ff996a3380166be2ae9cf0ef0fa22c58e11746a;hp=fe63322090329a19c6c41ad7330a946f0fa70d0e;hpb=550e77c02caecd7b9aec42b3889e9751bb91623e;p=gpl%2Fargeo-slc.git diff --git a/org.argeo.slc.api/src/org/argeo/slc/UnsupportedException.java b/org.argeo.slc.api/src/org/argeo/slc/UnsupportedException.java index fe6332209..aa050e30d 100644 --- a/org.argeo.slc.api/src/org/argeo/slc/UnsupportedException.java +++ b/org.argeo.slc.api/src/org/argeo/slc/UnsupportedException.java @@ -1,69 +1,54 @@ -/* - * Copyright (C) 2007-2012 Argeo GmbH - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.argeo.slc; - -/** Exception for unsupported features or actions. */ -public class UnsupportedException extends SlcException { - static final long serialVersionUID = 1l; - - /** Action not supported. */ - public UnsupportedException() { - this("Action not supported"); - } - - /** Constructor with a message. */ - public UnsupportedException(String message) { - super(message); - } - - /** - * Constructor generating a message. - * - * @param nature - * the nature of the unsupported object - * @param obj - * the object itself (its class name will be used in message) - */ - public UnsupportedException(String nature, Object obj) { - super("Unsupported " + nature + ": " - + (obj != null ? obj.getClass() : "[object is null]")); - } - - /** - * Constructor generating a message. - * - * @param nature - * the nature of the unsupported object - * @param clss - * the class itself (will be used in message) - */ - public UnsupportedException(String nature, Class clss) { - super("Unsupported " + nature + ": " + clss); - } - - /** - * Constructor generating a message. - * - * @param nature - * the nature of the unsupported object - * @param value - * the problematic value itself - */ - public UnsupportedException(String nature, String value) { - super("Unsupported " + nature + ": " + value); - } - -} +package org.argeo.slc; + +/** Exception for unsupported features or actions. */ +public class UnsupportedException extends SlcException { + static final long serialVersionUID = 1l; + + /** Action not supported. */ + public UnsupportedException() { + this("Action not supported"); + } + + /** Constructor with a message. */ + public UnsupportedException(String message) { + super(message); + } + + /** + * Constructor generating a message. + * + * @param nature + * the nature of the unsupported object + * @param obj + * the object itself (its class name will be used in message) + */ + public UnsupportedException(String nature, Object obj) { + super("Unsupported " + nature + ": " + + (obj != null ? obj.getClass() : "[object is null]")); + } + + /** + * Constructor generating a message. + * + * @param nature + * the nature of the unsupported object + * @param clss + * the class itself (will be used in message) + */ + public UnsupportedException(String nature, Class clss) { + super("Unsupported " + nature + ": " + clss); + } + + /** + * Constructor generating a message. + * + * @param nature + * the nature of the unsupported object + * @param value + * the problematic value itself + */ + public UnsupportedException(String nature, String value) { + super("Unsupported " + nature + ": " + value); + } + +}