Remove VcnStatusCallback#onEnteredSafemode().
This CL removes VcnStatusCallback#onEnteredSafeMode(). This method was previously used to notify callbacks when their VCN entered Safe Mode. However, this is not needed now that VcnStatusCallback#onVcnStatusChanged(int) is defined. Bug: 1597023 Test: atest FrameworksVcnTests Change-Id: I8e47de9bf6763cd38025a552bee710673dddf843
This commit is contained in:
@@ -18,7 +18,6 @@ package android.net.vcn;
|
||||
|
||||
/** @hide */
|
||||
oneway interface IVcnStatusCallback {
|
||||
void onEnteredSafeMode();
|
||||
void onVcnStatusChanged(int statusCode);
|
||||
void onGatewayConnectionError(
|
||||
in int[] gatewayNetworkCapabilities,
|
||||
|
||||
@@ -427,20 +427,6 @@ public class VcnManager {
|
||||
public abstract static class VcnStatusCallback {
|
||||
private VcnStatusCallbackBinder mCbBinder;
|
||||
|
||||
/**
|
||||
* Invoked when the VCN for this Callback's subscription group enters safe mode.
|
||||
*
|
||||
* <p>A VCN will be put into safe mode if any of the gateway connections were unable to
|
||||
* establish a connection within a system-determined timeout (while underlying networks were
|
||||
* available).
|
||||
*
|
||||
* @deprecated Removed in favor of {@link #onVcnStatusChanged(int)}. To be removed in a
|
||||
* followup patch.
|
||||
* @hide
|
||||
*/
|
||||
@Deprecated
|
||||
public void onEnteredSafeMode() {}
|
||||
|
||||
/**
|
||||
* Invoked when status of the VCN for this callback's subscription group changes.
|
||||
*
|
||||
@@ -584,12 +570,6 @@ public class VcnManager {
|
||||
mCallback = callback;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onEnteredSafeMode() {
|
||||
Binder.withCleanCallingIdentity(
|
||||
() -> mExecutor.execute(() -> mCallback.onEnteredSafeMode()));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onVcnStatusChanged(@VcnStatusCode int statusCode) {
|
||||
Binder.withCleanCallingIdentity(
|
||||
|
||||
@@ -203,9 +203,6 @@ public class VcnManagerTest {
|
||||
IVcnStatusCallback cbBinder =
|
||||
new VcnStatusCallbackBinder(INLINE_EXECUTOR, mMockStatusCallback);
|
||||
|
||||
cbBinder.onEnteredSafeMode();
|
||||
verify(mMockStatusCallback).onEnteredSafeMode();
|
||||
|
||||
cbBinder.onVcnStatusChanged(VCN_STATUS_CODE_ACTIVE);
|
||||
verify(mMockStatusCallback).onVcnStatusChanged(VCN_STATUS_CODE_ACTIVE);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user