Merge changes from topic "QosCallbackException"
* changes: CTS test for QosCallbackException Expose constructor of Exceptions.
This commit is contained in:
@@ -18,6 +18,8 @@ package android.net;
|
||||
|
||||
import android.annotation.SystemApi;
|
||||
|
||||
import com.android.internal.annotations.VisibleForTesting;
|
||||
|
||||
/**
|
||||
* Indicates that the {@link Network} was released and is no longer available.
|
||||
*
|
||||
@@ -25,7 +27,7 @@ import android.annotation.SystemApi;
|
||||
*/
|
||||
@SystemApi
|
||||
public class NetworkReleasedException extends Exception {
|
||||
/** @hide */
|
||||
@VisibleForTesting
|
||||
public NetworkReleasedException() {
|
||||
super("The network was released and is no longer available");
|
||||
}
|
||||
|
||||
@@ -21,6 +21,8 @@ import android.annotation.NonNull;
|
||||
import android.annotation.SystemApi;
|
||||
import android.util.Log;
|
||||
|
||||
import com.android.internal.annotations.VisibleForTesting;
|
||||
|
||||
import java.lang.annotation.Retention;
|
||||
import java.lang.annotation.RetentionPolicy;
|
||||
|
||||
@@ -94,16 +96,12 @@ public final class QosCallbackException extends Exception {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @hide
|
||||
*/
|
||||
@VisibleForTesting
|
||||
public QosCallbackException(@NonNull final String message) {
|
||||
super(message);
|
||||
}
|
||||
|
||||
/**
|
||||
* @hide
|
||||
*/
|
||||
@VisibleForTesting
|
||||
public QosCallbackException(@NonNull final Throwable cause) {
|
||||
super(cause);
|
||||
}
|
||||
|
||||
@@ -18,6 +18,8 @@ package android.net;
|
||||
|
||||
import android.annotation.SystemApi;
|
||||
|
||||
import com.android.internal.annotations.VisibleForTesting;
|
||||
|
||||
/**
|
||||
* Thrown when the local address of the socket has changed.
|
||||
*
|
||||
@@ -25,7 +27,7 @@ import android.annotation.SystemApi;
|
||||
*/
|
||||
@SystemApi
|
||||
public class SocketLocalAddressChangedException extends Exception {
|
||||
/** @hide */
|
||||
@VisibleForTesting
|
||||
public SocketLocalAddressChangedException() {
|
||||
super("The local address of the socket changed");
|
||||
}
|
||||
|
||||
@@ -18,6 +18,8 @@ package android.net;
|
||||
|
||||
import android.annotation.SystemApi;
|
||||
|
||||
import com.android.internal.annotations.VisibleForTesting;
|
||||
|
||||
/**
|
||||
* Thrown when a previously bound socket becomes unbound.
|
||||
*
|
||||
@@ -25,7 +27,7 @@ import android.annotation.SystemApi;
|
||||
*/
|
||||
@SystemApi
|
||||
public class SocketNotBoundException extends Exception {
|
||||
/** @hide */
|
||||
@VisibleForTesting
|
||||
public SocketNotBoundException() {
|
||||
super("The socket is unbound");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user