Felix Meschberger | 1fd5829 | 2009-10-02 12:59:27 +0000 | [diff] [blame] | 1 | /* |
| 2 | * Licensed to the Apache Software Foundation (ASF) under one |
| 3 | * or more contributor license agreements. See the NOTICE file |
| 4 | * distributed with this work for additional information |
| 5 | * regarding copyright ownership. The ASF licenses this file |
| 6 | * to you under the Apache License, Version 2.0 (the |
| 7 | * "License"); you may not use this file except in compliance |
| 8 | * with the License. You may obtain a copy of the License at |
| 9 | * |
| 10 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 11 | * |
| 12 | * Unless required by applicable law or agreed to in writing, |
| 13 | * software distributed under the License is distributed on an |
| 14 | * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY |
| 15 | * KIND, either express or implied. See the License for the |
| 16 | * specific language governing permissions and limitations |
| 17 | * under the License. |
| 18 | */ |
| 19 | package org.apache.felix.scrplugin; |
| 20 | |
Felix Meschberger | d6b7f21 | 2009-10-06 12:41:34 +0000 | [diff] [blame] | 21 | |
Carsten Ziegeler | 55c96d3 | 2012-06-13 12:03:35 +0000 | [diff] [blame] | 22 | public class SCRDescriptorException extends Exception { |
Felix Meschberger | 1fd5829 | 2009-10-02 12:59:27 +0000 | [diff] [blame] | 23 | |
Carsten Ziegeler | 9a496fe | 2012-06-27 06:20:28 +0000 | [diff] [blame] | 24 | private static final long serialVersionUID = 2L; |
Felix Meschberger | 1fd5829 | 2009-10-02 12:59:27 +0000 | [diff] [blame] | 25 | |
Felix Meschberger | d6b7f21 | 2009-10-06 12:41:34 +0000 | [diff] [blame] | 26 | private final String m_sourceLocation; |
| 27 | |
Carsten Ziegeler | 9a496fe | 2012-06-27 06:20:28 +0000 | [diff] [blame] | 28 | public SCRDescriptorException( final String message, final String sourceLocation ) { |
Felix Meschberger | d6b7f21 | 2009-10-06 12:41:34 +0000 | [diff] [blame] | 29 | super( message ); |
| 30 | this.m_sourceLocation = sourceLocation; |
Felix Meschberger | d6b7f21 | 2009-10-06 12:41:34 +0000 | [diff] [blame] | 31 | } |
| 32 | |
| 33 | |
Carsten Ziegeler | 9a496fe | 2012-06-27 06:20:28 +0000 | [diff] [blame] | 34 | public SCRDescriptorException( final String message, final Throwable cause ) { |
| 35 | this( message, null, cause ); |
Felix Meschberger | d6b7f21 | 2009-10-06 12:41:34 +0000 | [diff] [blame] | 36 | } |
| 37 | |
| 38 | |
Carsten Ziegeler | 9a496fe | 2012-06-27 06:20:28 +0000 | [diff] [blame] | 39 | public SCRDescriptorException( final String message, final String sourceLocation, |
| 40 | final Throwable cause ) { |
Felix Meschberger | d6b7f21 | 2009-10-06 12:41:34 +0000 | [diff] [blame] | 41 | super( message, cause ); |
| 42 | this.m_sourceLocation = sourceLocation; |
Felix Meschberger | d6b7f21 | 2009-10-06 12:41:34 +0000 | [diff] [blame] | 43 | } |
| 44 | |
| 45 | |
Carsten Ziegeler | 9a496fe | 2012-06-27 06:20:28 +0000 | [diff] [blame] | 46 | public String getSourceLocation() { |
Felix Meschberger | d6b7f21 | 2009-10-06 12:41:34 +0000 | [diff] [blame] | 47 | return m_sourceLocation; |
| 48 | } |
Felix Meschberger | 1fd5829 | 2009-10-02 12:59:27 +0000 | [diff] [blame] | 49 | } |