865fdc75c3
Got rid of the exposed exception code and we now rely on subclasses of LowpanException. Also introduces a new exception: LowpanRuntimeException LowpanRuntimeException, as a subclass of AndroidRuntimeException, doesn't need explicitly delared "throws" statements for function declarations. Most Exceptions are still LowpanExceptions, but some specific error codes, such as ERROR_NCP_PROBLEM, are now using this new exception class. Bug: b/63708181 Change-Id: Idba6233ac4803d33561b5aa951c8fa846c3ab1d8
43 lines
1.1 KiB
Java
43 lines
1.1 KiB
Java
/*
|
|
* Copyright (C) 2017 The Android Open Source Project
|
|
*
|
|
* 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 android.net.lowpan;
|
|
|
|
import android.util.AndroidRuntimeException;
|
|
|
|
/**
|
|
* Generic runtime exception for LoWPAN operations.
|
|
*
|
|
* @hide
|
|
*/
|
|
// @SystemApi
|
|
public class LowpanRuntimeException extends AndroidRuntimeException {
|
|
|
|
public LowpanRuntimeException() {}
|
|
|
|
public LowpanRuntimeException(String message) {
|
|
super(message);
|
|
}
|
|
|
|
public LowpanRuntimeException(String message, Throwable cause) {
|
|
super(message, cause);
|
|
}
|
|
|
|
public LowpanRuntimeException(Exception cause) {
|
|
super(cause);
|
|
}
|
|
}
|