Add 5G/NR QOS support
Bug: 155176305
Bug: 182317794
Test: atest ConnectivityServiceTest
atest QosCallbackTrackerTest
Change-Id: Idf6d8a7c3b80bc50a2c1244ceaefea9381d40c2f
This commit is contained in:
@@ -19,6 +19,7 @@ package android.net;
|
||||
import android.annotation.NonNull;
|
||||
import android.annotation.Nullable;
|
||||
import android.telephony.data.EpsBearerQosSessionAttributes;
|
||||
import android.telephony.data.NrQosSessionAttributes;
|
||||
|
||||
import com.android.internal.annotations.VisibleForTesting;
|
||||
|
||||
@@ -83,6 +84,25 @@ class QosCallbackConnection extends android.net.IQosCallback.Stub {
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Called when either the {@link NrQosSessionAttributes} has changed or on the first time
|
||||
* the attributes have become available.
|
||||
*
|
||||
* @param session the session that is now available
|
||||
* @param attributes the corresponding attributes of session
|
||||
*/
|
||||
@Override
|
||||
public void onNrQosSessionAvailable(@NonNull final QosSession session,
|
||||
@NonNull final NrQosSessionAttributes attributes) {
|
||||
|
||||
mExecutor.execute(() -> {
|
||||
final QosCallback callback = mCallback;
|
||||
if (callback != null) {
|
||||
callback.onQosSessionAvailable(session, attributes);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Called when the session is lost.
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user