VinodKumarS-Huawei | 37316ae | 2017-01-11 16:11:42 +0530 | [diff] [blame] | 1 | /* |
Brian O'Connor | 72b2df2 | 2017-08-03 18:48:28 -0700 | [diff] [blame] | 2 | * Copyright 2016-present Open Networking Foundation |
VinodKumarS-Huawei | 37316ae | 2017-01-11 16:11:42 +0530 | [diff] [blame] | 3 | * |
| 4 | * Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | * you may not use this file except in compliance with the License. |
| 6 | * You may obtain a copy of the License at |
| 7 | * |
| 8 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | * |
| 10 | * Unless required by applicable law or agreed to in writing, software |
| 11 | * distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | * See the License for the specific language governing permissions and |
| 14 | * limitations under the License. |
| 15 | */ |
| 16 | |
| 17 | package org.onosproject.yang.model; |
| 18 | |
| 19 | /** |
| 20 | * Represents the Model Exception. |
| 21 | */ |
| 22 | public class ModelException extends RuntimeException { |
| 23 | |
| 24 | private static final long serialVersionUID = 20161223L; |
| 25 | |
| 26 | /** |
| 27 | * Creates a new YANG tool exception with given message. |
| 28 | * |
| 29 | * @param message the detail of exception in string |
| 30 | */ |
| 31 | public ModelException(String message) { |
| 32 | super(message); |
| 33 | } |
| 34 | |
| 35 | /** |
| 36 | * Creates a new tool exception from given message and cause. |
| 37 | * |
| 38 | * @param message the detail of exception in string |
| 39 | * @param cause underlying cause of the error |
| 40 | */ |
| 41 | public ModelException(final String message, final Throwable cause) { |
| 42 | super(message, cause); |
| 43 | } |
| 44 | |
| 45 | /** |
| 46 | * Creates a new tool exception from cause. |
| 47 | * |
| 48 | * @param cause underlying cause of the error |
| 49 | */ |
| 50 | public ModelException(final Throwable cause) { |
| 51 | super(cause); |
| 52 | } |
| 53 | |
| 54 | } |
| 55 | |